Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to build on Windows #50

Open
CGMossa opened this issue Nov 13, 2023 · 1 comment
Open

Unable to build on Windows #50

CGMossa opened this issue Nov 13, 2023 · 1 comment

Comments

@CGMossa
Copy link

CGMossa commented Nov 13, 2023

Unable to build this on Windows.

[env]
LIBCLANG_PATH = "C:/Users/minin/scoop/apps/llvm/current/bin"

[build]
target-dir = "target"

And the rest of diagnostic:

PS>rustup show
Default host: x86_64-pc-windows-msvc
rustup home:  C:\Users\minin\scoop\persist\rustup\.rustup

installed toolchains
--------------------

stable-x86_64-pc-windows-gnu
stable-x86_64-pc-windows-msvc (default)
nightly-x86_64-pc-windows-gnu
nightly-x86_64-pc-windows-msvc
1.63.0-x86_64-pc-windows-msvc

installed targets for active toolchain
--------------------------------------

x86_64-pc-windows-gnu
x86_64-pc-windows-msvc

active toolchain
----------------

stable-x86_64-pc-windows-msvc (default)
rustc 1.73.0 (cc66ad468 2023-10-03)

C:\Users\minin>rustc --version
rustc 1.73.0 (cc66ad468 2023-10-03)


Windows 11, Version 23H2

```sh
debug/build/lightgbm-sys-91dabd8648f00896/out/include/LightGBM/utils/yamc/yamc_rwlock_sched.hpp
    -- Installing: C:/Users/minin/Documents/GitHub/lightgbm-rust/target/debug/build/lightgbm-sys-91dabd8648f00896/out/include/LightGBM/utils/yamc/yamc_shared_lock.hpp 
  cargo:root=C:\Users\minin\Documents\GitHub\lightgbm-rust\target\debug\build\lightgbm-sys-91dabd8648f00896\out

  --- stderr
  CMake Deprecation Warning at CMakeLists.txt:26 (cmake_minimum_required):
    Compatibility with CMake < 3.5 will be removed from a future version of
    CMake.

    Update the VERSION argument <min> value or use a ...<max> suffix to tell
    CMake that the project does not need compatibility with older versions.


  CMake Warning:
    Manually-specified variables were not used by the project:

      CMAKE_ASM_FLAGS
      CMAKE_ASM_FLAGS_RELEASE
      CMAKE_BUILD_TYPE


  thread 'main' panicked at C:\Users\minin\scoop\persist\rustup\.cargo\registry\src\index.crates.io-6f17d22bba15001f\proc-macro2-1.0.69\src\fallback.rs:817:9:
  "__vcrt_va_list_is_reference_(unnamed_enum_at_C_\\Program_Files_(x86)\\Microsoft_Visual_Studio\\2022\\BuildTools\\VC\\Tools\\MSVC\\14_35_32215\\include\\vadefs_h_176_13)" is not a valid Ident
  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
@leofidus
Copy link

The fix is probably in one of the unmerged PRs, for example updates so the library builds with Clang 16. We maintain a fork at https://github.com/DeepSignSecurity/lightgbm-rs with many fixes merged, you could check if that one builds for you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants