It is currently broken:
error: unresolved link to `crate::os::unix::ffi::OsStrExt`
--> library/std/src/ffi/mod.rs:134:22
|
134 | //! [unix.OsStrExt]: crate::os::unix::ffi::OsStrExt
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ unresolved link
|
= note: `-D broken-intra-doc-links` implied by `-D warnings`
= help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]`
error: unresolved link to `crate::os::unix::ffi::OsStrExt::from_bytes`
--> library/std/src/ffi/mod.rs:135:21
|
135 | //! [`from_bytes`]: crate::os::unix::ffi::OsStrExt::from_bytes
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ unresolved link
|
= help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]`
error: unresolved link to `crate::os::unix::ffi::OsStrExt::as_bytes`
--> library/std/src/ffi/mod.rs:136:19
|
136 | //! [`as_bytes`]: crate::os::unix::ffi::OsStrExt::as_bytes
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ unresolved link
|
= help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]`
error: unresolved link to `crate::os::unix::ffi::OsStringExt`
--> library/std/src/ffi/mod.rs:131:25
|
131 | //! [unix.OsStringExt]: crate::os::unix::ffi::OsStringExt
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ unresolved link
|
= help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]`
error: unresolved link to `crate::os::unix::ffi::OsStringExt::from_vec`
--> library/std/src/ffi/mod.rs:132:19
|
132 | //! [`from_vec`]: crate::os::unix::ffi::OsStringExt::from_vec
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ unresolved link
|
= help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]`
error: unresolved link to `crate::os::unix::ffi::OsStringExt::into_vec`
--> library/std/src/ffi/mod.rs:133:19
|
133 | //! [`into_vec`]: crate::os::unix::ffi::OsStringExt::into_vec
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ unresolved link
|
= help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]`
error: unresolved link to `crate::os::windows::ffi::OsStrExt`
--> library/std/src/ffi/mod.rs:138:25
|
138 | //! [windows.OsStrExt]: crate::os::windows::ffi::OsStrExt
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ unresolved link
|
= help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]`
error: unresolved link to `crate::os::windows::ffi::OsStrExt::encode_wide`
--> library/std/src/ffi/mod.rs:139:22
|
139 | //! [`encode_wide`]: crate::os::windows::ffi::OsStrExt::encode_wide
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ unresolved link
|
= help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]`
error: unresolved link to `crate::os::windows::ffi::OsStringExt`
--> library/std/src/ffi/mod.rs:141:28
|
141 | //! [windows.OsStringExt]: crate::os::windows::ffi::OsStringExt
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ unresolved link
|
= help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]`
error: unresolved link to `crate::os::windows::ffi::OsStringExt::from_wide`
--> library/std/src/ffi/mod.rs:142:20
|
142 | //! [`from_wide`]: crate::os::windows::ffi::OsStringExt::from_wide
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ unresolved link
|
= help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]`
error: unresolved link to `crate::os::unix::fs::PermissionsExt`
--> library/std/src/fs.rs:176:25
|
176 | /// [`PermissionsExt`]: crate::os::unix::fs::PermissionsExt
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ unresolved link
|
= help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]`
error: unresolved link to `crate::os::unix::fs::symlink`
--> library/std/src/fs.rs:1741:37
|
1741 | /// [`std::os::unix::fs::symlink`]: crate::os::unix::fs::symlink
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ unresolved link
|
= help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]`
error: unresolved link to `crate::os::windows::fs::symlink_file`
--> library/std/src/fs.rs:1742:45
|
1742 | /// [`std::os::windows::fs::symlink_file`]: crate::os::windows::fs::symlink_file
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ unresolved link
|
= help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]`
error: unresolved link to `crate::os::windows::fs::symlink_dir`
--> library/std/src/fs.rs:1743:22
|
1743 | /// [`symlink_dir`]: crate::os::windows::fs::symlink_dir
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ unresolved link
|
= help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]`
error: aborting due to 14 previous errors
error: Could not document `std`.
The location of rustc (found via env::current_exe()) is used to
find the right libstd. However it might have been "copied" by
creating a hard link to the new location instead. Like /proc/curproc/file,
KERN_PROC_PATHNAME (used internally by current_exe()) can return
any of the file's multiple paths. Most of the time it returns the
right rustc path and the build will succeed but occasionally it
will return the "wrong" path and the build fails with:
error[E0463]: can't find crate for `std`
If this is right a viable workaround should be to never create hard
links during the build, so let's try that.
Also drop the related llvm-config-wrapper workaround.
PR: 248184
RLS is broken in nightly-2020-07-18 but that should not have aborted
the package build. Add a workaround for the dist.missing-tools
with build.tools bug.
https://github.com/rust-lang/rust/issues/74545
- Add workaround to fix build when CC/CXX have "clang" in them [1]
- Add patch to allow build with outdated libgit2 0.99.0
Changes: 485c5fb6e1...7f3df57724
PR: 238556 [1]
libgit2-sys is now based on libgit2 0.99.0. While 0.99.0 is supposed
to be API compatible with 0.28, it has not yet been updated in the
ports tree and the git2 crate now make use of some of the new
function return values. Stop relying on system libgit2 and use the
bundled one. Upstream does not make any guarantees about system
libgit2 support in the first place.
Changes: 6d69caba11...96bb8b31c8
It sometimes fails [0,1] and sometimes succeeds [2,3]. When it
fails it fails with
running: "cmake" "/wrkdirs/usr/ports/lang/rust/work/rustc-1.41.1-src/src/llvm-project/lld" "-DCMAKE_INSTALL_MESSAGE=LAZY" "-DCMAKE_C_COMPILER=cc" "-DCMAKE_CXX_COMPILER=c++" "-DCMAKE_C_FLAGS=-ffunction-sections -fdata-sections -fPIC -m64 -pipe -fstack-protector-strong -fno-strict-aliasing" "-DCMAKE_CXX_FLAGS=-ffunction-sections -fdata-sections -fPIC -m64 -pipe -fstack-protector-strong -fno-strict-aliasing" "-DLLVM_CONFIG_PATH=/wrkdirs/usr/ports/lang/rust/work/rustc-1.41.1-src/build/bootstrap/debug/deps/llvm-config-wrapper" "-DLLVM_INCLUDE_TESTS=OFF" "-DCMAKE_INSTALL_PREFIX=/wrkdirs/usr/ports/lang/rust/work/rustc-1.41.1-src/build/x86_64-unknown-freebsd/lld" "-DCMAKE_BUILD_TYPE=Release"
-- The C compiler identification is Clang 9.0.1
-- The CXX compiler identification is Clang 9.0.1
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
CMake Error at CMakeLists.txt:23 (message):
llvm-config failed with status No such file or directory
-- Configuring incomplete, errors occurred!
There seems to be some kind of race when using llvm-config-wrapper,
but at the point where LLD is built, both llvm-config and
llvm-config-wrapper should definitely be available. Both are built
successfully much earlier in the build. Attempt to improve reliability
by not using the wrapper. It is a hack in the first place that is
only really needed on Windows.
This is a shot in the dark. I am unable to reproduce this myself.
[0] http://beefy18.nyi.freebsd.org/data/head-amd64-default/p527397_s358451/logs/errors/rust-1.41.1.log
[1] http://gohan03.nyi.freebsd.org/data/head-amd64-default-baseline/p527486_s358478/logs/errors/rust-1.41.1.log
[2] http://beefy18.nyi.freebsd.org/data/head-amd64-default/p527397_s358451/logs/rust-nightly-1.43.0.20200228.log
[3] http://gohan03.nyi.freebsd.org/data/head-amd64-default-baseline/p527313_s358414/logs/rust-1.41.1.log
= note: ld: error: relocation R_386_PC32 cannot be used against symbol __rust_probestack; recompile with -fPIC
>>> defined in /wrkdirs/usr/ports/lang/rust-nightly/work/rustc-nightly-src/build/i686-unknown-freebsd/stage1/lib/rustlib/i686-unknown-freebsd/lib/libcompiler_builtins-6570a75fe85f0e1a.rlib(compiler_builtins-6570a75fe85f0e1a.compiler_builtins.2i519eqi-cgu.15.rcgu.o)
>>> referenced by std.4xivr03c-cgu.14
>>> std-9bd70afd58e204b7.std.4xivr03c-cgu.14.rcgu.o:(_$LT$alloc..boxed..Box$LT$F$GT$$u20$as$u20$core..ops..function..FnOnce$LT$A$GT$$GT$::call_once::h1c78ed6e734a2bfc (.llvm.10122419023709863394)) in archive /wrkdirs/usr/ports/lang/rust-nightly/work/rustc-nightly-src/build/i686-unknown-freebsd/stage1/lib/rustlib/i686-unknown-freebsd/lib/libstd-9bd70afd58e204b7.rlib
ld: error: relocation R_386_PC32 cannot be used against symbol __rust_probestack; recompile with -fPIC
>>> defined in /wrkdirs/usr/ports/lang/rust-nightly/work/rustc-nightly-src/build/i686-unknown-freebsd/stage1/lib/rustlib/i686-unknown-freebsd/lib/libcompiler_builtins-6570a75fe85f0e1a.rlib(compiler_builtins-6570a75fe85f0e1a.compiler_builtins.2i519eqi-cgu.15.rcgu.o)
>>> referenced by std.4xivr03c-cgu.14
>>> std-9bd70afd58e204b7.std.4xivr03c-cgu.14.rcgu.o:(std::io::util::copy::h9115f048f2203467) in archive /wrkdirs/usr/ports/lang/rust-nightly/work/rustc-nightly-src/build/i686-unknown-freebsd/stage1/lib/rustlib/i686-unknown-freebsd/lib/libstd-9bd70afd58e204b7.rlib
clang-cpp: error: linker command failed with exit code 1 (use -v to see invocation)
error: aborting due to previous error
http://beefy17.nyi.freebsd.org/data/head-i386-default/p523508_s356869/logs/rust-nightly-1.42.0.20200118.log