diff options
author | Darren Kulp <darren@kulp.ch> | 2020-06-20 21:12:50 -0700 |
---|---|---|
committer | Emilio Cobos Álvarez <emilio@crisal.io> | 2020-06-22 01:36:38 +0200 |
commit | 871d4725206600e787f7bbc92dcc7b51cc651433 (patch) | |
tree | 7477d536890eb94a79cb83deb78fa3a680957319 | |
parent | d2e0407563156ed6c2449474c6f8a35389e7171e (diff) |
Rebuild when clang_sys environment changes
-rw-r--r-- | build.rs | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -42,6 +42,13 @@ mod testgen { println!("cargo:rerun-if-changed=tests/headers"); + // On behalf of clang_sys, rebuild ourselves if important configuration + // variables change, to ensure that bindings get rebuilt if the + // underlying libclang changes. + println!("cargo:rerun-if-env-changed=LLVM_CONFIG_PATH"); + println!("cargo:rerun-if-env-changed=LIBCLANG_PATH"); + println!("cargo:rerun-if-env-changed=LIBCLANG_STATIC_PATH"); + for entry in entries { match entry.path().extension().and_then(OsStr::to_str) { Some("h") | Some("hpp") => { |