mirror of
https://github.com/isar/rusqlite.git
synced 2025-10-10 05:22:19 +08:00
LIBSQLITE3_FLAGS for bundled -> SQLITE_FLAGS
This flag was added in a9b700c
but never documented. Here we change the
name to more closely follow SQLITE_MAX_VARIABLE_NUMBER etc; and
document its existence in README.md.
This commit is contained in:
@@ -138,18 +138,18 @@ mod build_bundled {
|
||||
}
|
||||
println!("cargo:rerun-if-env-changed=SQLITE_MAX_EXPR_DEPTH");
|
||||
|
||||
if let Ok(extras) = env::var("LIBSQLITE3_FLAGS") {
|
||||
if let Ok(extras) = env::var("SQLITE_FLAGS") {
|
||||
for extra in extras.split_whitespace() {
|
||||
if extra.starts_with("-D") || extra.starts_with("-U") {
|
||||
cfg.flag(extra);
|
||||
} else if extra.starts_with("SQLITE_") {
|
||||
cfg.flag(&format!("-D{}", extra));
|
||||
} else {
|
||||
panic!("Don't understand {} in LIBSQLITE3_FLAGS", extra);
|
||||
panic!("Don't understand {} in SQLITE_FLAGS", extra);
|
||||
}
|
||||
}
|
||||
}
|
||||
println!("cargo:rerun-if-env-changed=LIBSQLITE3_FLAGS");
|
||||
println!("cargo:rerun-if-env-changed=SQLITE_FLAGS");
|
||||
|
||||
cfg.compile("libsqlite3.a");
|
||||
|
||||
|
Reference in New Issue
Block a user