Reasons:
* Port build shouldn't use cross-compilation mode
because it buids for the same architecture.
* RUSTFLAGS isn't passed to the build of all or some Rust ports
in the cross-compilation mode.
Essential changes:
* Remove the CARGO_BUILD_TARGET make variable.
* Remove CARGO_BUILD_TARGET and CARGO_TARGET_* from CARGO_ENV.
* Update many ports that used CARGO_BUILD_TARGET.
* Build paths now don't include the architecture triplet part.
Immadiate benefits:
* Unbreak build on architectures like i386 that sometimes require
special RUSTFLAGS that were not effective in the cross-compilation
mode.
Ports that really need cross-compilation for some reason should
enable it on case-by-case basis. Example: net-p2p/cncli
(Not sure why does net-p2p/cncli actually need it, but it only
builds with these options.)
PR: 280305
Approved by: rust@FreeBSD.org (maintainer's timeout; 98 days)
The patch was applied to detect mempcpy(3) in /usr/include/string.h. It
is no longer necessary after ports snapshot d124846683 and did not
detect the function after src snapshot 0c47b9c211.
Approved by: mikael (maintainer)
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D46058
After src snapshot 0c47b9c211e, the build began failing with:
../../third_party/nasm/include/compiler.h:249:21: error: static
declaration of 'mempcpy' follows non-static declaration
249 | static inline void *mempcpy(void *dst, const void *src, size_t n)
| ^
/usr/include/string.h:71:8: note: previous declaration is here
71 | void *(mempcpy)(void * __restrict,
const void * __restrict, size_t);
Fix the build by restoring a default definition of HAVE_MEMPCPY since
we have had mempcpy() since 13.1.
Approved by: kevans, mikael (maintainer)
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D46053