diff options
author | Alex McArther <acmcarther@gmail.com> | 2018-01-09 19:24:12 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-01-09 19:24:12 -0800 |
commit | d302c13d2b732f1ff88d3657ceca1852d7e441cb (patch) | |
tree | 56b0e5e0018c7341b049be99ef13f12d3dd63e6f | |
parent | 21861ea37a0f334fec0964caf4033ece8d566ca0 (diff) |
Make CARGO_PKG_VERSION option_env!, rather than env!
-rw-r--r-- | src/options.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/options.rs b/src/options.rs index c35aa276..6d6e712c 100644 --- a/src/options.rs +++ b/src/options.rs @@ -19,7 +19,7 @@ where ); let matches = App::new("bindgen") - .version(env!("CARGO_PKG_VERSION")) + .version(option_env!("CARGO_PKG_VERSION").unwrap_or("unknown")) .about("Generates Rust bindings from C/C++ headers.") .usage("bindgen [FLAGS] [OPTIONS] <header> -- <clang-args>...") .args(&[ |