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

b2 uses the wrong slashes for gcc under windows in .rsp files #433

Open
3 tasks done
kfbBjoern opened this issue Dec 19, 2024 · 0 comments
Open
3 tasks done

b2 uses the wrong slashes for gcc under windows in .rsp files #433

kfbBjoern opened this issue Dec 19, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@kfbBjoern
Copy link

kfbBjoern commented Dec 19, 2024

Make sure you completed the following tasks

Environment and version details

  • Operating System+version: Windows 11
  • Compiler+version: mingw gcc-12.1.0
  • Shell: cmd, poweshell
  • B2 Version: Output of b2 -v and b2 --version B2 5.2.1 (OS=NT, jobs=48)
  • B2 Configuration: Output of b2 --debug-configuration in your project.
...
D:/Dependencies/mingw64-12.1.0/bin/../lib/gcc/x86_64-w64-mingw32/12.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find -lmkl_rt: No such file or directory
collect2.exe: error: ld returned 1 exit status

    "../../../Dependencies/mingw64-12.1.0/bin/g++.exe" @"Library/MultibodySystem/gcc-12.1.0/debug/libCaesMultibodySystem.dll.rsp"
....

When the linking command is to large a .rsp file is written. The slashes for the library path are bakshlahes and not recogneized by the linker

Steps to reproduce the issue

Actual behavior summary

The .rsp files look like

-L"..\..\..\Third_Party\MKL-2021.3b\Library\MKL\gcc-12.1.0\release\address-model-64"  -Wl,--out-implib,"Library/MultibodySystem/gcc-12.1.0/debug/libCaesMultibodySystem.dll.a" -o "Library/MultibodySystem/gcc-12.1.0/debug/libCaesMultibodySystem.dll"  -shared -Wl,--start-group "Library/MultibodySystem/gcc-12.1.0/debug/AccelerationsProvider.o" "Library/MultibodySystem/gcc-12.1.0/debug/DummyIntegrator.o" "Library/MultibodySystem/gcc-12.1.0/debug/FilesFunctions.o" "Library/MultibodySystem/gcc-12.1.0/debug/IntegratorsSetter.o" 
..
"Library/MultibodySystem/gcc-12.1.0/debug/Vectors3.o" "Library/MultibodySystem/gcc-12.1.0/debug/ZXZAnglesToEulerParamsSignal.o" "Library/MultibodySystem/gcc-12.1.0/debug/MultibodySystem_res.o"  -Wl,-Bstatic  -Wl,-Bdynamic -lmkl_rt -Wl,--end-group -g 

**The project is blocked since we have to use the newest msvc and the gcc in version 12.1 for WIN11 **

Expected behavior summary

I think the .rsp files should look l ike this as this can be linked without errors

-L"../../../Third_Party/MKL-2021.3b/Library/MKL/gcc-12.1.0\release\address-model-64"  -Wl,--out-implib,"Library/MultibodySystem/gcc-12.1.0/debug/libCaesMultibodySystem.dll.a" -o "Library/MultibodySystem/gcc-12.1.0/debug/libCaesMultibodySystem.dll"  -shared -Wl,--start-group "Library/MultibodySystem/gcc-12.1.0/debug/AccelerationsProvider.o" "Library/MultibodySystem/gcc-12.1.0/debug/DummyIntegrator.o" "Library/MultibodySystem/gcc-12.1.0/debug/FilesFunctions.o" "Library/MultibodySystem/gcc-12.1.0/debug/IntegratorsSetter.o" 
..
"Library/MultibodySystem/gcc-12.1.0/debug/Vectors3.o" "Library/MultibodySystem/gcc-12.1.0/debug/ZXZAnglesToEulerParamsSignal.o" "Library/MultibodySystem/gcc-12.1.0/debug/MultibodySystem_res.o"  -Wl,-Bstatic  -Wl,-Bdynamic -lmkl_rt -Wl,--end-group -g 
@kfbBjoern kfbBjoern added the bug Something isn't working label Dec 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant