Skip to content

Commit d8ee105

Browse files
authored
Avoid unconditional dependency on libssh2-sys when using zlib-ng-compat (#833)
Use a weak dependency feature to enable zlib-ng-compat on libssh2-sys without forcibly enabling libssh2-sys.
1 parent 2d391e9 commit d8ee105

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

Diff for: libgit2-sys/Cargo.toml

+1-6
Original file line numberDiff line numberDiff line change
@@ -38,9 +38,4 @@ https = ["openssl-sys"]
3838
ssh_key_from_memory = []
3939
vendored = []
4040
vendored-openssl = ["openssl-sys/vendored"]
41-
# Cargo does not support requiring features on an optional dependency without
42-
# requiring the dependency. Rather than introduce additional complexity, we
43-
# just require libssh2 when using zlib-ng-compat. This will require building
44-
# libssh2, but it will not add code to the final binary without the "ssh"
45-
# feature enabled.
46-
zlib-ng-compat = ["libz-sys/zlib-ng", "libssh2-sys/zlib-ng-compat"]
41+
zlib-ng-compat = ["libz-sys/zlib-ng", "libssh2-sys?/zlib-ng-compat"]

0 commit comments

Comments
 (0)