This package serves as foundation for
BinaryBuilder.jl
.
juliapackaging / binarybuilderbase.jl Goto Github PK
View Code? Open in Web Editor NEWHome Page: https://juliapackaging.github.io/BinaryBuilderBase.jl/stable
License: MIT License
Home Page: https://juliapackaging.github.io/BinaryBuilderBase.jl/stable
License: MIT License
This package serves as foundation for
BinaryBuilder.jl
.
We already know that host and target may step on each other toes:
BinaryBuilderBase.jl/src/Runner.jl
Lines 586 to 590 in 30d056e
% julia -e 'using BinaryBuilderBase; BinaryBuilderBase.runshell(Platform("x86_64", "linux"; libc="musl", cxxstring_abi="cxx03");preferred_gcc_version=v"5")'
sandbox:${WORKSPACE} # echo 'int main() {return 0;}'|SUPER_VERBOSE=1 ${CC_FOR_BUILD} -x c -
ccache /opt/x86_64-linux-musl/bin/x86_64-linux-musl-gcc -D_GLIBCXX_USE_CXX11_ABI=0 -frandom-seed=0x5ccd0c16 -march=x86-64 -mtune=generic -x c -
Not sure there is much we can do within the current setup (maybe let us choose the C++ string ABI with an environment variable?), but opening this for future reference
As mose showed in #261
Clang doesn't find the libs when using arm + musl
% julia --compile=min -e 'using BinaryBuilderBase; BinaryBuilderBase.runshell(Platform("armv7l", "linux"; libc="musl"))'
sandbox:${WORKSPACE} # echo 'int test(){return 0;}' | clang -x c - -c -o test.o
clang-13: warning: argument unused during compilation: '-rtlib=libgcc' [-Wunused-command-line-argument]
clang-13: warning: argument unused during compilation: '-stdlib=libstdc++' [-Wunused-command-line-argument]
sandbox:${WORKSPACE} # echo 'int test(){return 0;}' | clang -x c - -shared -o test.so
/opt/arm-linux-musleabihf/bin/arm-linux-musleabihf-ld: cannot find crtbeginS.o: No such file or directory
/opt/arm-linux-musleabihf/bin/arm-linux-musleabihf-ld: cannot find -lgcc
/opt/arm-linux-musleabihf/bin/arm-linux-musleabihf-ld: cannot find -lgcc_s
/opt/arm-linux-musleabihf/bin/arm-linux-musleabihf-ld: cannot find -lgcc
/opt/arm-linux-musleabihf/bin/arm-linux-musleabihf-ld: cannot find -lgcc_s
/opt/arm-linux-musleabihf/bin/arm-linux-musleabihf-ld: cannot find crtendS.o: No such file or directory
clang-13: error: linker command failed with exit code 1 (use -v to see invocation)
sandbox:${WORKSPACE} # qfind /opt/${target}/${target} -name 'libgcc_s.*'
/opt/arm-linux-musleabihf/arm-linux-musleabihf/lib/libgcc_s.so
/opt/arm-linux-musleabihf/arm-linux-musleabihf/lib/libgcc_s.so.1
Undefined symbols for architecture x86_64:
"___isOSVersionAtLeast", referenced from:
_foo in test-4022da.o
ld: symbol(s) not found for architecture x86_64
clang-8: error: linker command failed with exit code 1 (use -v to see invocation)
Previous command exited with 1
vchuravy@odin ~/b/Y/test (vc/llvm_10_patch) [1]> cat bundled/test.c
int foo() {
/// that is a CLang extension
#if __has_builtin(__builtin_available)
if(__builtin_available(macOS 10.12, iOS 9.0, tvOS 9.0, watchOS 2.0, *)) {
return 256;
}
#endif
return 42;
}
int main() {
return foo();
}
vchuravy@odin ~/b/Y/test (vc/llvm_10_patch)> cat build_tarballs.jl
# Note that this script can accept some limited command-line arguments, run
# `julia build_tarballs.jl --help` to see a usage message.
using BinaryBuilder
name = "test"
version = v"0.1.0"
# Collection of sources required to complete build
sources = [
DirectorySource("./bundled")
]
# Bash recipe for building across all platforms
script = raw"""
clang -mmacosx-version-min=10.8 test.c -o test
"""
# These are the platforms we will build for by default, unless further
# platforms are passed in on the command line
platforms = [
MacOS(:x86_64),
]
# The products that we will ensure are always built
products = [
ExecutableProduct("test", :test)
]
# Dependencies that must be installed before this package can be built
dependencies = [
]
# Build the tarballs, and possibly a `build.jl` as well.
build_tarballs(ARGS, name, version, sources, script, platforms, products, dependencies;
preferred_gcc_version=v"7", preferred_llvm_version=v"8")
JuliaPackaging/Yggdrasil#1718 Used the new syntax Dependency("GMP_jll", v"6.1.2")
, which however results in inconsistent compat bounds between Project.toml
and the registry:
Project.toml
has a strict dependency on v6.1.2:
https://github.com/JuliaBinaryWrappers/Singular_jll.jl/blob/85929b66afd6fdd6b877ec60fe8de9fe12661b27/Project.toml#L18v6.1.2
: https://github.com/JuliaRegistries/General/pull/22388/files#diff-190a13cffbbf470e5e0c7f62902925bcR2The registry here is what we want and the only thing that actually matters, but it's probably better to make these two bounds consistent
BinaryBuilderBase.jl/src/Dependencies.jl
Line 164 in 0820b59
julia> versioninfo()
Julia Version 1.7.0-beta3
Commit e76c9dad42 (2021-07-07 08:12 UTC)
Platform Info:
OS: macOS (arm64-apple-darwin20.5.0)
CPU: Apple M1
WORD_SIZE: 64
LIBM: libopenlibm
LLVM: libLLVM-12.0.0 (ORCJIT, cyclone)
Environment:
JULIA_NUM_THREADS = 4
JULIA_PKG_SERVER = [private registry url]
It looks like Pkg.Types.RegistrySpec
is actually Pkg.RegistrySpec
for me.
I've tried this on the following:
julia> versioninfo()
Julia Version 1.6.1
Commit 6aaedecc44 (2021-04-23 05:59 UTC)
Platform Info:
OS: Linux (x86_64-pc-linux-gnu)
CPU: Intel(R) Xeon(R) Silver 4114 CPU @ 2.20GHz
WORD_SIZE: 64
LIBM: libopenlibm
LLVM: libLLVM-11.0.1 (ORCJIT, skylake-avx512)
Environment:
JULIA_NUM_THREADS = 8
and did not hit the issue, because it looks like Pkg.Types
exports RegistrySpec
in 1.6.1
I was using the wizard when I ran into this:
...
# Step 4: Select build products
ERROR: The build has produced no binary artifacts.
This is generally because an error occurred during the build
or because you forgot to `make install` or equivalent.
How would you like to proceed? (CTRL-C to exit)
> Return to build environment
Retry with a clean build environment
Edit the script
ArgumentError: '/private/var/folders/j7/fwm5mtz52_xdxds4f1rnhn9c0000gn/T/jl_c5U2g4/s7UYZWFT/artifacts/53e6c375d00db870bf575afc992c03c54cba1d7e' exists. `force=true` is required to remove '/private/var/folders/j7/fwm5mtz52_xdxds4f1rnhn9c0000gn/T/jl_c5U2g4/s7UYZWFT/artifacts/53e6c375d00db870bf575afc992c03c54cba1d7e' before copying.
Stacktrace:
[1] checkfor_mv_cp_cptree(src::String, dst::String, txt::String; force::Bool)
@ Base.Filesystem ./file.jl:312
[2] cp(src::String, dst::String; force::Bool, follow_symlinks::Bool)
@ Base.Filesystem ./file.jl:349
[3] cp
@ ./file.jl:349 [inlined]
[4] (::BinaryBuilderBase.var"#58#64"{Bool, Prefix, Vector{Pkg.Types.PackageSpec}, Platform, Vector{String}})()
@ BinaryBuilderBase ~/.julia/dev/BinaryBuilderBase/src/Prefix.jl:495
[5] activate(f::BinaryBuilderBase.var"#58#64"{Bool, Prefix, Vector{Pkg.Types.PackageSpec}, Platform, Vector{String}}, new_project::String)
@ Pkg.API ~/Development/Julia/x86/1.6/usr/share/julia/stdlib/v1.6/Pkg/src/API.jl:1433
[6] setup_dependencies(prefix::Prefix, dependencies::Vector{Pkg.Types.PackageSpec}, platform::Platform; verbose::Bool)
@ BinaryBuilderBase ~/.julia/dev/BinaryBuilderBase/src/Prefix.jl:433
[7] setup_dependencies
@ ~/.julia/dev/BinaryBuilderBase/src/Prefix.jl:407 [inlined]
[8] step4(state::BinaryBuilder.Wizard.WizardState, ur::BinaryBuilderBase.DockerRunner, platform::Platform, build_path::String, prefix::Prefix)
@ BinaryBuilder.Wizard ~/.julia/packages/BinaryBuilder/vDNXJ/src/wizard/interactive_build.jl:70
[9] step3_interactive(state::BinaryBuilder.Wizard.WizardState, prefix::Prefix, platform::Platform, ur::BinaryBuilderBase.DockerRunner, build_path::String, artifact_paths::Vector{String})
@ BinaryBuilder.Wizard ~/.julia/packages/BinaryBuilder/vDNXJ/src/wizard/interactive_build.jl:414
[10] step34(state::BinaryBuilder.Wizard.WizardState)
@ BinaryBuilder.Wizard ~/.julia/packages/BinaryBuilder/vDNXJ/src/wizard/interactive_build.jl:542
[11] run_wizard(state::Nothing)
@ BinaryBuilder.Wizard ~/.julia/packages/BinaryBuilder/vDNXJ/src/Wizard.jl:104
[12] run_wizard()
@ BinaryBuilder.Wizard ~/.julia/packages/BinaryBuilder/vDNXJ/src/Wizard.jl:87
[13] top-level scope
@ REPL[3]:1
[14] eval(m::Module, e::Any)
@ Core ./boot.jl:360
[15] eval_user_input(ast::Any, backend::REPL.REPLBackend)
@ REPL ~/Development/Julia/x86/1.6/usr/share/julia/stdlib/v1.6/REPL/src/REPL.jl:139
[16] repl_backend_loop(backend::REPL.REPLBackend)
@ REPL ~/Development/Julia/x86/1.6/usr/share/julia/stdlib/v1.6/REPL/src/REPL.jl:200
[17] start_repl_backend(backend::REPL.REPLBackend, consumer::Any)
@ REPL ~/Development/Julia/x86/1.6/usr/share/julia/stdlib/v1.6/REPL/src/REPL.jl:185
[18] run_repl(repl::REPL.AbstractREPL, consumer::Any; backend_on_current_task::Bool)
@ REPL ~/Development/Julia/x86/1.6/usr/share/julia/stdlib/v1.6/REPL/src/REPL.jl:317
[19] run_repl(repl::REPL.AbstractREPL, consumer::Any)
@ REPL ~/Development/Julia/x86/1.6/usr/share/julia/stdlib/v1.6/REPL/src/REPL.jl:305
[20] (::Base.var"#867#869"{Bool, Bool, Bool})(REPL::Module)
@ Base ./client.jl:387
[21] #invokelatest#2
@ ./essentials.jl:707 [inlined]
[22] invokelatest
@ ./essentials.jl:706 [inlined]
[23] run_main_repl(interactive::Bool, quiet::Bool, banner::Bool, history_file::Bool, color_set::Bool)
@ Base ./client.jl:372
[24] exec_options(opts::Base.JLOptions)
@ Base ./client.jl:302
[25] _start()
@ Base ./client.jl:485
WizardState [step3]
For JuliaPackaging/Yggdrasil#1694 it would be useful to be able to download the host version of LLVM_full_jll
so that I can use llvm-config
as the LLVM_CONFIG_HOST
and get the right build flags.
When we build a package with a GitSource
on Yggdrasil, each runner calls download_source
and in particular the line
BinaryBuilderBase.jl/src/Sources.jl
Line 165 in 2022194
When we build in parallel we probably need a mechanism to tell to the parallel runners that there is no need refetch the repository again. Edit: even better, we can probably use LibGit2.iscommit
to check whether the repo has already the commit, if so, no need to fetch again
We recently started observing a new bug in the FreeBSD toolchain with GCC 4 and 5:
% julia -e 'using BinaryBuilderBase; BinaryBuilderBase.runshell(Platform("x86_64", "freebsd"); preferred_gcc_version=v"4")'
sandbox:${WORKSPACE} # make -C /usr/share/testsuite/
make: Entering directory '/usr/share/testsuite'
make[1]: Entering directory '/usr/share/testsuite/c/dyn_link'
x86_64-unknown-freebsd11.1-cc -shared -o /tmp/testsuite/x86_64-unknown-freebsd11.1/c/dyn_link/libfoo/libfoo.so -fPIC -g -O2 -lm libfoo/libfoo.c
x86_64-unknown-freebsd11.1-cc -o /tmp/testsuite/x86_64-unknown-freebsd11.1/c/dyn_link/dyn_link -I/usr/share/testsuite/c/dyn_link/libfoo -fPIC -g -O2 -Wl,-z,origin -Wl,-rpath,$ORIGIN/libfoo -L/tmp/testsuite/x86_64-unknown-freebsd11.1/c/dyn_link/libfoo -lfoo dyn_link.c
make[1]: Leaving directory '/usr/share/testsuite/c/dyn_link'
make[1]: Entering directory '/usr/share/testsuite/c/hello_world'
x86_64-unknown-freebsd11.1-cc -o /tmp/testsuite/x86_64-unknown-freebsd11.1/c/hello_world/hello_world -g -O2 hello_world.c
make[1]: Leaving directory '/usr/share/testsuite/c/hello_world'
make[1]: Entering directory '/usr/share/testsuite/c/openmp'
gcc -o /tmp/testsuite/x86_64-unknown-freebsd11.1/c/openmp/openmp -g -O2 -fopenmp openmp.c
make[1]: Leaving directory '/usr/share/testsuite/c/openmp'
make[1]: Entering directory '/usr/share/testsuite/cxx/dyn_link'
x86_64-unknown-freebsd11.1-c++ -shared -o /tmp/testsuite/x86_64-unknown-freebsd11.1/cxx/dyn_link/librepeater/librepeater.so -fPIC -g -O2 -lm librepeater/librepeater.cc
x86_64-unknown-freebsd11.1-c++ -o /tmp/testsuite/x86_64-unknown-freebsd11.1/cxx/dyn_link/dyn_link -I/usr/share/testsuite/cxx/dyn_link/librepeater -fPIC -g -O2 -Wl,-z,origin -Wl,-rpath,$ORIGIN/librepeater -L/tmp/testsuite/x86_64-unknown-freebsd11.1/cxx/dyn_link/librepeater -lrepeater dyn_link.cc
/opt/x86_64-unknown-freebsd11.1/bin/x86_64-unknown-freebsd11.1-ld: /tmp/dyn_link-4e028c.o: unrecognized relocation (0x2a) in section `.text'
/opt/x86_64-unknown-freebsd11.1/bin/x86_64-unknown-freebsd11.1-ld: final link failed: Bad value
clang-12: error: linker command failed with exit code 1 (use -v to see invocation)
make[1]: *** [Makefile:8: /tmp/testsuite/x86_64-unknown-freebsd11.1/cxx/dyn_link/dyn_link] Error 1
make[1]: Leaving directory '/usr/share/testsuite/cxx/dyn_link'
make: *** [Makefile:45: build-project-cxx-dyn_link] Error 2
make: Leaving directory '/usr/share/testsuite'
sandbox:${WORKSPACE} #
You can observe the same with preferred_gcc_version=v"5"
, but no other versions. I'm not really sure why this depends on the version of GCC, maybe that's a proxy for something like binutils? Also, I have no clue why we're seeing this now (v0.6.10 currently), I believe this wasn't an issue until some time ago and we didn't change anything in FreeBSD specifically lately. I'll try to bisect the issue.
Currently FileSource's hash is hard-coded to be SHA256, however, several projects publish different kinds of hashes (SHA1, commonly MD5, etc). For example, NVIDIA provides MD5sums for the CUDA installers: https://developer.download.nvidia.com/compute/cuda/11.7.0/docs/sidebar/md5sum.txt. It'd be nice if we could re-use these, as I currently have to download about 10GB of CUDA binaries before updating the package :-)
As a quick hack, I guess we could just look at the length of the hash to determine its type (64=SHA256, 40=SHA1, 32=MD5).
MutableArtifacts were always a kludge due to the lack of scratch spaces. We should write out UID-remapped squashfs images to scratch spaces (namespaced appropriately to avoid interfering with other squashfs images).
In
BinaryBuilderBase.jl/src/Rootfs.jl
Lines 164 to 166 in c67ccbe
x86_64-linux-musl-cxx11
, GCC v5+) and the target also when the target is x86_64-linux-musl-cxx03
with preferred GCC v4These are some of the issues of our Clang wrapper for Windows:
% julia --compile=min -e 'using BinaryBuilderBase; BinaryBuilderBase.runshell(Platform("x86_64", "windows"))'
sandbox:${WORKSPACE} # echo 'int main(){return 0;}' | clang -x c -
clang-13: warning: argument unused during compilation: '--gcc-toolchain=/opt/x86_64-w64-mingw32' [-Wunused-command-line-argument]
clang-13: warning: argument unused during compilation: '-stdlib=libstdc++' [-Wunused-command-line-argument]
/opt/x86_64-w64-mingw32/bin/x86_64-w64-mingw32-ld: cannot find -lgcc
/opt/x86_64-w64-mingw32/bin/x86_64-w64-mingw32-ld: cannot find -lgcc_eh
/opt/x86_64-w64-mingw32/bin/x86_64-w64-mingw32-ld: cannot find -lgcc
/opt/x86_64-w64-mingw32/bin/x86_64-w64-mingw32-ld: cannot find -lgcc_eh
clang-13: error: linker command failed with exit code 1 (use -v to see invocation)
sandbox:${WORKSPACE} # echo -e '#include <limits>\nint main(){return 0;}' | clang -x c++ -
clang-13: warning: argument unused during compilation: '--gcc-toolchain=/opt/x86_64-w64-mingw32' [-Wunused-command-line-argument]
<stdin>:1:10: fatal error: 'limits' file not found
#include <limits>
^~~~~~~~
1 error generated.
We actually already do
BinaryBuilderBase.jl/src/Runner.jl
Lines 318 to 319 in 4b21cde
I tried to address this issue in #247, but it's a horrible ad-hoc kludge. I opened this issue because I feel like we should be able to make this work more nicely than putting a bunch of random -I...
and -L...
arguments.
On a machine without zst
installed (sudo apt install zstd
), ArchiveSource
fails to extract and the corresponding build script errors without a clue why. I suggest either an error message is spit out or, even better, include this compression standard since ArciveSource
already accepts zst
's.
The choose_shards
function is rather complicated. Among its issues it computes the GCC_build
for the host and the target together, which for example fails for
BinaryBuilderBase.runshell(Platform("x86_64", "linux"; libc="musl", cxxstring_abi="cxx03");preferred_gcc_version=v"4")
GCC v4.8 is chosen for both of them, when it should choose v4.8 for the target and v5 for the host (with #82 we always require C++11 string ABI for the host). The same happens for the target Platform("x86_64", "linux"; libc="glibc", cxxstring_abi="cxx03")
and I have an even harder time to understand why, since the two platforms are strictly speaking different (maybe the same version of GCC is always chosen?). See also #82 (comment), which is what we want to eventually achieve
I've run locally this builder for OpenAL
, which depends only on alsa_jll
, Ogg_jll
and CompilerSupportLibraries_jll
. None of them has further dependencies, but I've got installed in the build environment also completely unrelated packages, like HDF5_jll
, FFTW_jll
, MKL_jll
, all MPI flavours, Zlib_jll
, etc.... I realised these packages are all in my global environment. After the build I found that my global environment has alsa_jll
, Ogg_jll
and CompilerSupportLibraries_jll
installed.
I've bisected the issue to #36.
This issue is used to trigger TagBot; feel free to unsubscribe.
If you haven't already, you should update your TagBot.yml
to include issue comment triggers.
Please see this post on Discourse for instructions and more details.
If you'd like for me to do this for you, comment TagBot fix
on this issue.
I'll open a PR within a few hours, please be patient!
sccache is a ccache-like compiler caching tool, written in Rust and supporting Rust in addition to C/C++. We may consider using it instead/in addition to ccache.
Downloading artifact: PlatformSupport-x86_64-apple-darwin14.v2021.1.28.x86_64-linux-musl.unpacked
[ Info: Unpacking /tmp/jl_wCSiqs-download.gz into /home/keno/.julia/artifacts/jl_LwUaEq...
โ Error: Tree Hash Mismatch!
โ Expected git-tree-sha1: 3d1ef3b48fbf4b8655278870a98ab22fbbc43d4f
โ Calculated git-tree-sha1: e75f8520df3f7e9a7579279c78c81bf3b90f78b9
Downloaded artifact: PlatformSupport-x86_64-apple-darwin14.v2021.1.28.x86_64-linux-musl.unpacked
Downloading artifact: PlatformSupport-x86_64-apple-darwin14.v2021.1.28.x86_64-linux-musl.unpacked
[ Info: No hash cache found
[ Info: Calculated hash 38d66fbcb5f9c6c9e6343280e605f55dfc2c346cfec1bf864bd08964e747de99 for file /tmp/jl_g1P0Rp-download.gz
[ Info: Unpacking /tmp/jl_g1P0Rp-download.gz into /home/keno/.julia/artifacts/jl_7jNHDq...
โ Error: Tree Hash Mismatch!
โ Expected git-tree-sha1: 3d1ef3b48fbf4b8655278870a98ab22fbbc43d4f
โ Calculated git-tree-sha1: e75f8520df3f7e9a7579279c78c81bf3b90f78b9
Downloaded artifact: PlatformSupport-x86_64-apple-darwin14.v2021.1.28.x86_64-linux-musl.unpacked
Similarly to https://github.com/JuliaLang/Statistics.jl/issues/1, this is the script I used to extract the history of the relevant files in BinaryBuilder.jl
:
#!/bin/sh
NEWPACKAGE="BinaryBuilderBase"
git clone -b master --single-branch --no-tags BinaryBuilder "${NEWPACKAGE}"
cd "${NEWPACKAGE}"
# https://ptc-it.de/move-files-to-new-repo-in-git/#
git filter-branch --prune-empty --index-filter \
'git ls-tree -r -z --name-only --full-tree ${GIT_COMMIT} | \
grep -z -v "Artifacts.toml" | \
grep -z -v "src/compat.jl" | \
grep -z -v "src/Sources.jl" | \
grep -z -v "src/Dependencies.jl" | \
grep -z -v "src/Prefix.jl" | \
grep -z -v "src/Products.jl" | \
grep -z -v "src/Platforms.jl" | \
grep -z -v "src/Runner.jl" | \
grep -z -v "src/Rootfs.jl" | \
grep -z -v "src/squashfs_utils.jl" | \
grep -z -v "src/UserNSRunner.jl" | \
grep -z -v "src/DockerRunner.jl" | \
grep -z -v "test/runtests.jl" | \
grep -z -v "test/basic.jl" | \
xargs -0 -r git rm --cached -r' -f -- --all
# https://stackoverflow.com/questions/9803294/prune-empty-merge-commits-from-history-in-git-repository
git filter-branch --prune-empty --parent-filter \
'sed "s/-p //g" | xargs -r git show-branch --independent | sed "s/\</-p /g"'
# Squeeze repository size
# https://help.github.com/en/github/authenticating-to-github/removing-sensitive-data-from-a-repository
git for-each-ref --format="delete %(refname)" refs/original | git update-ref --stdin && \
git reflog expire --all --expire=now && \
git gc --prune=now --aggressive
The docstring of package
BinaryBuilderBase.jl/src/Prefix.jl
Lines 135 to 148 in 2de8d4f
audit
, but this isn't trueThis should work according to the docstring of LibraryProduct:
LibraryProduct("libfoo", :libfoo; dir_paths=["lib/plugins"])
But instead it gives an error.
The undocumented variants LibraryProduct("libfoo", :libfoo, ["lib/plugins"])
or LibraryProduct("libfoo", :libfoo, "lib/plugins")
do work.
Should the docstring be changed?
I am trying to build openPMD_api
with this command:
julia --color=yes build_tarballs.jl --debug --verbose --deploy=local x86_64-apple-darwin-julia_version+1.7.0-mpi+mpitrampoline
Although I am using mpi+mpitrampoline
, I find that $prefix/include/mpi.h
is from MPICH, not from MPItrampoline.
This is my build_tarballs.jl
.
Is there a mistake in my script?
The same setup is working fine for the package ADIOS2
. The main difference is that ADIOS2 does not depend on any other package that also depends on MPI. Maybe BinaryBuilder installs a wrong version of ADIOS2, one which depends on MPICH instead of MPItrampoline?
It would be nice if we had a kwarg that let us rename the directory. We have
unpack_target
, but that would result inwine/wine-staging
.
Originally posted by @Keno in JuliaPackaging/Yggdrasil#4127 (comment)
I'm not sure this is how this was meant to work, I believe we wanted unpack_target="wine"
to clone the repo to /workspace/srcdir/wine
. For example this is what ArchiveSource
does.
I was trying to download and run rr
inside BinaryBuilder, and one of the missing pieces that @staticfloat and I found was that /lib64/libgcc_s.so
was missing. Workaround was to download the x86_64-linux-glibc
environment and add that to the LD_LIBRARY_PATH
.
When it will become available in a stable version of Rust we support, it'd be nice to automatically enable the sparse registry: https://blog.rust-lang.org/2022/06/22/sparse-registry-testing.html. Updating the registry always takes an overly large fraction of the build process of Rust packages, in addition to the fact we can't cache build outputs (related issue: #186).
Building aarch64-apple-darwin libraries with Docker and native aarch64 Julia 1.7.1 result in an error.
I think the issue is that PlatformSupport has not been built to aarch64-apple-darwin as I can only find the following x86-apple-darwin PlatformSupport _jll: https://github.com/JuliaBinaryWrappers?q=PlatformSupport+apple&type=all&language=&sort=
Command:
julia build_tarballs.jl aarch64-apple-darwin
Error:
ERROR: LoadError: MethodError: no method matching artifact_exists(::Nothing)
Closest candidates are:
artifact_exists(::Base.SHA1; honor_overrides) at /Applications/Julia-1.7.app/Contents/Resources/julia/share/julia/stdlib/v1.7/Artifacts/src/Artifacts.jl:252
Stacktrace:
[1] _broadcast_getindex_evalf
@ ./broadcast.jl:670 [inlined]
[2] _broadcast_getindex
@ ./broadcast.jl:643 [inlined]
[3] getindex
@ ./broadcast.jl:597 [inlined]
[4] copy
@ ./broadcast.jl:899 [inlined]
[5] materialize(bc::Base.Broadcast.Broadcasted{Base.Broadcast.DefaultArrayStyle{1}, Nothing, typeof(Artifacts.artifact_exists), Tuple{Vector{Nothing}}})
@ Base.Broadcast ./broadcast.jl:860
[6] macos_sdk_already_installed()
@ BinaryBuilderBase ~/.julia/packages/BinaryBuilderBase/UqKXf/src/Rootfs.jl:352
[7] mount(cs::BinaryBuilderBase.CompilerShard, build_prefix::String; verbose::Bool)
@ BinaryBuilderBase ~/.julia/packages/BinaryBuilderBase/UqKXf/src/Rootfs.jl:234
[8] JuliaPackaging/Yggdrasil#41
@ ./broadcast.jl:1283 [inlined]
[9] _broadcast_getindex_evalf
@ ./broadcast.jl:670 [inlined]
[10] _broadcast_getindex
@ ./broadcast.jl:643 [inlined]
[11] getindex
@ ./broadcast.jl:597 [inlined]
[12] macro expansion
@ ./broadcast.jl:961 [inlined]
[13] macro expansion
@ ./simdloop.jl:77 [inlined]
[14] copyto!(dest::Vector{String}, bc::Base.Broadcast.Broadcasted{Nothing, Tuple{Base.OneTo{Int64}}, Base.Broadcast.var"#41#42"{Base.Pairs{Symbol, Bool, Tuple{Symbol}, NamedTuple{(:verbose,), Tuple{Bool}}}, typeof(BinaryBuilderBase.mount)}, Tuple{Vector{BinaryBuilderBase.CompilerShard}, Base.RefValue{String}}})
@ Base.Broadcast ./broadcast.jl:960
[15] copyto!
@ ./broadcast.jl:913 [inlined]
[16] copy
@ ./broadcast.jl:885 [inlined]
[17] materialize
@ ./broadcast.jl:860 [inlined]
[18] #mount_shards#279
@ ~/.julia/packages/BinaryBuilderBase/UqKXf/src/Rootfs.jl:970 [inlined]
[19] run(dr::BinaryBuilderBase.DockerRunner, cmd::Cmd, logger::IOStream; verbose::Bool, tee_stream::Base.DevNull)
@ BinaryBuilderBase ~/.julia/packages/BinaryBuilderBase/UqKXf/src/DockerRunner.jl:145
[20] (::BinaryBuilder.var"#26#30"{Bool, Base.Pairs{Symbol, VersionNumber, Tuple{Symbol}, NamedTuple{(:preferred_gcc_version,), Tuple{VersionNumber}}}, String, BinaryBuilderBase.DockerRunner, BinaryBuilder.BuildTimer})(io::IOStream)
@ BinaryBuilder ~/.julia/dev/BinaryBuilder/src/AutoBuild.jl:822
[21] JuliaPackaging/Yggdrasil#321
@ ~/.julia/packages/BinaryBuilderBase/UqKXf/src/utils.jl:13 [inlined]
[22] open(::BinaryBuilderBase.var"#321#322"{BinaryBuilder.var"#26#30"{Bool, Base.Pairs{Symbol, VersionNumber, Tuple{Symbol}, NamedTuple{(:preferred_gcc_version,), Tuple{VersionNumber}}}, String, BinaryBuilderBase.DockerRunner, BinaryBuilder.BuildTimer}}, ::String, ::Vararg{String}; kwargs::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
@ Base ./io.jl:330
[23] open
@ ./io.jl:328 [inlined]
[24] with_logfile(f::BinaryBuilder.var"#26#30"{Bool, Base.Pairs{Symbol, VersionNumber, Tuple{Symbol}, NamedTuple{(:preferred_gcc_version,), Tuple{VersionNumber}}}, String, BinaryBuilderBase.DockerRunner, BinaryBuilder.BuildTimer}, logfile::String)
@ BinaryBuilderBase ~/.julia/packages/BinaryBuilderBase/UqKXf/src/utils.jl:12
[25] with_logfile(f::Function, prefix::Prefix, name::String; subdir::String)
@ BinaryBuilderBase ~/.julia/packages/BinaryBuilderBase/UqKXf/src/utils.jl:4
[26] autobuild(dir::AbstractString, src_name::AbstractString, src_version::VersionNumber, sources::Vector{<:BinaryBuilderBase.AbstractSource}, script::AbstractString, platforms::Vector, products::Vector{<:Product}, dependencies::Vector{<:BinaryBuilderBase.AbstractDependency}; verbose::Bool, debug::Bool, skip_audit::Bool, ignore_audit_errors::Bool, autofix::Bool, code_dir::Union{Nothing, String}, require_license::Bool, kwargs::Base.Pairs{Symbol, V, Tuple{Vararg{Symbol, N}}, NamedTuple{names, T}} where {V, N, names, T<:Tuple{Vararg{Any, N}}})
@ BinaryBuilder ~/.julia/dev/BinaryBuilder/src/AutoBuild.jl:814
[27] build_tarballs(ARGS::Any, src_name::Any, src_version::Any, sources::Any, script::Any, platforms::Any, products::Any, dependencies::Any; julia_compat::String, kwargs::Base.Pairs{Symbol, V, Tuple{Vararg{Symbol, N}}, NamedTuple{names, T}} where {V, N, names, T<:Tuple{Vararg{Any, N}}})
@ BinaryBuilder ~/.julia/dev/BinaryBuilder/src/AutoBuild.jl:321
[28] top-level scope
@ ~/git/Yggdrasil/Q/QLever/build_tarballs.jl:107
in expression starting at /Users/jpslewis/git/Yggdrasil/Q/QLever/build_tarballs.jl:107
sandbox:${WORKSPACE}/srcdir/p4est-2.2 # cat conftest.f
program main
open(unit=9,file='conftest.out')
close(unit=9)
end
sandbox:${WORKSPACE}/srcdir/p4est-2.2 # ${FC_FOR_BUILD} -o conftest conftest.f
sandbox:${WORKSPACE}/srcdir/p4est-2.2 # ./conftest
Error relocating /usr/lib/csl-glibc-x86_64/libquadmath.so.0: register_printf_specifier: symbol not found
Error relocating /usr/lib/csl-glibc-x86_64/libquadmath.so.0: register_printf_type: symbol not found
Error relocating /usr/lib/csl-glibc-x86_64/libquadmath.so.0: register_printf_modifier: symbol not found
Spotted in JuliaPackaging/Yggdrasil#1749
% julia --compile=min -e 'using BinaryBuilderBase; BinaryBuilderBase.runshell(Platform("aarch64", "macos"))'
sandbox:${WORKSPACE} # ${target}-objdump
/opt/bin/aarch64-apple-darwin20-libgfortran5-cxx11/aarch64-apple-darwin20-objdump: line 5: /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-objdump: No such file or directory
sandbox:${WORKSPACE} # ls /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-*
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-ObjectDump /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-install_name_tool
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-ar /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-ld
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-as /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-libtool
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-bitcode_strip /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-lipo
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-c++ /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-lto-dump
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-check_dylib /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-machocheck
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-checksyms /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-makerelocs
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-cmpdylib /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-mtoc
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-codesign_allocate /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-mtor
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-cpp /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-nm
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-ctf_insert /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-nmedit
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-dyldinfo /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-otool
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-g++ /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-pagestuff
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-gcc /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-ranlib
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-gcc-12.0.1 /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-redo_prebinding
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-gcc-ar /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-seg_addr_table
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-gcc-nm /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-seg_hack
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-gcc-ranlib /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-segedit
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-gcov /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-size
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-gcov-dump /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-strings
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-gcov-tool /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-strip
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-gfortran /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-unwinddump
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-indr /opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-vtool
/opt/aarch64-apple-darwin20/bin/aarch64-apple-darwin20-inout
Based on the following Dependency
, with Julia 1.6, the correct non-official binary is picked up, with Julia 1.7, the canonical JuliaBinaryWrappers
version is installed.
Dependency(PackageSpec(; name = "boost_jll", uuid = "28df3c45-c428-5900-9ff8-a3135698ca75", url = "https://github.com/jeremiahpslewis/boost_jll.jl.git")),
https://github.com/jeremiahpslewis/Yggdrasil/blob/jpsl/qlever_jll/Q/QLever/build_tarballs.jl#L104
For the standard build command:
julia build_tarballs.jl --verbose --debug x86_64-linux-gnu
Tested on Julia 1.6 and there are no issues.
Dependency(PackageSpec(; name = "boost_jll", uuid = "28df3c45-c428-5900-9ff8-a3135698ca75", path = "/root/.julia/dev/boost_jll")),
[3f19e933] + p7zip_jll v16.2.1+2
ERROR: LoadError: MethodError: no method matching get_last_stdlibs(::Nothing)
Closest candidates are:
get_last_stdlibs(::VersionNumber) at ~/julia-1.7.1/share/julia/stdlib/v1.7/Pkg/src/Types.jl:416
Stacktrace:
[1] stdlib_version(uuid::Base.UUID, julia_version::Nothing)
@ BinaryBuilderBase ~/.julia/dev/BinaryBuilderBase/src/compat.jl:23
[2] (::BinaryBuilderBase.var"#88#94"{Bool, Prefix, Vector{Pkg.Types.PackageSpec}, Platform, Vector{String}, Vector{String}})()
@ BinaryBuilderBase ~/.julia/dev/BinaryBuilderBase/src/Prefix.jl:598
[3] activate(f::BinaryBuilderBase.var"#88#94"{Bool, Prefix, Vector{Pkg.Types.PackageSpec}, Platform, Vector{String}, Vector{String}}, new_project::String)
@ Pkg.API ~/julia-1.7.1/share/julia/stdlib/v1.7/Pkg/src/API.jl:1599
[4] setup_dependencies(prefix::Prefix, dependencies::Vector{Pkg.Types.PackageSpec}, platform::Platform; verbose::Bool)
@ BinaryBuilderBase ~/.julia/dev/BinaryBuilderBase/src/Prefix.jl:565
[5] (::BinaryBuilder.var"#setup_deps#27")(f::typeof(BinaryBuilderBase.is_target_dependency), prefix::Prefix, dependencies::Vector{BinaryBuilderBase.AbstractDependency}, platform::Platform, verbose::Bool)
@ BinaryBuilder ~/.julia/packages/BinaryBuilder/FL6q3/src/AutoBuild.jl:754
[6] autobuild(dir::AbstractString, src_name::AbstractString, src_version::VersionNumber, sources::Vector{<:BinaryBuilderBase.AbstractSource}, script::AbstractString, platforms::Vector, products::Vector{<:Product}, dependencies::Vector{<:BinaryBuilderBase.AbstractDependency}; verbose::Bool, debug::Bool, skip_audit::Bool, ignore_audit_errors::Bool, autofix::Bool, code_dir::Union{Nothing, String}, require_license::Bool, kwargs::Base.Pairs{Symbol, V, Tuple{Vararg{Symbol, N}}, NamedTuple{names, T}} where {V, N, names, T<:Tuple{Vararg{Any, N}}})
@ BinaryBuilder ~/.julia/packages/BinaryBuilder/FL6q3/src/AutoBuild.jl:757
[7] build_tarballs(ARGS::Any, src_name::Any, src_version::Any, sources::Any, script::Any, platforms::Any, products::Any, dependencies::Any; julia_compat::String, kwargs::Base.Pairs{Symbol, V, Tuple{Vararg{Symbol, N}}, NamedTuple{names, T}} where {V, N, names, T<:Tuple{Vararg{Any, N}}})
@ BinaryBuilder ~/.julia/packages/BinaryBuilder/FL6q3/src/AutoBuild.jl:321
[8] top-level scope
@ ~/Yggdrasil/Q/QLever/build_tarballs.jl:114
This throws an error, if a varname
conflicts with any name in Base. This doesn't make a lot of sense to me, since the identifier may not even be exported by Base, and even if it is exported from Base, it can still just be shadowed by the JLL. (Perhaps JLLWrappers would have to be a bit more careful with macro hygiene, so that shadowing a Base function never affects anything else.) I therefore propose making this just a warning instead.
Our new shiny Rust 1.57.0 toolchain passes basic tests on all platforms, but it fails to build librsvg on non-x86_64 Musl platforms, because libraries need libc.musl-<ARCH>.so.1
, but we don't have such file in our current non-x86_64 Musl toolchains:
% julia -e 'using BinaryBuilderBase; BinaryBuilderBase.runshell(Platform("aarch64", "linux"; libc="musl"))'
sandbox:${WORKSPACE} # echo 'int main(){return 0;}' | cc -x c -; readelf -d a.out | grep NEEDED
0x0000000000000001 (NEEDED) Shared library: [libc.musl-aarch64.so.1]
sandbox:${WORKSPACE} # qfind / -name "libc.*"
/lib/libc.musl-x86_64.so.1
/lib/libc.so.6
/lib64/libc.so.6
/workspace/.mounts/GCCBootstrap-x86_64-linux-musl.v6.1.0.x86_64-linux-musl.squashfs/x86_64-linux-musl/sys-root/usr/lib/libc.a
/workspace/.mounts/GCCBootstrap-x86_64-linux-musl.v6.1.0.x86_64-linux-musl.squashfs/x86_64-linux-musl/sys-root/usr/lib/libc.so
/workspace/.mounts/GCCBootstrap-aarch64-linux-musl.v6.1.0.x86_64-linux-musl.squashfs/aarch64-linux-musl/sys-root/usr/lib/libc.a
/workspace/.mounts/GCCBootstrap-aarch64-linux-musl.v6.1.0.x86_64-linux-musl.squashfs/aarch64-linux-musl/sys-root/usr/lib/libc.so
/opt/aarch64-linux-musl/aarch64-linux-musl/sys-root/usr/lib/libc.a
/opt/aarch64-linux-musl/aarch64-linux-musl/sys-root/usr/lib/libc.so
/opt/x86_64-linux-musl/x86_64-linux-musl/sys-root/usr/lib/libc.a
/opt/x86_64-linux-musl/x86_64-linux-musl/sys-root/usr/lib/libc.so
However the libc.so
file has the correct soname (correctly set in the GCC build recipe: [1] and [2]):
sandbox:${WORKSPACE} # readelf -d /opt/aarch64-linux-musl/aarch64-linux-musl/sys-root/usr/lib/libc.so | grep SONAME
0x000000000000000e (SONAME) Library soname: [libc.musl-aarch64.so.1]
The log of librsvg shows
[15:34:43] error: linking with `aarch64-linux-musl-gcc` failed: exit status: 1
[15:34:43] |
[15:34:43] = note: "aarch64-linux-musl-gcc" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/self-contained/crt1.o" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/self-contained/crti.o" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/self-contained/crtbegin.o" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/rsvg_convert-546b0b5de5111dee.rsvg_convert.6fd34acb-cgu.0.rcgu.o" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/rsvg_convert-546b0b5de5111dee.rsvg_convert.6fd34acb-cgu.1.rcgu.o" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/rsvg_convert-546b0b5de5111dee.rsvg_convert.6fd34acb-cgu.10.rcgu.o" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/rsvg_convert-546b0b5de5111dee.rsvg_convert.6fd34acb-cgu.11.rcgu.o" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/rsvg_convert-546b0b5de5111dee.rsvg_convert.6fd34acb-cgu.12.rcgu.o" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/rsvg_convert-546b0b5de5111dee.rsvg_convert.6fd34acb-cgu.13.rcgu.o" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/rsvg_convert-546b0b5de5111dee.rsvg_convert.6fd34acb-cgu.14.rcgu.o" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/rsvg_convert-546b0b5de5111dee.rsvg_convert.6fd34acb-cgu.15.rcgu.o" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/rsvg_convert-546b0b5de5111dee.rsvg_convert.6fd34acb-cgu.2.rcgu.o" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/rsvg_convert-546b0b5de5111dee.rsvg_convert.6fd34acb-cgu.3.rcgu.o" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/rsvg_convert-546b0b5de5111dee.rsvg_convert.6fd34acb-cgu.4.rcgu.o" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/rsvg_convert-546b0b5de5111dee.rsvg_convert.6fd34acb-cgu.5.rcgu.o" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/rsvg_convert-546b0b5de5111dee.rsvg_convert.6fd34acb-cgu.6.rcgu.o" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/rsvg_convert-546b0b5de5111dee.rsvg_convert.6fd34acb-cgu.7.rcgu.o" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/rsvg_convert-546b0b5de5111dee.rsvg_convert.6fd34acb-cgu.8.rcgu.o" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/rsvg_convert-546b0b5de5111dee.rsvg_convert.6fd34acb-cgu.9.rcgu.o" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/rsvg_convert-546b0b5de5111dee.5addkaf2o4nmsl3h.rcgu.o" "-Wl,--as-needed" "-L" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps" "-L" "/workspace/srcdir/librsvg-2.52.4/target/release/deps" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/workspace/destdir/lib" "-L" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib" "-Wl,-Bstatic" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libchrono-c792d6f4998d4088.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/liblibrsvg-ba289cb112842c58.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libpangocairo-fc8293f0172fda0c.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libpango_cairo_sys-2d1aac6d528cf02d.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/librctree-e2c0ed45f4ef179a.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libxml5ever-dadfca9b4682f2c0.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libtime-6e8b4bba84f95675.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libencoding-b94e41ba286c7fd5.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libencoding_index_tradchinese-98eac038e022c7cb.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libencoding_index_simpchinese-aabae2f38f41c9c5.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libencoding_index_japanese-a997501dd864530b.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libencoding_index_korean-791f380a99b6316a.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libencoding_index_singlebyte-1fd5613b3670cd08.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/librgb-0b3442b02f1a9aa9.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libbytemuck-209bba03124c4c37.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libitertools-f9ac0928a6fe0b9d.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libcast-c3cf1dbc9c6860e4.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/librayon-c1d5ad16918680f8.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/librayon_core-d848dbae3986e26c.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libnum_cpus-9a40e94cead12246.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libcrossbeam_deque-8d0fa79c6475221f.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libcrossbeam_epoch-fd6aa70bb6209d64.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libmemoffset-a04089e691c7b711.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libcrossbeam_channel-89dd2edc7901e78f.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libcrossbeam_utils-05081808448320d8.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libeither-9e8a4c701192e89a.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libnalgebra-da67ea8ae8b72d88.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libnum_rational-05f04cf100d735c9.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libnum_integer-76b449b170c687e8.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libtypenum-5434f692a4e5da1f.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libsimba-cf5536ee80743066.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libnum_complex-126a881f4609710a.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libmatrixmultiply-1c186a9acdef3a20.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/librawpointer-2ae42a7d111148cd.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libapprox-5e1018a268020f02.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libcairo-6fd585d0d19e9d35.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libcairo_sys-4ad94b885c848461.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libpango-faac5cc4ef98ebf2.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libpango_sys-cfdec11c1fbbbdae.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libselectors-0cc53b6a5e264930.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libthin_slice-216012155bf23b90.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libservo_arc-a0db8c4c06d47c48.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libstable_deref_trait-f7af783407e33764.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libnodrop-58049dfc896a484e.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/liblog-5dfc53d734091479.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libfxhash-5ca1277a4e2e6501.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libbyteorder-8e6e2e93c0e40d80.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libdata_url-db131dc6a49c72b5.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libgdk_pixbuf-b5cf945ac8fb9f48.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libgdk_pixbuf_sys-681f0c0831bbbda5.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/liburl-da57bde2b7245447.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libidna-196c43a13d1eca57.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libunicode_normalization-3edebca0e39827d6.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libtinyvec-db493d2c98876320.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libtinyvec_macros-0d8a11e787a947fe.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libunicode_bidi-5f51a6c973e6ed74.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libform_urlencoded-6a4ba6c963489d57.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libpercent_encoding-2c654cef3df97fae.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/liblocale_config-6f17292dbf01d809.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libregex-10dedd1ebce4a66d.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libaho_corasick-7e912c3e7f566c6f.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libmemchr-c5c914d16bdd24eb.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libregex_syntax-1416ecf41d5237d2.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/liblanguage_tags-957743de78c62d3e.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libfloat_cmp-179c7f1b9d60ec4d.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libnum_traits-6c236c2f6b25301f.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libmarkup5ever-d0bd2b751c852846.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libstring_cache-716a38b304ecf0e2.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libprecomputed_hash-e708050c64fc7f8d.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libserde-201f2c9db638b3bf.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libparking_lot-c137993f1a6ce04b.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libparking_lot_core-0dbbca55ae56d2d1.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/liblock_api-92e15ac73bd375bc.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libscopeguard-c9b7df94bbdc7a83.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libinstant-db9e2146401e85fb.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libcfg_if-88f6a1a0de010767.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/liblazy_static-0ffe0dc747383ddf.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libtendril-9a275559df6772bc.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libutf8-a948e61845f33c10.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libfutf-3502f25507572932.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libdebug_unreachable-0b6794fe545a05e3.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libmac-95108075a64de6df.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libcssparser-a67d987767be6e2b.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libitoa-9754b96a9f6a0f99.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libdtoa_short-fc39fe2cbc52e7c4.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libdtoa-652b29c5bec5b81c.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libmatches-6807a7fa4705aaef.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libphf-4bf70509424c3386.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libphf_shared-cdf7f4b7eb96e51f.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libsiphasher-d989e332b16ee17f.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libgio-d95f46b1833e1a23.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libthiserror-1655dc936e8fe6c8.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libfutures_io-40c27e4311a7c875.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libglib-10ebbcefd45b7ac2.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libfutures_executor-def87426a02153a1.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libfutures_util-fe0746bd1ac2f1bd.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libslab-d2493ab0afb74cfe.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libpin_project_lite-444b7e15ea54127c.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libpin_utils-1089fcd8d77ac6c8.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libfutures_channel-cf3e5143012885a7.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libfutures_task-0ade75c8c9e0e324.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libfutures_core-83c0cfc3ceaa4c65.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libsmallvec-0d3152e64433c316.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libonce_cell-62f2db780be4f172.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libgio_sys-7f2f3869953441b9.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libgobject_sys-f3590af0365d77b8.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libglib_sys-bd6d7254bb4359a1.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libclap-a55a3a8df0759dd0.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libvec_map-ca3911f48477b989.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libtextwrap-08e777dcdecee451.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libunicode_width-14d93714776d85cb.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libstrsim-17105fc0ec5edd81.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libbitflags-b4b367f6359f7bff.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libatty-fa3feb3a23f2202d.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/liblibc-1a967cebe0d5f101.rlib" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/libansi_term-c5005c18cc08fad2.rlib" "-Wl,--start-group" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/libstd-2385126132a13d8d.rlib" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/libpanic_unwind-53dc449cb9bfde94.rlib" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/libminiz_oxide-621b428e042a5b5a.rlib" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/libadler-bd06e9884af8796d.rlib" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/libobject-71c5b205e30677a1.rlib" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/libmemchr-a7cff77931af3228.rlib" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/libaddr2line-3b48360072a1a766.rlib" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/libgimli-084c846f66a77474.rlib" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/libstd_detect-49b6dc0c3b70fd49.rlib" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/librustc_demangle-48d1908bd81ab682.rlib" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/libhashbrown-0b97d58c1cafab68.rlib" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/librustc_std_workspace_alloc-c68db2691c4321cd.rlib" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/libunwind-45964380a14b009e.rlib" "-lunwind" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/libcfg_if-f763d2e124225658.rlib" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/liblibc-332be3d0f34d6401.rlib" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/liballoc-588127cab293d3c3.rlib" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/librustc_std_workspace_core-51ef7488a5581ffe.rlib" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/libcore-93baf229ba52b9d4.rlib" "-Wl,--end-group" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/libcompiler_builtins-e68536d86a2479c4.rlib" "-Wl,-Bdynamic" "-lpangoft2-1.0" "-lxml2" "-lgdk_pixbuf-2.0" "-lfontconfig" "-lfreetype" "-lgio-2.0" "-lpangocairo-1.0" "-lpango-1.0" "-lharfbuzz" "-lpng16" "-lz" "-lcairo-gobject" "-lcairo" "-lgobject-2.0" "-lglib-2.0" "-lpangocairo-1.0" "-lpango-1.0" "-lgobject-2.0" "-lglib-2.0" "-lharfbuzz" "-lcairo" "-lcairo-gobject" "-lgobject-2.0" "-lglib-2.0" "-lcairo" "-lpango-1.0" "-lgobject-2.0" "-lglib-2.0" "-lharfbuzz" "-lgdk_pixbuf-2.0" "-lgobject-2.0" "-lglib-2.0" "-lgobject-2.0" "-lgio-2.0" "-lgobject-2.0" "-lglib-2.0" "-lgobject-2.0" "-lglib-2.0" "-lgobject-2.0" "-lglib-2.0" "-Wl,--eh-frame-hdr" "-Wl,-znoexecstack" "-nostartfiles" "-L" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib" "-L" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/self-contained" "-o" "/workspace/srcdir/librsvg-2.52.4/target/aarch64-unknown-linux-musl/release/deps/rsvg_convert-546b0b5de5111dee" "-Wl,--gc-sections" "-static" "-Wl,-zrelro" "-Wl,-znow" "-Wl,-O1" "-nodefaultlibs" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/self-contained/crtend.o" "/opt/x86_64-linux-musl/toolchains/1.57.0-x86_64-unknown-linux-musl/lib/rustlib/aarch64-unknown-linux-musl/lib/self-contained/crtn.o"
[15:34:43] = note: /opt/aarch64-linux-musl/bin/../lib/gcc/aarch64-linux-musl/4.8.5/../../../../aarch64-linux-musl/bin/ld: warning: libc.musl-aarch64.so.1, needed by /workspace/destdir/lib/libxml2.so, not found (try using -rpath or -rpath-link)
[15:34:43] /opt/aarch64-linux-musl/bin/../aarch64-linux-musl/sys-root/usr/local/lib/libmount.so.1: undefined reference to `getgroups'
[15:34:43] /workspace/destdir/lib/libgio-2.0.so: undefined reference to `ngettext'
[15:34:43] /workspace/destdir/lib/libxml2.so: undefined reference to `puts'
[15:34:43] /opt/aarch64-linux-musl/bin/../aarch64-linux-musl/sys-root/usr/local/lib/libX11.so.6: undefined reference to `putc'
[15:34:43] /workspace/destdir/lib/libgio-2.0.so: undefined reference to `tolower'
[15:34:43] /opt/aarch64-linux-musl/bin/../aarch64-linux-musl/sys-root/usr/local/lib/libmount.so.1: undefined reference to `warn'
[15:34:43] /opt/aarch64-linux-musl/bin/../aarch64-linux-musl/sys-root/usr/local/lib/libmount.so.1: undefined reference to `umask'
[15:34:43] /opt/aarch64-linux-musl/bin/../aarch64-linux-musl/sys-root/usr/local/lib/libpcre.so.1: undefined reference to `ispunct'
[15:34:43] /workspace/destdir/lib/libglib-2.0.so: undefined reference to `__ctype_get_mb_cur_max'
[15:34:43] /workspace/destdir/lib/libglib-2.0.so: undefined reference to `fscanf'
[15:34:43] /workspace/destdir/lib/libglib-2.0.so: undefined reference to `perror'
[15:34:43] /workspace/destdir/lib/libcairo.so: undefined reference to `hypot'
[15:34:43] /workspace/destdir/lib/libglib-2.0.so: undefined reference to `strtod'
[15:34:43] /workspace/destdir/lib/libxml2.so: undefined reference to `dlclose'
[15:34:43] /workspace/destdir/lib/libgio-2.0.so: undefined reference to `utimes'
[...]
I think the solution is to create the symlink
ln -sv libc.so ${sysroot}/urs/lib/libc.musl-$(musl_arch).so.1
after https://github.com/JuliaPackaging/Yggdrasil/blob/beb4ee8102255237abd5c84e5da25651ccc6b00e/0_RootFS/gcc_common.jl#L701. I'm opening the issue as a reminder, before I get to rebuild all Musl GCCs, sigh.
The JSON serialization via --meta-json
that is used during the Yggdrasil build will convert any VersionSpec to just a fixed full VersionNumber x.y.z
, this is done here
BinaryBuilderBase.jl/src/Dependencies.jl
Lines 127 to 149 in 573b396
Dependency(PackageSpec(name="FLINT_jll", version=VersionSpec("200.690"))),
resulted in
FLINT_jll = "200.690.0"
FLINT_jll = "=200.690.0"
cc @fingolfin
I think it could be useful to have a field to the Dependency
struct to filter the platforms where the package will actually be loaded. We can't have platform-dependent dependencies because Pkg doesn't allow it, but we can at least avoid loading them if not necessary, even if they are mostly no-op. For example, GTK3_jll on macOS and Windows could not load the whole X11 stack, and NativeFileDialog_jll could not load GTK3_jll on the same platforms.
CC: @fingolfin
This error recently popped up in the Rust tests:
x86_64-unknown-freebsd11.1-cc -o /tmp/testsuite/x86_64-unknown-freebsd11.1/c/dyn_link/dyn_link -I/usr/share/testsuite/c/dyn_link/libfoo -fPIC -g -O2 -Wl,-z,origin -Wl,-rpath,$ORIGIN/libfoo -L/tmp/testsuite/x86_64-unknown-freebsd11.1/c/dyn_link/libfoo -lfoo dyn_link.c
error: linking with `x86_64-unknown-freebsd-gcc` failed: exit code: 1
|
= note: "x86_64-unknown-freebsd-gcc" "-Wl,--as-needed" "-Wl,-z,noexecstack" "-m64" "-L" "/opt/x86_64-linux-musl/toolchains/1.43.0-x86_64-unknown-linux-musl/lib/rustlib/x86_64-unknown-freebsd/lib" "/usr/share/testsuite/rust/cargo_build/target/x86_64-unknown-freebsd/release/deps/cargo_build-b31da3f674f0a82e.cargo_build.16vq6tll-cgu.0.rcgu.o" "/usr/share/testsuite/rust/cargo_build/target/x86_64-unknown-freebsd/release/deps/cargo_build-b31da3f674f0a82e.cargo_build.16vq6tll-cgu.1.rcgu.o" "-o" "/usr/share/testsuite/rust/cargo_build/target/x86_64-unknown-freebsd/release/deps/cargo_build-b31da3f674f0a82e" "/usr/share/testsuite/rust/cargo_build/target/x86_64-unknown-freebsd/release/deps/cargo_build-b31da3f674f0a82e.1f957yvw5j3vum8a.rcgu.o" "-Wl,--gc-sections" "-pie" "-Wl,-zrelro" "-Wl,-znow" "-Wl,-O1" "-nodefaultlibs" "-L" "/usr/share/testsuite/rust/cargo_build/target/x86_64-unknown-freebsd/release/deps" "-L" "/usr/share/testsuite/rust/cargo_build/target/release/deps" "-L" "/opt/x86_64-linux-musl/toolchains/1.43.0-x86_64-unknown-linux-musl/lib/rustlib/x86_64-unknown-freebsd/lib" "-Wl,--start-group" "-Wl,-Bstatic" "/opt/x86_64-linux-musl/toolchains/1.43.0-x86_64-unknown-linux-musl/lib/rustlib/x86_64-unknown-freebsd/lib/libstd-3fbe8b2cc03d7ccc.rlib" "/opt/x86_64-linux-musl/toolchains/1.43.0-x86_64-unknown-linux-musl/lib/rustlib/x86_64-unknown-freebsd/lib/libpanic_unwind-5fae110c92ddbf1b.rlib" "/opt/x86_64-linux-musl/toolchains/1.43.0-x86_64-unknown-linux-musl/lib/rustlib/x86_64-unknown-freebsd/lib/libhashbrown-9b25d8656a1d88a2.rlib" "/opt/x86_64-linux-musl/toolchains/1.43.0-x86_64-unknown-linux-musl/lib/rustlib/x86_64-unknown-freebsd/lib/librustc_std_workspace_alloc-9eabecaf3d8c573d.rlib" "/opt/x86_64-linux-musl/toolchains/1.43.0-x86_64-unknown-linux-musl/lib/rustlib/x86_64-unknown-freebsd/lib/libbacktrace-583fee1783041933.rlib" "/opt/x86_64-linux-musl/toolchains/1.43.0-x86_64-unknown-linux-musl/lib/rustlib/x86_64-unknown-freebsd/lib/libbacktrace_sys-db4821f2f4b24b43.rlib" "/opt/x86_64-linux-musl/toolchains/1.43.0-x86_64-unknown-linux-musl/lib/rustlib/x86_64-unknown-freebsd/lib/librustc_demangle-85700bdf94840727.rlib" "/opt/x86_64-linux-musl/toolchains/1.43.0-x86_64-unknown-linux-musl/lib/rustlib/x86_64-unknown-freebsd/lib/libunwind-0aa3d74c4c1f4b9b.rlib" "/opt/x86_64-linux-musl/toolchains/1.43.0-x86_64-unknown-linux-musl/lib/rustlib/x86_64-unknown-freebsd/lib/libcfg_if-7dd3424c8e2c2dc7.rlib" "/opt/x86_64-linux-musl/toolchains/1.43.0-x86_64-unknown-linux-musl/lib/rustlib/x86_64-unknown-freebsd/lib/liblibc-a5c2b50ddd067c26.rlib" "/opt/x86_64-linux-musl/toolchains/1.43.0-x86_64-unknown-linux-musl/lib/rustlib/x86_64-unknown-freebsd/lib/liballoc-144c5c3608b68f63.rlib" "/opt/x86_64-linux-musl/toolchains/1.43.0-x86_64-unknown-linux-musl/lib/rustlib/x86_64-unknown-freebsd/lib/librustc_std_workspace_core-7e5176cc9d084e3f.rlib" "/opt/x86_64-linux-musl/toolchains/1.43.0-x86_64-unknown-linux-musl/lib/rustlib/x86_64-unknown-freebsd/lib/libcore-89a20c5f932d3d9f.rlib" "-Wl,--end-group" "/opt/x86_64-linux-musl/toolchains/1.43.0-x86_64-unknown-linux-musl/lib/rustlib/x86_64-unknown-freebsd/lib/libcompiler_builtins-672583d1a2562a22.rlib" "-Wl,-Bdynamic" "-lexecinfo" "-lpthread" "-lgcc_s" "-lc" "-lm" "-lrt" "-lpthread" "-lutil" "-lutil"
= note: /opt/x86_64-unknown-freebsd11.1/bin/../lib/gcc/x86_64-unknown-freebsd11.1/4.8.5/../../../../x86_64-unknown-freebsd11.1/bin/ld: /opt/x86_64-unknown-freebsd11.1/bin/../x86_64-unknown-freebsd11.1/sys-root/usr/lib/crt1.o: relocation R_X86_64_32 against `_DYNAMIC' can not be used when making a shared object; recompile with -fPIC
/opt/x86_64-unknown-freebsd11.1/bin/../x86_64-unknown-freebsd11.1/sys-root/usr/lib/crt1.o: error adding symbols: Bad value
collect2: error: ld returned 1 exit status
We've seen this error also before, for example JuliaPackaging/Yggdrasil#1780 (comment).
I've been experimenting with building the GCCBootstrap@11-IainS
shard for aarch64-apple-darwin20
(Apple Silicon) and have found that most of the time is taken up compressing the artifact. In particular when running on AWS using an c5ad.8xlarge
instance I found that I could build the shard in 23 minutes but compressing the GCCBootstrap.v11.0.0-iains.aarch64-apple-darwin20.tar.gz
was taking around an 1 hour and 10 minutes (plus another round of compression for squashfs).
When BinaryBuilder shows the output:
[ Info: Tree hash of contents of GCCBootstrap.v11.0.0-iains.aarch64-apple-darwin20.tar.gz: 120bcbd3d356f2fa86d3919c58ee1dd67ab757f5
You can see in the background the process 7z a -si -tgzip -mx9
running on a single thread.
We could potentially greatly benefit from using an alternate tool for performing compression, specifically one that can use multiple threads.
https://github.com/tpoechtrager/cctools-port
As an example building compiler-rt needs lipo
https://github.com/llvm/llvm-project/blob/df3e903655e2499968fc7af64fb5fa52b2ee79bb/compiler-rt/cmake/Modules/CompilerRTDarwinUtils.cmake#L323
https://cmake.org/cmake/help/latest/variable/CMAKE_CROSSCOMPILING.html
This variable will be set to true by CMake if the
CMAKE_SYSTEM_NAME
variable has been set manually (i.e. in a toolchain file or as a cache entry from thecmake
command line). In most cases, manually settingCMAKE_SYSTEM_NAME
will only be done when cross compiling, since it will otherwise be given the same value asCMAKE_HOST_SYSTEM_NAME
if not manually set, which is correct for the non-cross-compiling case. In the event thatCMAKE_SYSTEM_NAME
is manually set to the same value asCMAKE_HOST_SYSTEM_NAME
, thenCMAKE_CROSSCOMPILING
will still be set to true.
In
CMAKE_SYSTEM_NAME
, so CMake will always think we're doing a cross-compilation, even when we use the toolchain file for the host.
Came out in JuliaPackaging/Yggdrasil#2564
That leads to errors whenever using any platform that is not of type Platform
, e.g.:
julia> using BinaryBuilder
julia> BinaryBuilder.runshell(Linux(:x86_64);verbose=true)
[ Info: Checking to see if /home/jessica/Julia/libmpdec_builder/ is encrypted...
[ Info: Checking to see if /home/jessica/.julia/packages/BinaryBuilderBase/nW1CT/deps/ is encrypted...
ERROR: MethodError: no method matching get_concrete_platform(::Linux, ::Vector{BinaryBuilderBase.CompilerShard})
Closest candidates are:
get_concrete_platform(::Platform, ::Vector{BinaryBuilderBase.CompilerShard}) at /home/jessica/.julia/packages/BinaryBuilderBase/nW1CT/src/utils.jl:23
get_concrete_platform(::AnyPlatform, ::Vector{BinaryBuilderBase.CompilerShard}) at /home/jessica/.julia/packages/BinaryBuilderBase/nW1CT/src/utils.jl:61
get_concrete_platform(::AbstractPlatform; kwargs...) at /home/jessica/.julia/packages/BinaryBuilderBase/nW1CT/src/utils.jl:55
...
Stacktrace:
[1] get_concrete_platform(platform::Linux; kwargs::Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
@ BinaryBuilderBase ~/.julia/packages/BinaryBuilderBase/nW1CT/src/utils.jl:57
[2] get_concrete_platform(platform::Linux)
@ BinaryBuilderBase ~/.julia/packages/BinaryBuilderBase/nW1CT/src/utils.jl:56
[3] BinaryBuilderBase.UserNSRunner(workspace_root::String; cwd::String, workspaces::Vector{Pair}, mappings::Vector{Pair}, platform::Linux, extra_env::Dict{String, String}, verbose::Bool, compiler_wrapper_path::String, toolchains_path::String, src_name::String, shards::Nothing, kwargs::Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
@ BinaryBuilderBase ~/.julia/packages/BinaryBuilderBase/nW1CT/src/UserNSRunner.jl:43
[4] runshell(::Type{BinaryBuilderBase.UserNSRunner}, platform::Linux; verbose::Bool, kwargs::Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
@ BinaryBuilderBase ~/.julia/packages/BinaryBuilderBase/nW1CT/src/Runner.jl:1062
[5] runshell(platform::Linux; kwargs::Base.Iterators.Pairs{Symbol, Bool, Tuple{Symbol}, NamedTuple{(:verbose,), Tuple{Bool}}})
@ BinaryBuilderBase ~/.julia/packages/BinaryBuilderBase/nW1CT/src/Runner.jl:1054
[6] top-level scope
@ REPL[3]:1
From #4 (comment)
If you like, some point in the future, feel free to completely rewrite
generate_compiler_wrappers!()
to not be a giant rats nest of function calls. XDSomething where we have
Compiler
structs that havecompiler_flags
andlinker_flags
attributes and something might be a nice way to clean this up.
On master
(tests in #138 reproduce the failure):
julia> BinaryBuilderBase.runshell(; compilers=[:c, :rust, :go]);
sandbox:${WORKSPACE} # export SUPER_VERBOSE=1
sandbox:${WORKSPACE} # make -j${nproc} -sC /usr/share/testsuite install
x86_64-linux-gnu-cc -o /tmp/testsuite/x86_64-linux-gnu/c/hello_world/hello_world -g -O2 hello_world.c
gcc -o /tmp/testsuite/x86_64-linux-gnu/c/openmp/openmp -g -O2 -fopenmp openmp.c
x86_64-linux-gnu-cc -shared -o /tmp/testsuite/x86_64-linux-gnu/c/dyn_link/libfoo/libfoo.so -fPIC -g -O2 -lm libfoo/libfoo.c
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-gcc -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0x4df3e497 -march=x86-64 -mtune=generic -o /tmp/testsuite/x86_64-linux-gnu/c/openmp/openmp -g -O2 -fopenmp openmp.c
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-gcc -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0x91d8f682 -march=x86-64 -mtune=generic -o /tmp/testsuite/x86_64-linux-gnu/c/hello_world/hello_world -g -O2 hello_world.c
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-gcc -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0xefd9e6a4 -march=x86-64 -mtune=generic -shared -o /tmp/testsuite/x86_64-linux-gnu/c/dyn_link/libfoo/libfoo.so -fPIC -g -O2 -lm libfoo/libfoo.c
x86_64-linux-gnu-cc -o /tmp/testsuite/x86_64-linux-gnu/c/dyn_link/dyn_link -I/usr/share/testsuite/c/dyn_link/libfoo -fPIC -g -O2 -Wl,-z,origin -Wl,-rpath,$ORIGIN/libfoo -L/tmp/testsuite/x86_64-linux-gnu/c/dyn_link/libfoo -lfoo dyn_link.c
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-gcc -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0xbd703e78 -march=x86-64 -mtune=generic -o /tmp/testsuite/x86_64-linux-gnu/c/dyn_link/dyn_link -I/usr/share/testsuite/c/dyn_link/libfoo -fPIC -g -O2 -Wl,-z,origin -Wl,-rpath,$ORIGIN/libfoo -L/tmp/testsuite/x86_64-linux-gnu/c/dyn_link/libfoo -lfoo dyn_link.c
x86_64-linux-gnu-c++ -shared -o /tmp/testsuite/x86_64-linux-gnu/cxx/dyn_link/librepeater/librepeater.so -fPIC -g -O2 -lm librepeater/librepeater.cc
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-g++ -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0x03419044 -march=x86-64 -mtune=generic -shared -o /tmp/testsuite/x86_64-linux-gnu/cxx/dyn_link/librepeater/librepeater.so -fPIC -g -O2 -lm librepeater/librepeater.cc
x86_64-linux-gnu-c++ -o /tmp/testsuite/x86_64-linux-gnu/cxx/hello_world/hello_world -g -O2 hello_world.cc
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-g++ -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0x405d8293 -march=x86-64 -mtune=generic -o /tmp/testsuite/x86_64-linux-gnu/cxx/hello_world/hello_world -g -O2 hello_world.cc
x86_64-linux-gnu-f77 -o /tmp/testsuite/x86_64-linux-gnu/fortran/hello_world/hello_world.o -c hello_world.f
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-gfortran -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0x1f7de1e0 -march=x86-64 -mtune=generic -o /tmp/testsuite/x86_64-linux-gnu/fortran/hello_world/hello_world.o -c hello_world.f
x86_64-linux-gnu-cc -o /tmp/testsuite/x86_64-linux-gnu/fortran/hello_world/hello_world -g -O2 /tmp/testsuite/x86_64-linux-gnu/fortran/hello_world/hello_world.o -lgfortran -lm -lquadmath
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-gcc -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0x27fdff42 -march=x86-64 -mtune=generic -o /tmp/testsuite/x86_64-linux-gnu/fortran/hello_world/hello_world -g -O2 /tmp/testsuite/x86_64-linux-gnu/fortran/hello_world/hello_world.o -lgfortran -lm -lquadmath
x86_64-linux-gnu-f77 -o /tmp/testsuite/x86_64-linux-gnu/fortran/hello_world/hello_world hello_world.f
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-gfortran -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0x79b8f319 -march=x86-64 -mtune=generic -o /tmp/testsuite/x86_64-linux-gnu/fortran/hello_world/hello_world hello_world.f
x86_64-linux-gnu-go build -o /tmp/testsuite/x86_64-linux-gnu/go/float_abi/float_abi float_abi.go
/opt/x86_64-linux-musl/go/bin/go build -o /tmp/testsuite/x86_64-linux-gnu/go/float_abi/float_abi float_abi.go
x86_64-linux-gnu-c++ -o /tmp/testsuite/x86_64-linux-gnu/cxx/dyn_link/dyn_link -I/usr/share/testsuite/cxx/dyn_link/librepeater -fPIC -g -O2 -Wl,-z,origin -Wl,-rpath,$ORIGIN/librepeater -L/tmp/testsuite/x86_64-linux-gnu/cxx/dyn_link/librepeater -lrepeater dyn_link.cc
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-g++ -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0x6f690163 -march=x86-64 -mtune=generic -o /tmp/testsuite/x86_64-linux-gnu/cxx/dyn_link/dyn_link -I/usr/share/testsuite/cxx/dyn_link/librepeater -fPIC -g -O2 -Wl,-z,origin -Wl,-rpath,$ORIGIN/librepeater -L/tmp/testsuite/x86_64-linux-gnu/cxx/dyn_link/librepeater -lrepeater dyn_link.cc
x86_64-linux-gnu-go build -o /tmp/testsuite/x86_64-linux-gnu/go/hello_world/hello_world hello_world.go
/opt/x86_64-linux-musl/go/bin/go build -o /tmp/testsuite/x86_64-linux-gnu/go/hello_world/hello_world hello_world.go
cargo install --verbose --path . --root /tmp/testsuite/x86_64-linux-gnu/rust/cargo_build
/opt/x86_64-linux-musl/bin/cargo install --verbose --path . --root /tmp/testsuite/x86_64-linux-gnu/rust/cargo_build
Installing cargo_build v0.1.0 (/usr/share/testsuite/rust/cargo_build)
x86_64-linux-gnu-rustc -o /tmp/testsuite/x86_64-linux-gnu/rust/hello_world/hello_world hello_world.rs
/opt/x86_64-linux-musl/bin/rustc --target=x86_64-unknown-linux-gnu -Clinker=x86_64-linux-gnu-gcc -o /tmp/testsuite/x86_64-linux-gnu/rust/hello_world/hello_world hello_world.rs
error: failed to compile `cargo_build v0.1.0 (/usr/share/testsuite/rust/cargo_build)`, intermediate artifacts can be found at `/usr/share/testsuite/rust/cargo_build/target`
Caused by:
failed to run `rustc` to learn about target-specific information
Caused by:
process didn't exit successfully: `x86_64-linux-gnu-rustc - --crate-name ___ --print=file-names --target x86_64-unknown-linux-gnu --crate-type bin --crate-type rlib --crate-type dylib --crate-type cdylib --crate-type staticlib --crate-type proc-macro --print=sysroot --print=cfg` (exit code: 1)
--- stderr
/opt/x86_64-linux-musl/bin/rustc --target=x86_64-unknown-linux-gnu -Clinker=x86_64-linux-gnu-gcc - --crate-name ___ --print=file-names --target x86_64-unknown-linux-gnu --crate-type bin --crate-type rlib --crate-type dylib --crate-type cdylib --crate-type staticlib --crate-type proc-macro --print=sysroot --print=cfg
error: Option 'target' given more than once
make[1]: *** [Makefile:7: /tmp/testsuite/x86_64-linux-gnu/rust/cargo_build/cargo_build] Error 101
make: *** [Makefile:48: install-project-rust-cargo_build] Error 2
make: *** Waiting for unfinished jobs....
sandbox:${WORKSPACE} #
With #137:
julia> BinaryBuilderBase.runshell(; compilers=[:c, :rust, :go]);
[ Info: Running privileged container via `sudo`, may ask for your password:
sandbox:${WORKSPACE} # export SUPER_VERBOSE=1
sandbox:${WORKSPACE} # make -j${nproc} -sC /usr/share/testsuite install
x86_64-linux-gnu-ccx86_64-linux-gnu-c++ x86_64-linux-gnu-f77-o /tmp/testsuite/x86_64-linux-gnu/c/hello_world/hello_world -g -O2 hello_world.c-o /tmp/testsuite/x86_64-linux-gnu/cxx/hello_world/hello_world -g -O2 hello_world.cc
-o /tmp/testsuite/x86_64-linux-gnu/fortran/hello_world/hello_world.o -c hello_world.f
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-gcc -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0x91d8f682 -march=x86-64 -mtune=generic -o /tmp/testsuite/x86_64-linux-gnu/c/hello_world/hello_world -g -O2 hello_world.c
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-g++ -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0x405d8293 -march=x86-64 -mtune=generic -o /tmp/testsuite/x86_64-linux-gnu/cxx/hello_world/hello_world -g -O2 hello_world.cc
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-gfortran -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0x1f7de1e0 -march=x86-64 -mtune=generic -o /tmp/testsuite/x86_64-linux-gnu/fortran/hello_world/hello_world.o -c hello_world.f
x86_64-linux-gnu-cc -o /tmp/testsuite/x86_64-linux-gnu/fortran/hello_world/hello_world -g -O2 /tmp/testsuite/x86_64-linux-gnu/fortran/hello_world/hello_world.o -lgfortran -lm -lquadmath
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-gcc -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0x27fdff42 -march=x86-64 -mtune=generic -o /tmp/testsuite/x86_64-linux-gnu/fortran/hello_world/hello_world -g -O2 /tmp/testsuite/x86_64-linux-gnu/fortran/hello_world/hello_world.o -lgfortran -lm -lquadmath
x86_64-linux-gnu-f77 -o /tmp/testsuite/x86_64-linux-gnu/fortran/hello_world/hello_world hello_world.f
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-gfortran -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0x79b8f319 -march=x86-64 -mtune=generic -o /tmp/testsuite/x86_64-linux-gnu/fortran/hello_world/hello_world hello_world.f
x86_64-linux-gnu-go build -o /tmp/testsuite/x86_64-linux-gnu/go/hello_world/hello_world hello_world.go
/opt/x86_64-linux-musl/go/bin/go build -o /tmp/testsuite/x86_64-linux-gnu/go/hello_world/hello_world hello_world.go
x86_64-linux-gnu-rustc -o /tmp/testsuite/x86_64-linux-gnu/rust/hello_world/hello_world hello_world.rs
/opt/x86_64-linux-musl/bin/rustc --target=x86_64-unknown-linux-gnu -Clinker=x86_64-linux-gnu-gcc -o /tmp/testsuite/x86_64-linux-gnu/rust/hello_world/hello_world hello_world.rs
x86_64-linux-gnu-cc -shared -o /tmp/testsuite/x86_64-linux-gnu/c/dyn_link/libfoo/libfoo.so -fPIC -g -O2 -lm libfoo/libfoo.c
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-gcc -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0xefd9e6a4 -march=x86-64 -mtune=generic -shared -o /tmp/testsuite/x86_64-linux-gnu/c/dyn_link/libfoo/libfoo.so -fPIC -g -O2 -lm libfoo/libfoo.c
x86_64-linux-gnu-cc -o /tmp/testsuite/x86_64-linux-gnu/c/dyn_link/dyn_link -I/usr/share/testsuite/c/dyn_link/libfoo -fPIC -g -O2 -Wl,-z,origin -Wl,-rpath,$ORIGIN/libfoo -L/tmp/testsuite/x86_64-linux-gnu/c/dyn_link/libfoo -lfoo dyn_link.c
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-gcc -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0xbd703e78 -march=x86-64 -mtune=generic -o /tmp/testsuite/x86_64-linux-gnu/c/dyn_link/dyn_link -I/usr/share/testsuite/c/dyn_link/libfoo -fPIC -g -O2 -Wl,-z,origin -Wl,-rpath,$ORIGIN/libfoo -L/tmp/testsuite/x86_64-linux-gnu/c/dyn_link/libfoo -lfoo dyn_link.c
x86_64-linux-gnu-c++ -shared -o /tmp/testsuite/x86_64-linux-gnu/cxx/dyn_link/librepeater/librepeater.so -fPIC -g -O2 -lm librepeater/librepeater.cc
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-g++ -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0x03419044 -march=x86-64 -mtune=generic -shared -o /tmp/testsuite/x86_64-linux-gnu/cxx/dyn_link/librepeater/librepeater.so -fPIC -g -O2 -lm librepeater/librepeater.cc
x86_64-linux-gnu-c++ -o /tmp/testsuite/x86_64-linux-gnu/cxx/dyn_link/dyn_link -I/usr/share/testsuite/cxx/dyn_link/librepeater -fPIC -g -O2 -Wl,-z,origin -Wl,-rpath,$ORIGIN/librepeater -L/tmp/testsuite/x86_64-linux-gnu/cxx/dyn_link/librepeater -lrepeater dyn_link.cc
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-g++ -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0x6f690163 -march=x86-64 -mtune=generic -o /tmp/testsuite/x86_64-linux-gnu/cxx/dyn_link/dyn_link -I/usr/share/testsuite/cxx/dyn_link/librepeater -fPIC -g -O2 -Wl,-z,origin -Wl,-rpath,$ORIGIN/librepeater -L/tmp/testsuite/x86_64-linux-gnu/cxx/dyn_link/librepeater -lrepeater dyn_link.cc
gcc -o /tmp/testsuite/x86_64-linux-gnu/c/openmp/openmp -g -O2 -fopenmp openmp.c
/opt/x86_64-linux-gnu/bin/x86_64-linux-gnu-gcc -D_GLIBCXX_USE_CXX11_ABI=1 -D_DARWIN_FEATURE_CLOCK_GETTIME=0 -frandom-seed=0x4df3e497 -march=x86-64 -mtune=generic -o /tmp/testsuite/x86_64-linux-gnu/c/openmp/openmp -g -O2 -fopenmp openmp.c
sandbox:${WORKSPACE} #
Some environment like mingw would like asm compiler such as uasm.
https://github.com/msys2/MINGW-packages/blob/8ff2f8d0c3589b43d538cb6c738a0d9eed7e9d7e/mingw-w64-clang/PKGBUILD#L297-L298
export ASM_COMPILER="${MINGW_PREFIX}/bin/uasm.exe"
platform_config+=(-DCMAKE_ASM_MASM_COMPILER="${ASM_COMPILER}"
Poking about at JuliaCI/PkgEval.jl#97 today I got to the step where we instantiate a build environment using BinaryBuilder.
[ Info: Running privileged container via `sudo`, may ask for your password:
Downloading artifact: PlatformSupport-powerpc64le-linux-gnu.v2021.1.28.x86_64-linux-musl.unpacked
Downloaded artifact: PlatformSupport-powerpc64le-linux-gnu.v2021.1.28.x86_64-linux-musl.unpacked
Downloading artifact: GCCBootstrap-powerpc64le-linux-gnu.v7.1.0.x86_64-linux-musl.unpacked
Downloaded artifact: GCCBootstrap-powerpc64le-linux-gnu.v7.1.0.x86_64-linux-musl.unpacked
Downloading artifact: LLVMBootstrap.v11.0.1.x86_64-linux-musl.unpacked
Downloaded artifact: LLVMBootstrap.v11.0.1.x86_64-linux-musl.unpacked
Downloading artifact: PlatformSupport-x86_64-linux-musl.v2021.1.28.x86_64-linux-musl.unpacked
Downloaded artifact: PlatformSupport-x86_64-linux-musl.v2021.1.28.x86_64-linux-musl.unpacked
Downloading artifact: GCCBootstrap-x86_64-linux-musl.v7.1.0.x86_64-linux-musl.unpacked
Downloading [> ] 0.0 %
Would be great if we could support more than just x86_64 as a host arch.
We need to select a CSL that matches the current platform (esp. w.r.t. libgfortran version) so we can't just bundle the CSLs into the Rootfs like we are doing here: https://github.com/JuliaPackaging/Yggdrasil/blob/f3bd341c5384916a241c101990ec776ee4f1c17f/0_RootFS/Rootfs/build_tarballs.jl#L202-L210
Instead, what would be ideal is if we mount in CompilerSupportLibrares_jll
for all the platforms we can run natively, tuned to the compiler ABI we're currently compiling for. We can mount them into /usr/lib/csl-$name
, but we just need to either select them dynamically, or beef the CSL's up to be libgfortran-version-independent.
Right now, we build the macOS and FreeBSD compiler shards into explicitly-versioned directories. This is mostly okay (except that the version number for the macOS shard is wrong; it's a 10.15 (kernel version 19) while claiming it's a 10.10 (kernel version 14).
We should instead fix the versioning, then get BB to the point that we can ask for a build against e.g. x86_64-apple-darwin17
and have it pass the proper -mmin-macos-version=10.13
flags to the compiler, while still knowing that the compiler shard is stored at /opt/x86_64-apple-darwin19/
or whatever. If we expect all platform SDKs to always be fully backward-compatible (as macOS is) then there's no need to version the shard mount location, but if we do not expect that (as I suspect FreeBSD may not be, due to issues on FreeBSD 12 with our 11.1 binaries) we could drop the version numbers completely. I kind of like having version numbers, because we can then encode the maximum os_version
that each compiler shard supports and we'll throw an error if the user asks for something unrealistic.
So I think my proposed action item here is:
Rebuild the macOS
shard with an os_version
of 19
instead of 14
, to actually tell the truth here
Teach BB to choose the appropriate compiler shard given an os-versioned target (done in https://github.com/JuliaPackaging/BinaryBuilderBase.jl/pull/73/files#diff-316fd87ca594c4a160f4887703a9d9f9801311b6fd9df2f0bbd7596da49603b1R116)
Teach BB to pass the right -mmin-macos-version=10.X
while still looking for the compilers in a stable place (right now the compiler path is set via the os_version
of the target; not good).
Figure out some way to test this.
Based upon the benchmarking done in #106 we should switch using the 7z
or xz
format with maximum compression and threading enabled. Unfortunately as [Pkg doesn't know about the 7z
format](https://github.com/JuliaLang/Pkg.jl/blob/76402b8974aba76f4412e59bee2e4bc6be1b7860/src/PlatformEngines.jl#L461-L465 but xz
is available) support for that will need to be added first.
Newer gfortran compilers do more aggressive optimization that breaks the ABI for character arguments.
See JuliaLang/julia#32870 for a detailed description.
And a fix of a crash on power: JuliaLang/julia#38836
One remedy is passing -fno-optimize-sibling-calls
to gfortran, which will prevent the optimizations that cause breakage. We may at least want to apply this for LAPACK (inside OpenBLAS) and a few other Fortran libraries.
Over time, packages that call fortran functions with character/string inputs should do the right thing.
% julia -e 'using BinaryBuilderBase; BinaryBuilderBase.runshell(Platform("i686", "linux"))'
sandbox:${WORKSPACE} # mkdir -p ${prefix}
sandbox:${WORKSPACE} # wget -qO - 'https://github.com/JuliaBinaryWrappers/CompilerSupportLibraries_jll.jl/releases/download/CompilerSupportLibraries-v0.5.0%2B0/CompilerSupportLibraries.v0.5.0.i686-linux-gnu-libgfortran3.tar.gz' | tar xzf - -C ${prefix}
sandbox:${WORKSPACE} # echo 'int main() { return 0; }' | g++ -x c++ - -Wl,--trace -o sanitycheckcpp.exe -L${libdir}
/opt/i686-linux-gnu/bin/../lib/gcc/i686-linux-gnu/4.8.5/../../../../i686-linux-gnu/bin/ld: mode elf_i386
/opt/i686-linux-gnu/bin/../i686-linux-gnu/sys-root/usr/lib/crt1.o
/opt/i686-linux-gnu/bin/../i686-linux-gnu/sys-root/usr/lib/crti.o
/opt/i686-linux-gnu/bin/../lib/gcc/i686-linux-gnu/4.8.5/crtbegin.o
/tmp/ccnJKpAc.o
-lstdc++ (/workspace/destdir/lib/libstdc++.so)
-lm (/opt/i686-linux-gnu/bin/../i686-linux-gnu/sys-root/usr/lib/libm.so)
-lgcc_s (/opt/i686-linux-gnu/bin/../lib/gcc/i686-linux-gnu/4.8.5/../../../../i686-linux-gnu/lib/libgcc_s.so)
/lib/libc.so.6 (/opt/i686-linux-gnu/bin/../i686-linux-gnu/sys-root/lib/libc.so.6)
(/opt/i686-linux-gnu/bin/../i686-linux-gnu/sys-root/usr/lib/libc_nonshared.a)elf-init.oS
/lib/ld-linux.so.2 (/opt/i686-linux-gnu/bin/../i686-linux-gnu/sys-root/lib/ld-linux.so.2)
-lgcc_s (/opt/i686-linux-gnu/bin/../lib/gcc/i686-linux-gnu/4.8.5/../../../../i686-linux-gnu/lib/libgcc_s.so)
/opt/i686-linux-gnu/bin/../lib/gcc/i686-linux-gnu/4.8.5/crtend.o
/opt/i686-linux-gnu/bin/../i686-linux-gnu/sys-root/usr/lib/crtn.o
/workspace/destdir/lib/libstdc++.so: undefined reference to `__divmoddi4@GCC_7.0.0'
/opt/i686-linux-gnu/bin/../lib/gcc/i686-linux-gnu/4.8.5/../../../../i686-linux-gnu/bin/ld: link errors found, deleting executable `sanitycheckcpp.exe'
collect2: error: ld returned 1 exit status
sandbox:${WORKSPACE} # echo 'int main() { return 0; }' | g++ -x c++ - -Wl,--trace -o sanitycheckcpp.exe
/opt/i686-linux-gnu/bin/../lib/gcc/i686-linux-gnu/4.8.5/../../../../i686-linux-gnu/bin/ld: mode elf_i386
/opt/i686-linux-gnu/bin/../i686-linux-gnu/sys-root/usr/lib/crt1.o
/opt/i686-linux-gnu/bin/../i686-linux-gnu/sys-root/usr/lib/crti.o
/opt/i686-linux-gnu/bin/../lib/gcc/i686-linux-gnu/4.8.5/crtbegin.o
/tmp/ccMjMAnj.o
-lstdc++ (/opt/i686-linux-gnu/bin/../lib/gcc/i686-linux-gnu/4.8.5/../../../../i686-linux-gnu/lib/libstdc++.so)
-lm (/opt/i686-linux-gnu/bin/../i686-linux-gnu/sys-root/usr/lib/libm.so)
-lgcc_s (/opt/i686-linux-gnu/bin/../lib/gcc/i686-linux-gnu/4.8.5/../../../../i686-linux-gnu/lib/libgcc_s.so)
/lib/libc.so.6 (/opt/i686-linux-gnu/bin/../i686-linux-gnu/sys-root/lib/libc.so.6)
(/opt/i686-linux-gnu/bin/../i686-linux-gnu/sys-root/usr/lib/libc_nonshared.a)elf-init.oS
/lib/ld-linux.so.2 (/opt/i686-linux-gnu/bin/../i686-linux-gnu/sys-root/lib/ld-linux.so.2)
-lgcc_s (/opt/i686-linux-gnu/bin/../lib/gcc/i686-linux-gnu/4.8.5/../../../../i686-linux-gnu/lib/libgcc_s.so)
/opt/i686-linux-gnu/bin/../lib/gcc/i686-linux-gnu/4.8.5/crtend.o
/opt/i686-linux-gnu/bin/../i686-linux-gnu/sys-root/usr/lib/crtn.o
sandbox:${WORKSPACE} # ./sanitycheckcpp.exe
sandbox:${WORKSPACE} # nm ${libdir}/libstdc++.so | grep divmoddi4
U __divmoddi4@GCC_7.0.0
So, when using CompilerSupportLibraries_jll
v0.5.0 from GCC 11 and ${libdir}
is in the linker search path of libraries g++
can't compile the simple program because ${libdir}/libstdc++.so
has an undefined symbol __divmoddi4@GCC_7.0.0
. We don't have any issues if ${libdir}
isn't in the linker search path and /opt/${target}/${target}/lib/libstdc++.so
is picked up
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.