cross does not build when using the latest libc 0.2.149 on x86_64-unknown-netbsd
joseluisq opened this issue ยท 6 comments
Checklist
- I've looked through the issues and pull requests for similar reports
Describe your issue
cross 0.2.5
no longer compiles my project after an upgrade of libc to 0.2.149
.
Basically, I got an ld: cannot find -lexecinfo collect2: error: ld returned 1 exit status
error when I cross-compile from a Linux x86_64 machine to x86_64-unknown-netbsd
(mode details below)
What target(s) are you cross-compiling for?
x86_64-unknown-netbsd
Which operating system is the host (e.g computer cross is on) running?
- macOS
- Windows
- Linux / BSD
- other OS (specify in description)
What architecture is the host?
- x86_64 / AMD64
- arm32
- arm64 (including Mac M1)
What container engine is cross using?
- docker
- podman
- other container engine (specify in description)
cross version
cross 0.2.5
Example
git clone https://github.com/static-web-server/static-web-server.git
git checkout libc-cross-error
CROSS_BUILD_OPTS="--network=host" cross build -vv --target=x86_64-unknown-netbsd
Compiling static-web-server v2.22.1 (/project)
Running `CARGO=/rust/bin/cargo CARGO_BIN_NAME=static-web-server CARGO_CRATE_NAME=static_web_server CARGO_MANIFEST_DIR=/project CARGO_PKG_AUTHORS='Jose Quintana <https://joseluisq.net>' CARGO_PKG_DESCRIPTION='A cross-platform, high-performance and asynchronous web server for static files-serving.' CARGO_PKG_HOMEPAGE='https://static-web-server.net' CARGO_PKG_LICENSE='MIT OR Apache-2.0' CARGO_PKG_LICENSE_FILE='' CARGO_PKG_NAME=static-web-server CARGO_PKG_README=README.md CARGO_PKG_REPOSITORY='https://github.com/static-web-server/static-web-server' CARGO_PKG_RUST_VERSION=1.70.0 CARGO_PKG_VERSION=2.22.1 CARGO_PKG_VERSION_MAJOR=2 CARGO_PKG_VERSION_MINOR=22 CARGO_PKG_VERSION_PATCH=1 CARGO_PKG_VERSION_PRE='' CARGO_PRIMARY_PACKAGE=1 LD_LIBRARY_PATH='/target/debug/deps:/rust/lib' rustc --crate-name static_web_server --edition=2021 src/bin/server.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --diagnostic-width=190 --crate-type bin --emit=dep-info,link -C embed-bitcode=no -C debuginfo=2 --cfg 'feature="async-compression"' --cfg 'feature="basic-auth"' --cfg 'feature="bcrypt"' --cfg 'feature="chrono"' --cfg 'feature="compression"' --cfg 'feature="compression-brotli"' --cfg 'feature="compression-deflate"' --cfg 'feature="compression-gzip"' --cfg 'feature="compression-zstd"' --cfg 'feature="default"' --cfg 'feature="directory-listing"' --cfg 'feature="fallback-page"' --cfg 'feature="http2"' --cfg 'feature="humansize"' --cfg 'feature="rustls-pemfile"' --cfg 'feature="tokio-rustls"' -C metadata=e8c91db20bda56b2 -C extra-filename=-e8c91db20bda56b2 --out-dir /target/x86_64-unknown-netbsd/debug/deps --target x86_64-unknown-netbsd -C linker=x86_64-unknown-netbsd-gcc -C incremental=/target/x86_64-unknown-netbsd/debug/incremental -L dependency=/target/x86_64-unknown-netbsd/debug/deps -L dependency=/target/debug/deps --extern aho_corasick=/target/x86_64-unknown-netbsd/debug/deps/libaho_corasick-a31ba3dcf47374cb.rlib --extern anyhow=/target/x86_64-unknown-netbsd/debug/deps/libanyhow-8872961d93843fde.rlib --extern async_compression=/target/x86_64-unknown-netbsd/debug/deps/libasync_compression-d5c5e7b4458a90e2.rlib --extern bcrypt=/target/x86_64-unknown-netbsd/debug/deps/libbcrypt-83b686987d938796.rlib --extern bytes=/target/x86_64-unknown-netbsd/debug/deps/libbytes-36ef9bbc09b78e8c.rlib --extern chrono=/target/x86_64-unknown-netbsd/debug/deps/libchrono-f16bd5047aa6982e.rlib --extern clap=/target/x86_64-unknown-netbsd/debug/deps/libclap-0da0a6bf5921458d.rlib --extern form_urlencoded=/target/x86_64-unknown-netbsd/debug/deps/libform_urlencoded-5f2ea0379c38be0b.rlib --extern futures_util=/target/x86_64-unknown-netbsd/debug/deps/libfutures_util-179c40ce5fab6d70.rlib --extern globset=/target/x86_64-unknown-netbsd/debug/deps/libglobset-c0669c060ec8c234.rlib --extern headers=/target/x86_64-unknown-netbsd/debug/deps/libheaders_accept_encoding-7d490ebfeb3117fd.rlib --extern http=/target/x86_64-unknown-netbsd/debug/deps/libhttp-ee10b1572804f61e.rlib --extern http_serde=/target/x86_64-unknown-netbsd/debug/deps/libhttp_serde-4f34722080793cc5.rlib --extern humansize=/target/x86_64-unknown-netbsd/debug/deps/libhumansize-73c5c245e0bf8927.rlib --extern hyper=/target/x86_64-unknown-netbsd/debug/deps/libhyper-fb90426b1301dd83.rlib --extern listenfd=/target/x86_64-unknown-netbsd/debug/deps/liblistenfd-6f6a8347efacdc67.rlib --extern mime_guess=/target/x86_64-unknown-netbsd/debug/deps/libmime_guess-264b4a70baa20aa7.rlib --extern num_cpus=/target/x86_64-unknown-netbsd/debug/deps/libnum_cpus-3ac3b7ce0761c2da.rlib --extern percent_encoding=/target/x86_64-unknown-netbsd/debug/deps/libpercent_encoding-a208d6334f935161.rlib --extern pin_project=/target/x86_64-unknown-netbsd/debug/deps/libpin_project-056d9b839b651cab.rlib --extern regex=/target/x86_64-unknown-netbsd/debug/deps/libregex-23dda271e92170e6.rlib --extern rustls_pemfile=/target/x86_64-unknown-netbsd/debug/deps/librustls_pemfile-384d188beec1518d.rlib --extern serde=/target/x86_64-unknown-netbsd/debug/deps/libserde-39c68d9ba1c8e1c9.rlib --extern serde_ignored=/target/x86_64-unknown-netbsd/debug/deps/libserde_ignored-b0f1b427474325c5.rlib --extern serde_repr=/target/debug/deps/libserde_repr-899b366136ecac48.so --extern signal_hook=/target/x86_64-unknown-netbsd/debug/deps/libsignal_hook-20ed38b597dd94bf.rlib --extern signal_hook_tokio=/target/x86_64-unknown-netbsd/debug/deps/libsignal_hook_tokio-c5df56c51766add7.rlib --extern static_web_server=/target/x86_64-unknown-netbsd/debug/deps/libstatic_web_server-83378e6aff6ef2a4.rlib --extern tokio=/target/x86_64-unknown-netbsd/debug/deps/libtokio-2ae2fabfe3fa94ba.rlib --extern tokio_rustls=/target/x86_64-unknown-netbsd/debug/deps/libtokio_rustls-8763edea1770a1d4.rlib --extern tokio_util=/target/x86_64-unknown-netbsd/debug/deps/libtokio_util-68744c539f20fe07.rlib --extern toml=/target/x86_64-unknown-netbsd/debug/deps/libtoml-4136a35200d5b977.rlib --extern tracing=/target/x86_64-unknown-netbsd/debug/deps/libtracing-b287ed95a7690398.rlib --extern tracing_subscriber=/target/x86_64-unknown-netbsd/debug/deps/libtracing_subscriber-19a2e2efa713d55b.rlib -L native=/usr/lib/x86_64-linux-musl -L native=/target/x86_64-unknown-netbsd/debug/build/zstd-sys-cf5630936b86994a/out -L native=/target/x86_64-unknown-netbsd/debug/build/signal-hook-a8c0729e3030984d/out -L native=/target/x86_64-unknown-netbsd/debug/build/ring-37f94d2723397c6c/out`
error: linking with `x86_64-unknown-netbsd-gcc` failed: exit status: 1
|
= note: LC_ALL="C" PATH="/rust/lib/rustlib/x86_64-unknown-linux-gnu/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/rust/bin" VSLANG="1033" "x86_64-unknown-netbsd-gcc" "-m64" "/tmp/rustc5uPAte/symbols.o" "/target/x86_64-unknown-netbsd/debug/deps/static_web_server-e8c91db20bda56b2.1xu30sx6dgchwl6p.rcgu.o" "/target/x86_64-unknown-netbsd/debug/deps/static_web_server-e8c91db20bda56b2.2r1qc2hh7ybrxxmr.rcgu.o" "/target/x86_64-unknown-netbsd/debug/deps/static_web_server-e8c91db20bda56b2.35qh62dt5ivfu5kt.rcgu.o" "/target/x86_64-unknown-netbsd/debug/deps/static_web_server-e8c91db20bda56b2.38tqsdzk4jsuoxqz.rcgu.o" "/target/x86_64-unknown-netbsd/debug/deps/static_web_server-e8c91db20bda56b2.4exmi198wtipw6ld.rcgu.o" "/target/x86_64-unknown-netbsd/debug/deps/static_web_server-e8c91db20bda56b2.4rscg1intaicgs3r.rcgu.o" "/target/x86_64-unknown-netbsd/debug/deps/static_web_server-e8c91db20bda56b2.djraheiljbcc0to.rcgu.o" "/target/x86_64-unknown-netbsd/debug/deps/static_web_server-e8c91db20bda56b2.22oi2w764tsdiioy.rcgu.o" "-Wl,--as-needed" "-L" "/target/x86_64-unknown-netbsd/debug/deps" "-L" "/target/debug/deps" "-L" "/usr/lib/x86_64-linux-musl" "-L" "/target/x86_64-unknown-netbsd/debug/build/zstd-sys-cf5630936b86994a/out" "-L" "/target/x86_64-unknown-netbsd/debug/build/signal-hook-a8c0729e3030984d/out" "-L" "/target/x86_64-unknown-netbsd/debug/build/ring-37f94d2723397c6c/out" "-L" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib" "-Wl,-Bstatic" "/target/x86_64-unknown-netbsd/debug/deps/libstatic_web_server-83378e6aff6ef2a4.rlib" "/target/x86_64-unknown-netbsd/debug/deps/librustls_pemfile-384d188beec1518d.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libtoml-4136a35200d5b977.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libtoml_edit-83c83ff8275ba74c.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libserde_spanned-cb0a5de542737def.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libindexmap-30c671318f0e81d0.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libequivalent-964e1efc43c45c4d.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libhashbrown-177911497f70966e.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libwinnow-ce507a7f7579b911.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libtoml_datetime-f188ef486e0c9222.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libhttp_serde-4f34722080793cc5.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libform_urlencoded-5f2ea0379c38be0b.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libserde_ignored-b0f1b427474325c5.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libtokio_rustls-8763edea1770a1d4.rlib" "/target/x86_64-unknown-netbsd/debug/deps/librustls-dfcaae160d1db943.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libsct-dc74639f6c8f6d54.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libwebpki-9889126ab38b916b.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libring-2f5d2f4b43a289e4.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libspin-02bee1d392e07a73.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libuntrusted-8101c6106e507385.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libsignal_hook_tokio-c5df56c51766add7.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libsignal_hook-20ed38b597dd94bf.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libglobset-c0669c060ec8c234.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libregex-23dda271e92170e6.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libregex_automata-1f689a7784f659cb.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libregex_syntax-89a764a3804e2f7d.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libbstr-68bfee34a823bcc7.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libaho_corasick-a31ba3dcf47374cb.rlib" "/target/x86_64-unknown-netbsd/debug/deps/liblistenfd-6f6a8347efacdc67.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libtracing_subscriber-19a2e2efa713d55b.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libnu_ansi_term-e72bb28e9ee8faeb.rlib" "/target/x86_64-unknown-netbsd/debug/deps/liboverload-cfc33a8a184c66f2.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libparking_lot-b705065ab3ca6394.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libparking_lot_core-10643a82a5f8a665.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libsmallvec-f878b7c3ba369150.rlib" "/target/x86_64-unknown-netbsd/debug/deps/liblock_api-8c8cc0fbfc3b6293.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libscopeguard-40c3618310faee63.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libthread_local-3688b82b8bed88c7.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libsharded_slab-ed935d26f981df02.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libtracing_log-394c5a3707a430e6.rlib" "/target/x86_64-unknown-netbsd/debug/deps/liblog-b3ca4bef4924f039.rlib" "/target/x86_64-unknown-netbsd/debug/deps/liblazy_static-8fe676397914e161.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libpercent_encoding-a208d6334f935161.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libhumansize-73c5c245e0bf8927.rlib" "/target/x86_64-unknown-netbsd/debug/deps/liblibm-e37a9c5223c6d344.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libclap-0da0a6bf5921458d.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libclap_builder-9ac86b2dfb42cbdf.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libstrsim-264132764c272a49.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libanstream-c3ce8ddd038105b1.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libanstyle_query-6c7722bd58bcf91a.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libcolorchoice-d074f7c8deb362a3.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libanstyle_parse-2378c839cea73982.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libutf8parse-4d44130db64dd78a.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libclap_lex-ff26bd5ee8d576f2.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libanstyle-a250f1c4f6db09d0.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libchrono-f16bd5047aa6982e.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libnum_traits-89236e51d5cf7140.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libiana_time_zone-10403008ce94e56d.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libpin_project-056d9b839b651cab.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libmime_guess-264b4a70baa20aa7.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libunicase-53787f08d959c8f1.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libasync_compression-d5c5e7b4458a90e2.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libmemchr-62b8a2d8c0408622.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libzstd-31e0f9b3dbe5d0fc.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libzstd_safe-bb7f804713d37303.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libzstd_sys-cf924f61536611c3.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libflate2-87afd3a5fb623f88.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libminiz_oxide-bcf104a5fe64e239.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libadler-0692adb92f0b477e.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libcrc32fast-df1d39514880833c.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libbrotli-51069b4913ac903b.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libbrotli_decompressor-28bc45a1907a474b.rlib" "/target/x86_64-unknown-netbsd/debug/deps/liballoc_stdlib-577a6f117e98cbb8.rlib" "/target/x86_64-unknown-netbsd/debug/deps/liballoc_no_stdlib-bb0f3136f78b635a.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libhyper-fb90426b1301dd83.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libsocket2-24bf32ac3b9f5bcb.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libhttparse-d35ebcecdd0ea051.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libh2-bb2b6f8164b622d1.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libindexmap-e7211f3fdb4b6a2a.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libhashbrown-d99b307f0344a5a3.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libslab-03910ae7e9e4478a.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libtokio_util-68744c539f20fe07.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libfutures_sink-146aef2f8d1da6c8.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libtower_service-d6036af4d0f4f8f7.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libtracing-b287ed95a7690398.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libtracing_core-90aee5b684c70b4e.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libonce_cell-98388fec763f2194.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libfutures_channel-de94d2df2468b919.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libhttp_body-f3ebc0ee816dd9cc.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libfutures_util-179c40ce5fab6d70.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libfutures_task-28ef02d289554602.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libpin_utils-1e240dc474d924a9.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libfutures_core-84ad6e501044a3f4.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libtokio-2ae2fabfe3fa94ba.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libsignal_hook_registry-4c6304158aab3aea.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libnum_cpus-3ac3b7ce0761c2da.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libsocket2-bb8bd835a8cc6f86.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libmio-aa3bc094eaa46aa5.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libpin_project_lite-d55f4e6dc7c949eb.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libheaders_accept_encoding-7d490ebfeb3117fd.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libsha1-f9fe3c6bbcb11ff2.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libcpufeatures-8261f9d9b022973b.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libdigest-f9ae963f9e6b7dee.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libblock_buffer-176d0560c52a3bb8.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libmime-231deadf3fb8ed28.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libitertools-baf239f68ed80074.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libeither-a32c690456ffb293.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libhttpdate-02b60ef1aaa84448.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libheaders_core-757b2367d55b8de5.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libhttp-ee10b1572804f61e.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libitoa-1cf07cb96526661c.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libfnv-5830a2cb875dd51c.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libbytes-36ef9bbc09b78e8c.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libbcrypt-83b686987d938796.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libsubtle-c67eb97517c9b6ad.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libblowfish-94d55a55a7e83f3f.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libbyteorder-2c2bd59fc28eabce.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libcipher-a11eceb7188a7ab1.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libinout-e8dbad426c5ca221.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libcrypto_common-de65809714466648.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libgeneric_array-a6d21ec7fbf2261c.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libtypenum-19d27199d686fa88.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libgetrandom-fdc9942773478275.rlib" "/target/x86_64-unknown-netbsd/debug/deps/liblibc-7c9f29eed291bcee.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libcfg_if-4607357f42796533.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libbase64-79f581b344643a31.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libzeroize-e3598a1f920f92fb.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libserde-39c68d9ba1c8e1c9.rlib" "/target/x86_64-unknown-netbsd/debug/deps/libanyhow-8872961d93843fde.rlib" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib/libstd-377d356093feb014.rlib" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib/libpanic_unwind-b129694b342ec5dd.rlib" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib/libobject-9860141b63c77f03.rlib" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib/libmemchr-81f663aabf9fafe5.rlib" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib/libaddr2line-1cb44d5adc569417.rlib" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib/libgimli-79c34f90bbcda44c.rlib" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib/librustc_demangle-a1bbe9e0e5f22dc4.rlib" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib/libstd_detect-3ea10fb104221b4d.rlib" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib/libhashbrown-afde58c4944303cf.rlib" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib/librustc_std_workspace_alloc-aa8811a6be373845.rlib" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib/libminiz_oxide-74f1985e980e2452.rlib" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib/libadler-31b70ceeefc41232.rlib" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib/libunwind-b38d828ada2a4ec7.rlib" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib/libcfg_if-263c47485c570248.rlib" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib/liblibc-39be58e0c79ef88e.rlib" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib/liballoc-7af001b19c09608d.rlib" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib/librustc_std_workspace_core-264aa2cf7b7cb7bc.rlib" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib/libcore-f8934580be9e4028.rlib" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib/libcompiler_builtins-ba21354461c3e6b4.rlib" "-Wl,-Bdynamic" "-lutil" "-lrt" "-lutil" "-lexecinfo" "-lpthread" "-lrt" "-lgcc_s" "-lc" "-lm" "-lrt" "-lpthread" "-lutil" "-lrt" "-lutil" "-Wl,--eh-frame-hdr" "-Wl,-z,noexecstack" "-L" "/rust/lib/rustlib/x86_64-unknown-netbsd/lib" "-o" "/target/x86_64-unknown-netbsd/debug/deps/static_web_server-e8c91db20bda56b2" "-Wl,--gc-sections" "-pie" "-Wl,-z,relro,-z,now"
= note: /usr/local/lib/gcc/x86_64-unknown-netbsd/9.4.0/../../../../x86_64-unknown-netbsd/bin/ld: cannot find -lexecinfo
collect2: error: ld returned 1 exit status
error: could not compile `static-web-server` (bin "static-web-server") due to previous error
Caused by:
process didn't exit successfully: `CARGO=/rust/bin/cargo CARGO_BIN_NAME=static-web-server CARGO_CRATE_NAME=static_web_server CARGO_MANIFEST_DIR=/project CARGO_PKG_AUTHORS='Jose Quintana <https://joseluisq.net>' CARGO_PKG_DESCRIPTION='A cross-platform, high-performance and asynchronous web server for static files-serving.' CARGO_PKG_HOMEPAGE='https://static-web-server.net' CARGO_PKG_LICENSE='MIT OR Apache-2.0' CARGO_PKG_LICENSE_FILE='' CARGO_PKG_NAME=static-web-server CARGO_PKG_README=README.md CARGO_PKG_REPOSITORY='https://github.com/static-web-server/static-web-server' CARGO_PKG_RUST_VERSION=1.70.0 CARGO_PKG_VERSION=2.22.1 CARGO_PKG_VERSION_MAJOR=2 CARGO_PKG_VERSION_MINOR=22 CARGO_PKG_VERSION_PATCH=1 CARGO_PKG_VERSION_PRE='' CARGO_PRIMARY_PACKAGE=1 LD_LIBRARY_PATH='/target/debug/deps:/rust/lib' rustc --crate-name static_web_server --edition=2021 src/bin/server.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --diagnostic-width=190 --crate-type bin --emit=dep-info,link -C embed-bitcode=no -C debuginfo=2 --cfg 'feature="async-compression"' --cfg 'feature="basic-auth"' --cfg 'feature="bcrypt"' --cfg 'feature="chrono"' --cfg 'feature="compression"' --cfg 'feature="compression-brotli"' --cfg 'feature="compression-deflate"' --cfg 'feature="compression-gzip"' --cfg 'feature="compression-zstd"' --cfg 'feature="default"' --cfg 'feature="directory-listing"' --cfg 'feature="fallback-page"' --cfg 'feature="http2"' --cfg 'feature="humansize"' --cfg 'feature="rustls-pemfile"' --cfg 'feature="tokio-rustls"' -C metadata=e8c91db20bda56b2 -C extra-filename=-e8c91db20bda56b2 --out-dir /target/x86_64-unknown-netbsd/debug/deps --target x86_64-unknown-netbsd -C linker=x86_64-unknown-netbsd-gcc -C incremental=/target/x86_64-unknown-netbsd/debug/incremental -L dependency=/target/x86_64-unknown-netbsd/debug/deps -L dependency=/target/debug/deps --extern aho_corasick=/target/x86_64-unknown-netbsd/debug/deps/libaho_corasick-a31ba3dcf47374cb.rlib --extern anyhow=/target/x86_64-unknown-netbsd/debug/deps/libanyhow-8872961d93843fde.rlib --extern async_compression=/target/x86_64-unknown-netbsd/debug/deps/libasync_compression-d5c5e7b4458a90e2.rlib --extern bcrypt=/target/x86_64-unknown-netbsd/debug/deps/libbcrypt-83b686987d938796.rlib --extern bytes=/target/x86_64-unknown-netbsd/debug/deps/libbytes-36ef9bbc09b78e8c.rlib --extern chrono=/target/x86_64-unknown-netbsd/debug/deps/libchrono-f16bd5047aa6982e.rlib --extern clap=/target/x86_64-unknown-netbsd/debug/deps/libclap-0da0a6bf5921458d.rlib --extern form_urlencoded=/target/x86_64-unknown-netbsd/debug/deps/libform_urlencoded-5f2ea0379c38be0b.rlib --extern futures_util=/target/x86_64-unknown-netbsd/debug/deps/libfutures_util-179c40ce5fab6d70.rlib --extern globset=/target/x86_64-unknown-netbsd/debug/deps/libglobset-c0669c060ec8c234.rlib --extern headers=/target/x86_64-unknown-netbsd/debug/deps/libheaders_accept_encoding-7d490ebfeb3117fd.rlib --extern http=/target/x86_64-unknown-netbsd/debug/deps/libhttp-ee10b1572804f61e.rlib --extern http_serde=/target/x86_64-unknown-netbsd/debug/deps/libhttp_serde-4f34722080793cc5.rlib --extern humansize=/target/x86_64-unknown-netbsd/debug/deps/libhumansize-73c5c245e0bf8927.rlib --extern hyper=/target/x86_64-unknown-netbsd/debug/deps/libhyper-fb90426b1301dd83.rlib --extern listenfd=/target/x86_64-unknown-netbsd/debug/deps/liblistenfd-6f6a8347efacdc67.rlib --extern mime_guess=/target/x86_64-unknown-netbsd/debug/deps/libmime_guess-264b4a70baa20aa7.rlib --extern num_cpus=/target/x86_64-unknown-netbsd/debug/deps/libnum_cpus-3ac3b7ce0761c2da.rlib --extern percent_encoding=/target/x86_64-unknown-netbsd/debug/deps/libpercent_encoding-a208d6334f935161.rlib --extern pin_project=/target/x86_64-unknown-netbsd/debug/deps/libpin_project-056d9b839b651cab.rlib --extern regex=/target/x86_64-unknown-netbsd/debug/deps/libregex-23dda271e92170e6.rlib --extern rustls_pemfile=/target/x86_64-unknown-netbsd/debug/deps/librustls_pemfile-384d188beec1518d.rlib --extern serde=/target/x86_64-unknown-netbsd/debug/deps/libserde-39c68d9ba1c8e1c9.rlib --extern serde_ignored=/target/x86_64-unknown-netbsd/debug/deps/libserde_ignored-b0f1b427474325c5.rlib --extern serde_repr=/target/debug/deps/libserde_repr-899b366136ecac48.so --extern signal_hook=/target/x86_64-unknown-netbsd/debug/deps/libsignal_hook-20ed38b597dd94bf.rlib --extern signal_hook_tokio=/target/x86_64-unknown-netbsd/debug/deps/libsignal_hook_tokio-c5df56c51766add7.rlib --extern static_web_server=/target/x86_64-unknown-netbsd/debug/deps/libstatic_web_server-83378e6aff6ef2a4.rlib --extern tokio=/target/x86_64-unknown-netbsd/debug/deps/libtokio-2ae2fabfe3fa94ba.rlib --extern tokio_rustls=/target/x86_64-unknown-netbsd/debug/deps/libtokio_rustls-8763edea1770a1d4.rlib --extern tokio_util=/target/x86_64-unknown-netbsd/debug/deps/libtokio_util-68744c539f20fe07.rlib --extern toml=/target/x86_64-unknown-netbsd/debug/deps/libtoml-4136a35200d5b977.rlib --extern tracing=/target/x86_64-unknown-netbsd/debug/deps/libtracing-b287ed95a7690398.rlib --extern tracing_subscriber=/target/x86_64-unknown-netbsd/debug/deps/libtracing_subscriber-19a2e2efa713d55b.rlib -L native=/usr/lib/x86_64-linux-musl -L native=/target/x86_64-unknown-netbsd/debug/build/zstd-sys-cf5630936b86994a/out -L native=/target/x86_64-unknown-netbsd/debug/build/signal-hook-a8c0729e3030984d/out -L native=/target/x86_64-unknown-netbsd/debug/build/ring-37f94d2723397c6c/out` (exit status: 1)
+ rustup component list --toolchain stable-x86_64-unknown-linux-gnu
See also the CI broken https://github.com/static-web-server/static-web-server/actions/runs/6519619958/job/17706311139#step:8:454
Additional information / notes
I do not get why libc v0.2.149
fails on NetBSD recently and asks for execinfo
. Maybe some change in 0.2.149?
However, downgrading to 0.2.148
works for now.
We need to add execinfo here:
Line 81 in a537585
For what it's worth - I've encountered the same issue (specifically missing -lexecinfo) with the only difference being that I'm using Podman instead of Docker.
here's a temporary workaround until an official fix is in place. Add this to Cargo.toml or wherever you keep your Cross configs:
[package.metadata.cross.target.x86_64-unknown-netbsd]
pre-build = [
"mkdir -p /tmp/netbsd",
"curl https://cdn.netbsd.org/pub/NetBSD/NetBSD-9.2/amd64/binary/sets/base.tar.xz -O",
"tar -C /tmp/netbsd -xJf base.tar.xz",
"cp /tmp/netbsd/usr/lib/libexecinfo.so /usr/local/x86_64-unknown-netbsd/lib",
"rm base.tar.xz",
"rm -rf /tmp/netbsd",
]
@esheri3 thank you for the fix!
I was helping add a netbsd ci test to a repo (Byron/trash-rs#90) and it was failing with the above issue:
https://github.com/Byron/trash-rs/actions/runs/6586046532/job/17893604558
I applied the fix suggested above which seems to have done the trick, but it started failing on something else I wasn't able to pin down:
https://github.com/Byron/trash-rs/actions/runs/6586482261/job/17894895647
In the end I "fixed" it by switching from cargo test
to cargo build
for netbsd:
https://github.com/Byron/trash-rs/actions/runs/6587609486
I'm somewhat baffled as to why the cargo test
fails when cargo build
works after this fix (the tests themselves run fine when run locally) so I'm just flagging this up here in case it is related / a side effect of the fix.