diff options
-rw-r--r-- | appveyor.yml | 1 | ||||
-rw-r--r-- | libssh2-sys/build.rs | 5 |
2 files changed, 5 insertions, 1 deletions
diff --git a/appveyor.yml b/appveyor.yml index 2753cde..ff69c40 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -13,7 +13,6 @@ install: - if defined MSYS_BITS set PATH=%PATH%;C:\msys64\mingw%MSYS_BITS%\bin - rustc -V - cargo -V - - git submodule update --init build: false diff --git a/libssh2-sys/build.rs b/libssh2-sys/build.rs index 3489a21..6025703 100644 --- a/libssh2-sys/build.rs +++ b/libssh2-sys/build.rs @@ -17,6 +17,11 @@ fn main() { return } + if !Path::new("libssh2").exists() { + let _ = Command::new("git").args(&["submodule", "update", "--init"]) + .status(); + } + let mut cfg = cmake::Config::new("libssh2"); let target = env::var("TARGET").unwrap(); |