Hi, I've been having some issues building rust, namely an error with: ld-elf.so.1: /usr/ports/lang/rust/work/bootstrap/bin/../lib/librustc_driver-94523f912a230ea1.so I notice some chatter about this error possibly being related to linking up with the wrong libc++. The output of the Makefile indicates that it is using llvm17. Any suggestions are to what is wrong? I do have a number of ports that depend on rust so it would be nice to resolve this issue. thanks
I am also a bit confused on why 'pkg version' indicates: rust-1.81.0 < needs updating (index has 1.82.0) while 'pkg install rust' tells me: The most recent versions of packages are already installed
=> SHA256 Checksum OK for rust/2024-09-05/cargo-1.81.0-x86_64-unknown-freebsd.tar.xz. ===> Patching for rust-1.82.0_1 ===> Applying FreeBSD patches for rust-1.82.0_1 from /usr/ports/lang/rust/files ===> rust-1.82.0_1 depends on file: /usr/local/bin/cmake - found ===> rust-1.82.0_1 depends on executable: ninja - found ===> rust-1.82.0_1 depends on package: pkgconf>=1.3.0_1 - found ===> rust-1.82.0_1 depends on file: /usr/local/bin/python3.11 - found ===> rust-1.82.0_1 depends on file: /usr/local/lib/libcrypto.so.12 - found ===> rust-1.82.0_1 depends on shared library: libcurl.so - found (/usr/local/lib/libcurl.so) ===> Configuring for rust-1.82.0_1 ===> FreeBSD 10 autotools fix applied to /usr/ports/lang/rust/work/rustc-1.82.0-src/vendor/libssh2-sys-0.3.0/libssh2/config.rpath ===> FreeBSD 10 autotools fix applied to /usr/ports/lang/rust/work/rustc-1.82.0-src/vendor/libssh2-sys-0.2.23/libssh2/config.rpath install: install: validating arguments install: install: verifying destination is writable install: verifying destination is not the same as source install: creating uninstall script at /usr/ports/lang/rust/work/bootstrap/lib/rustlib/uninstall.sh install: installing component 'cargo' install: copying file /usr/ports/lang/rust/work/bootstrap/bin/cargo install: copying file /usr/ports/lang/rust/work/bootstrap/etc/bash_completion.d/cargo install: copying file /usr/ports/lang/rust/work/bootstrap/share/doc/cargo/LICENSE-APACHE install: copying file /usr/ports/lang/rust/work/bootstrap/share/doc/cargo/LICENSE-MIT install: copying file /usr/ports/lang/rust/work/bootstrap/share/doc/cargo/LICENSE-THIRD-PARTY install: copying file /usr/ports/lang/rust/work/bootstrap/share/doc/cargo/README.md install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-add.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-bench.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-build.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-check.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-clean.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-doc.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-fetch.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-fix.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-generate-lockfile.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-help.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-init.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-install.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-locate-project.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-login.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-logout.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-metadata.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-new.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-owner.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-package.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-pkgid.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-publish.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-remove.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-report.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-run.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-rustc.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-rustdoc.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-search.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-test.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-tree.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-uninstall.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-update.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-vendor.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-verify-project.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-version.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo-yank.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/cargo.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/zsh/site-functions/_cargo cargo installed. install: install: validating arguments install: install: verifying destination is writable install: verifying destination is not the same as source install: creating uninstall script at /usr/ports/lang/rust/work/bootstrap/lib/rustlib/uninstall.sh install: installing component 'rust-std-x86_64-unknown-freebsd' install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libaddr2line-e03705642c8506a6.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libadler-8863a2f17b96ed5a.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/liballoc-ad17b4778b283795.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libcfg_if-e91a57de3d9fc5b9.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libcompiler_builtins-e5125b62d0bad282.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libcore-4008cccaa07abc7a.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libgetopts-50dedf1e436b99cc.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libgimli-e32652f5335fba6e.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libhashbrown-dcd418ecde764bc1.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/liblibc-865a0e1a16f9fbb0.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libmemchr-3034bbde98d1fad3.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libminiz_oxide-d6b722efd58aa5a1.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libobject-6624556950b59c4f.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libpanic_abort-07d54c594fc7f889.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libpanic_unwind-14245305d4c5ad97.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libproc_macro-d06d07e3cae365e5.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/librustc_demangle-659a339ca9e69781.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/librustc_std_workspace_alloc-dea0201cf0b055f5.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/librustc_std_workspace_core-d4a0dd1e03f77f73.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/librustc_std_workspace_std-5a6749a7e129afbd.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libstd-c9b5e7172b2ee9ae.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libstd-c9b5e7172b2ee9ae.so install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libstd_detect-adfac9f905909895.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libsysroot-a570fd5d4ac0af41.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libtest-90fded0bfe290e98.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libunicode_width-3054bd630ff0bc0a.rlib install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/x86_64-unknown-freebsd/lib/libunwind-3c02b3c071872a13.rlib rust std installed. install: install: validating arguments install: install: verifying destination is writable install: verifying destination is not the same as source install: creating uninstall script at /usr/ports/lang/rust/work/bootstrap/lib/rustlib/uninstall.sh install: installing component 'rustc' install: copying file /usr/ports/lang/rust/work/bootstrap/bin/rust-gdb install: copying file /usr/ports/lang/rust/work/bootstrap/bin/rust-gdbgui install: copying file /usr/ports/lang/rust/work/bootstrap/bin/rust-lldb install: copying file /usr/ports/lang/rust/work/bootstrap/bin/rustc install: copying file /usr/ports/lang/rust/work/bootstrap/bin/rustdoc install: copying file /usr/ports/lang/rust/work/bootstrap/lib/librustc_driver-94523f912a230ea1.so install: copying file /usr/ports/lang/rust/work/bootstrap/lib/libstd-c9b5e7172b2ee9ae.so install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/etc/gdb_load_rust_pretty_printers.py install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/etc/gdb_lookup.py install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/etc/gdb_providers.py install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/etc/lldb_commands install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/etc/lldb_lookup.py install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/etc/lldb_providers.py install: copying file /usr/ports/lang/rust/work/bootstrap/lib/rustlib/etc/rust_types.py install: copying file /usr/ports/lang/rust/work/bootstrap/share/doc/rust/COPYRIGHT install: copying file /usr/ports/lang/rust/work/bootstrap/share/doc/rust/LICENSE-APACHE install: copying file /usr/ports/lang/rust/work/bootstrap/share/doc/rust/LICENSE-MIT install: copying file /usr/ports/lang/rust/work/bootstrap/share/doc/rust/README.md install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/rustc.1 install: copying file /usr/ports/lang/rust/work/bootstrap/share/man/man1/rustdoc.1 rustc installed. ===> Building for rust-1.82.0_1 Building bootstrap running: /usr/ports/lang/rust/work/bootstrap/bin/cargo build --manifest-path /usr/ports/lang/rust/work/rustc-1.82.0-src/src/bootstrap/Cargo.toml --verbose --verbo\ se --frozen error: process didn't exit successfully: `/usr/ports/lang/rust/work/bootstrap/bin/rustc -vV` (exit status: 1) --- stderr ld-elf.so.1: /usr/ports/lang/rust/work/bootstrap/bin/../lib/librustc_driver-94523f912a230ea1.so: Undefined symbol "_ZNSt3__122__libcpp_verbose_abortEPKcz" Traceback (most recent call last): File "/usr/ports/lang/rust/work/rustc-1.82.0-src/x.py", line 50, in <module> bootstrap.main() File "/usr/ports/lang/rust/work/rustc-1.82.0-src/src/bootstrap/bootstrap.py", line 1208, in main bootstrap(args) File "/usr/ports/lang/rust/work/rustc-1.82.0-src/src/bootstrap/bootstrap.py", line 1175, in bootstrap build.build_bootstrap() File "/usr/ports/lang/rust/work/rustc-1.82.0-src/src/bootstrap/bootstrap.py", line 921, in build_bootstrap run(args, env=env, verbose=self.verbose, cwd=self.rust_root) File "/usr/ports/lang/rust/work/rustc-1.82.0-src/src/bootstrap/bootstrap.py", line 195, in run raise RuntimeError(err) RuntimeError: failed to run: /usr/ports/lang/rust/work/bootstrap/bin/cargo build --manifest-path /usr/ports/lang/rust/work/rustc-1.82.0-src/src/bootstrap/Cargo.to\ ml --verbose --verbose --frozen *** Error code 1 Stop. make[1]: stopped in /usr/ports/lang/rust *** Error code 1 Stop. make: stopped in /usr/ports/lang/rust
so, nobody home or are all of you on extended vacation?????
Hello, uname -a you builder?
(In reply to Andrey Fesenko from comment #4) Hi Andrey, Thanks for the reply. I am pretty much stuck on this issue and I am bit surprised I seem to be the only one who can't figure it out. So root@tahoestores:/usr/ports/devel/cargo-c # uname -a FreeBSD tahoestores.org 13.2-RELEASE-p11 FreeBSD 13.2-RELEASE-p11 GENERIC amd64 Am I a builder? Not sure what you mean. I do maintain my system using ports. I finally upgraded to 13.2 on a production system. It takes 2 days to rebuild everything, so I am hesitant to upgrade to 13.4 until I resolve my problem. I tried using pkg to upgrade rust, works ok, but then all the ports that depend on rust like cargo-c seem to copy files from /usr/ports/lang/rust/work/bootstrap and then the make fails with the same error as it tries to rebuild rust. Any help would be appreciated, thanks Joel
1. You don't need to rebuild everything when you upgrade minor versions, only when upgrading to a newer branch (e.g. 14). 2. This error probably happens because the new Rust bootstraps are built against FreeBSD 13.3-RELEASE with newer libc++. You're running EOL system, so no support. Upgrade to at least 13.3-RELEASE. Also, starting with the next Rust release, 13.3-RELEASE is also going EOL so may have the same issue and you will need at least 13.4-RELEASE. Since this issue is related to EOL system, I'm closing it. EOL has no support after all.
(In reply to Piotr Kubaj from comment #6) Thank you very much Piotr, that is exactly what I needed to know. Joel
(In reply to Joel Rodriguez from comment #5) > I do maintain my system using ports. Provided you have rust 1.81 and you are comfortable modifying Makefiles, then it is (easily .-) possible to build rust on your system. Modify Makefile/do-configure step: - disable installing the bootstrap components (delete or comment the loop) - add: cd ${WRKDIR} && ln -sf /usr/local bootstrap That way the installed rust compiler is used. Beware: The rustc version _has_ to be 1.81!