|
|
@ -44,17 +44,23 @@ fn main() {
|
|
|
|
.success());
|
|
|
|
.success());
|
|
|
|
|
|
|
|
|
|
|
|
// Configure and install
|
|
|
|
// Configure and install
|
|
|
|
assert!(Command::new("sh").arg("configure")
|
|
|
|
let mut command = Command::new("sh");
|
|
|
|
.arg("--enable-ssl=yes")
|
|
|
|
command.arg("configure");
|
|
|
|
.arg("--enable-sasl=no")
|
|
|
|
command.arg("--enable-ssl=yes");
|
|
|
|
.arg("--enable-static=yes")
|
|
|
|
command.arg("--enable-sasl=no");
|
|
|
|
.arg("--enable-shared=no")
|
|
|
|
command.arg("--enable-static=yes");
|
|
|
|
.arg("--with-libbson=bundled")
|
|
|
|
command.arg("--enable-shared=no");
|
|
|
|
.arg(format!("--prefix={}", &out_dir))
|
|
|
|
command.arg("--with-libbson=bundled");
|
|
|
|
.current_dir(&driver_path)
|
|
|
|
command.arg(format!("--prefix={}", &out_dir));
|
|
|
|
.status()
|
|
|
|
command.env("BSON_CFLAGS", "-fPIC");
|
|
|
|
.unwrap()
|
|
|
|
command.current_dir(&driver_path);
|
|
|
|
.success());
|
|
|
|
|
|
|
|
|
|
|
|
// Use env var to override build target if set
|
|
|
|
|
|
|
|
if let Ok(target) = env::var("MONGO_C_DRIVER_TARGET") {
|
|
|
|
|
|
|
|
command.arg(format!("--target={}", target));
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
assert!(command.status().unwrap().success());
|
|
|
|
assert!(Command::new("make").current_dir(&driver_path).status().unwrap().success());
|
|
|
|
assert!(Command::new("make").current_dir(&driver_path).status().unwrap().success());
|
|
|
|
assert!(Command::new("make").arg("install").current_dir(&driver_path).status().unwrap().success());
|
|
|
|
assert!(Command::new("make").arg("install").current_dir(&driver_path).status().unwrap().success());
|
|
|
|
|
|
|
|
|
|
|
|