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

Failing to link against libscu #915

Closed
dpyte opened this issue Jan 15, 2021 · 3 comments
Closed

Failing to link against libscu #915

dpyte opened this issue Jan 15, 2021 · 3 comments

Comments

@dpyte
Copy link

dpyte commented Jan 15, 2021

libscu.a linking error

Build Log
What is the build error?

[1/17622] Linking ASM static library src/csu/libcsu.a
FAILED: src/csu/libcsu.a
: && /home/predaking2612/dev/tmp/darling/build/src/external/cctools-port/cctools/ar/x86_64-apple-darwin19-ar cr src/csu/libcsu.a  src/csu/CMakeFiles/csu.dir/crt1.10.6.o  && /home/predaking2612/dev/tmp/darling/build/src/external/cctools-port/cctools/ar/x86_64-apple-darwin19-ranlib src/csu/libcsu.a && :
ar: src/csu/libcsu.a is a fat file (use libtool(1) or lipo(1) and ar(1) on it)
x86_64-apple-darwin19-ar: src/csu/libcsu.a: Invalid argument
[10/17622] Building C object src/external/BerkeleyDB/CMakeFiles/berkeley_db.dir/db/db/db_iface.c.o
ninja: build stopped: subcommand failed.

System Information
What system are you building with?
ArchLinux

Software Version
Clang 11.0.1
CMake 3.19.3
Linux Kernel 5.4.88-1-lts
Darling f00820e
@facekapow
Copy link
Member

Yeah, this is a known issue when building with ninja. The workaround for this is to remove src/csu/libcsu.a and then try again.

@dpyte dpyte closed this as completed Jan 16, 2021
@npyl
Copy link

npyl commented Oct 2, 2022

Had this issue today on WSL2 (ubuntu) and I just want to say that some other parts may cause problems like: python7, Ruby etc.
I used the same technique mentioned above for python7 but for Ruby I just disabled the submodule from CMakeLists because It just wouldn't work.

IsaccBarker added a commit to IsaccBarker/darling-docs that referenced this issue Feb 5, 2023
"This is a known issue when building with ninja. The workaround for this is to remove src/csu/libcsu.a and then try again." The path "src/csu/libcsu.a" is outdated, the new path is "src/external/csu/libcsu.a".
darlinghq/darling#915 (comment)
@bugaevc
Copy link
Member

bugaevc commented Jul 5, 2023

Before it gets lost, this is a bug in upstream CMake: https://gitlab.kitware.com/cmake/cmake/-/issues/24984

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

4 participants