diff --git a/CHANGELOG.md b/CHANGELOG.md index f4e6d72..8e15c9b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,6 @@ +# 0.10.0 +* Initial upgrade to mongo c driver 1.8.0, no support for new features yet + # 0.9.0 * Add WriteConcernError and DuplicateKey to error * Add error code for unknown error diff --git a/Cargo.toml b/Cargo.toml index ca6c5f9..25148ad 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "mongo_driver" -version = "0.9.0" +version = "0.10.0" authors = ["Thijs Cadier "] description = "Mongo Rust driver built on top of the Mongo C driver" readme = "README.md" @@ -25,7 +25,7 @@ bson = "^0.9" [dependencies.mongoc-sys] path = "mongoc-sys" -version = "1.6.4" +version = "1.8.0" [dev-dependencies] chrono = "^0.4" diff --git a/mongoc-sys/Cargo.toml b/mongoc-sys/Cargo.toml index 50b9d0d..188d24f 100644 --- a/mongoc-sys/Cargo.toml +++ b/mongoc-sys/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "mongoc-sys" -version = "1.6.4" +version = "1.8.0" description = "Sys package with installer and bindings for mongoc" authors = ["Thijs Cadier "] build = "build.rs" diff --git a/mongoc-sys/build.rs b/mongoc-sys/build.rs index 296f226..701e205 100644 --- a/mongoc-sys/build.rs +++ b/mongoc-sys/build.rs @@ -2,10 +2,10 @@ use std::env; use std::path::Path; use std::process::Command; -static VERSION: &'static str = "1.6.3"; // Should be the same major version as in the manifest +static VERSION: &'static str = "1.8.0"; // Should be the same major version as in the manifest fn main() { - let out_dir_var = env::var("OUT_DIR").unwrap(); + let out_dir_var = env::var("OUT_DIR").expect("No out dir"); let out_dir = format!("{}/{}", out_dir_var, VERSION); let driver_src_path = format!("mongo-c-driver-{}", VERSION); @@ -21,7 +21,7 @@ fn main() { .arg("-L") // Follow redirects .arg(url) .status() - .unwrap() + .expect("Could not run curl") .success()); let archive_name = format!( @@ -31,7 +31,7 @@ fn main() { assert!(Command::new("tar").arg("xzf") .arg(&archive_name) .status() - .unwrap() + .expect("Could not run tar") .success()); // Configure and install @@ -44,6 +44,8 @@ fn main() { command.arg("--enable-shm-counters=no"); command.arg("--with-libbson=bundled"); command.arg("--with-pic=yes"); + command.arg("--with-snappy=no"); + command.arg("--with-zlib=no"); command.arg(format!("--prefix={}", &out_dir)); command.current_dir(&driver_src_path); @@ -57,18 +59,18 @@ fn main() { command.arg(format!("--build={}", target)); } - assert!(command.status().unwrap().success()); + assert!(command.status().expect("Could not run configure").success()); assert!(Command::new("make"). current_dir(&driver_src_path). env("CFLAGS", "-DMONGOC_TRACE"). status(). - unwrap(). + expect("Could not run make"). success()); assert!(Command::new("make"). arg("install"). current_dir(&driver_src_path). status(). - unwrap(). + expect("Could not run make install"). success()); }