This PR add a (very small) improvement in case LIBXML2 env value is misconfigured.
I've encountered this problem while porting Hurl to conda-forge where LIBXML2 value is set to "2.11".
Before the PR:
$ export LIBXML2="2.11"
$ cargo build
Compiling libxml v0.3.3 (/Users/jc/Documents/Dev/rust-libxml)
error: failed to run custom build command for `libxml v0.3.3 (/Users/jc/Documents/Dev/rust-libxml)`
Caused by:
process didn't exit successfully: `/Users/jc/Documents/Dev/rust-libxml/target/debug/build/libxml-5bb5ffa4b9ec77c1/build-script-build` (exit status: 101)
--- stderr
thread 'main' panicked at build.rs:7:5:
assertion failed: p.is_file()
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
After the PR:
$ export LIBXML2="2.11"
Compiling libxml v0.3.3 (/Users/jc/Documents/Dev/rust-libxml)
error: failed to run custom build command for `libxml v0.3.3 (/Users/jc/Documents/Dev/rust-libxml)`
Caused by:
process didn't exit successfully: `/Users/jc/Documents/Dev/rust-libxml/target/debug/build/libxml-5bb5ffa4b9ec77c1/build-script-build` (exit status: 101)
--- stderr
thread 'main' panicked at build.rs:10:5:
not a file in LIBXML2 env (2.11)
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
In a nutshell assertion failed: p.is_file() vs not a file in LIBXML2 env (2.11)
(build.rs have been formatted with cargo fmt and lint with cargo clippy)
This PR add a (very small) improvement in case
LIBXML2
env value is misconfigured. I've encountered this problem while porting Hurl to conda-forge whereLIBXML2
value is set to "2.11".Before the PR:
After the PR:
In a nutshell
assertion failed: p.is_file()
vsnot a file in LIBXML2 env (2.11)
(
build.rs
have been formatted withcargo fmt
and lint withcargo clippy
)