Skip to content

cargo build reports error that cannot find libclang.so #8

@l1t1

Description

@l1t1
chdb-rust# cargo build --release
    Updating `mirror` index
     Locking 46 packages to latest compatible versions
      Adding bindgen v0.70.1 (available: v0.72.0)
      Adding thiserror v1.0.69 (available: v2.0.12)
  Downloaded libloading v0.8.8 (registry `mirror`)
  Downloaded rustc-hash v1.1.0 (registry `mirror`)
  Downloaded cexpr v0.6.0 (registry `mirror`)
  Downloaded clang-sys v1.8.1 (registry `mirror`)
  Downloaded prettyplease v0.2.35 (registry `mirror`)
  Downloaded bindgen v0.70.1 (registry `mirror`)
  Downloaded 6 crates (391.5KiB) in 45.75s
   Compiling proc-macro2 v1.0.95
   Compiling unicode-ident v1.0.18
   Compiling glob v0.3.2
   Compiling prettyplease v0.2.35
   Compiling libc v0.2.174
   Compiling regex-syntax v0.8.5
   Compiling cfg-if v1.0.1
   Compiling memchr v2.7.5
   Compiling minimal-lexical v0.2.1
   Compiling libloading v0.8.8
   Compiling either v1.15.0
   Compiling bindgen v0.70.1
   Compiling rustc-hash v1.1.0
   Compiling itertools v0.13.0
   Compiling clang-sys v1.8.1
   Compiling nom v7.1.3
   Compiling bitflags v2.9.1
   Compiling shlex v1.3.0
   Compiling log v0.4.27
   Compiling thiserror v1.0.69
   Compiling quote v1.0.40
   Compiling syn v2.0.104
   Compiling regex-automata v0.4.9
   Compiling cexpr v0.6.0
   Compiling regex v1.11.1
   Compiling thiserror-impl v1.0.69
   Compiling chdb-rust v1.0.0 (/par/chdb-rust)
error: failed to run custom build command for `chdb-rust v1.0.0 (/par/chdb-rust)`

Caused by:
  process didn't exit successfully: `/par/chdb-rust/target/release/build/chdb-rust-10d92a847ce87f33/build-script-build` (exit status: 101)
  --- stdout
  cargo:rustc-link-search=./
  cargo:rustc-link-lib=chdb
  cargo:rerun-if-changed=chdb.h
  cargo:rerun-if-env-changed=TARGET
  cargo:rerun-if-env-changed=BINDGEN_EXTRA_CLANG_ARGS_aarch64-unknown-linux-gnu
  cargo:rerun-if-env-changed=BINDGEN_EXTRA_CLANG_ARGS_aarch64_unknown_linux_gnu
  cargo:rerun-if-env-changed=BINDGEN_EXTRA_CLANG_ARGS
  cargo:rerun-if-changed=wrapper.h

  --- stderr

  thread 'main' panicked at /usr/local/cargo/registry/src/mirrors.tuna.tsinghua.edu.cn-4dc01642fd091eda/bindgen-0.70.1/lib.rs:622:27:
  Unable to find libclang: "couldn't find any valid shared libraries matching: ['libclang.so', 'libclang-*.so', 'libclang.so.*', 'libclang-*.so.*'], set the `LIBCLANG_PATH` environment variable to a path where one of these files can be found (invalid: [])"
  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions