-
-
Notifications
You must be signed in to change notification settings - Fork 227
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
Chanfe 397fdf5 weird behavior for cross-compile processes #183
Labels
bug
Something isn't working
Comments
I have the same issue after upgrading to Boost 1.80.0 on Linux ARM32, the build error looks like:
For now, I tried to revert 397fdf5 as a workaround. |
3 tasks
Same issue here. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Environment and version details
b2 -v
b2 --version
b2 embedded in boost libraries 1.80
b2 --debug-configuration
Brief problem description
Cross compiling for arm-linux-gnueabihf generates weird target option for clang
Steps to reproduce the issue
./b2 -j7 -q architecture=arm address-model=32 binary-format=elf abi=aapcs target-os=linux variant=release optimization=speed lto=on lto-mode=thin threading=multi -d+1 link=shared runtime-link=shared toolset=clang 'cflags=--sysroot=/mnt/distos -march=armv6kz -mtune=arm1176jzf-s -mfpu=vfpv2 -mfloat-abi=hard -marm ' 'cxxflags=-I/mnt/binaries/usr/include -I/mnt/distos/usr/include -I/mnt/distos/usr/include/arm-linux-gnueabihf -I/mnt/distos/usr/include/c++/10 -I/mnt/distos/usr/include/arm-linux-gnueabihf/c++/10 -I/mnt/distos/usr/include/python3.9 -fPIC ' 'linkflags=--target=arm-linux-gnueabihf --sysroot=/mnt/distos -fuse-ld=lld -Wl,--threads=7 -Wl,-rpath-link,/mnt/binaries/lib/arm-linux-gnueabihf -L/mnt/binaries/lib/arm-linux-gnueabihf -Wl,-rpath-link,/mnt/binaries/usr/lib/arm-linux-gnueabihf -L/mnt/binaries/usr/lib/arm-linux-gnueabihf -Wl,-rpath-link,/mnt/distos/lib/arm-linux-gnueabihf -L/mnt/distos/lib/arm-linux-gnueabihf -Wl,-rpath-link,/mnt/distos/usr/lib/arm-linux-gnueabihf -L/mnt/distos/usr/lib/arm-linux-gnueabihf -Wl,-rpath-link,/mnt/distos/usr/lib/gcc/arm-linux-gnueabihf/10 -L/mnt/distos/usr/lib/gcc/arm-linux-gnueabihf/10 ' install
where in
/mnt/distos
I mounted the target system image and/mnt/binaries
some dependencies for boostlibActual behavior summary
the generated clang command is:
clang --target=arm-pc-linux ......
In order to force the compilation I had to force the target parameter with "./b2 ... cflags=--target=arm-linux-gnueabihf... ..." in this case the output is
clang --target=arm-pc-linux --target=arm-linux-gnueabihf ......
that is a mess but at least it overrides the weird target clang option.
Expected behavior summary
The correct arch string should be:
clang --target=arm-linux-gnueabihf ......
I haven't tested other arch targets, but I expect the same issue for aarch64-linux-gnu...
In previous versions of b2 target option were not generated so I used to force anyway the target option for clang
The text was updated successfully, but these errors were encountered: