Skip to content

Commit 32d5223

Browse files
committed
Update comments for building the project correctly.
1 parent c6c925b commit 32d5223

File tree

2 files changed

+9
-7
lines changed

2 files changed

+9
-7
lines changed

src/libcprover-rust/build.rs

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,16 +8,18 @@ fn get_current_working_dir() -> std::io::Result<PathBuf> {
88
env::current_dir()
99
}
1010

11-
// Passed by the top-level CMakeLists.txt to control which version of the
12-
// static library of CBMC we're linking against. A user can also change the
13-
// environment variable to link against different versions of CBMC.
11+
// Initially passed by the top-level CMakeLists.txt to control which version
12+
// of the static library of CBMC we were linking against. Staying in order to
13+
// allow users to be able to easily change the version of the CBMC static
14+
// library that's being looked up.
1415
fn get_cbmc_version() -> Result<String, VarError> {
1516
env::var("CBMC_VERSION")
1617
}
1718

18-
// Passed by the top-level CMakeLists.txt to control where the static library we
19-
// link against is located. A user can also change the location of the library
20-
// on their system by supplying the environment variable themselves.
19+
// Initially passed by the top-level CMakeLists.txt to control where the static
20+
// library we link against was located. Now staying for backward compatibility of
21+
// the build system, and to allow fine grained control for a user as to where the
22+
// static library is located (be it in a build folder or a system `/lib` folder).
2123
fn get_lib_directory() -> Result<String, VarError> {
2224
env::var("CBMC_LIB_DIR")
2325
}

src/libcprover-rust/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ pub mod ffi_util {
8585
}
8686
}
8787

88-
// To test run "CBMC_LIB_DIR=<path_to_build/libs> SAT_IMPL=minisat2 cargo test -- --test-threads=1 --nocapture"
88+
// To test run "CBMC_LIB_DIR=<path_to_build/libs> CBMC_VERSION=<version> cargo test -- --test-threads=1 --nocapture"
8989
#[cfg(test)]
9090
mod tests
9191
use super::*;

0 commit comments

Comments
 (0)