[Bug 272806] aarch64's -m32 for system-clang uses -triple armv7-unknown-freebsd14.0 instead of -target armv7-unknown-freebsd14.0-gnueabihf
Date: Sun, 30 Jul 2023 03:03:47 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=272806
Bug ID: 272806
Summary: aarch64's -m32 for system-clang uses -triple
armv7-unknown-freebsd14.0 instead of -target
armv7-unknown-freebsd14.0-gnueabihf
Product: Base System
Version: CURRENT
Hardware: arm64
OS: Any
Status: New
Severity: Affects Some People
Priority: ---
Component: bin
Assignee: bugs@FreeBSD.org
Reporter: marklmi26-fbsd@yahoo.com
-m32 using -triple armv7-unknown-freebsd14.0 leads to attempted usage that
involves floating point getting build problems like:
ld.lld: error: undefined symbol: __muldf3
. . .
did you mean: __muldc3
defined in: /usr/lib32/libgcc_s.so
ld.lld: error: undefined symbol: __divdf3
. . .
did you mean: __divdc3
defined in: /usr/lib32/libgcc_s.so
ld.lld: error: undefined symbol: __ltdf2
. . .
devel/llvm* ( or, at least, devel/llvm16+ ) likely should use the
correct target for FreeBSD by default as well. For 14.0 that would
be -m32 for aarch64 using:
-target armv7-unknown-freebsd14.0-gnueabihf
Of course, this will generalize to FreeBSD 14.1+ and 15+ as well and
to llvm17+ for them.
[It may be less certain what should be done for aarch64 FreeBSD
versions that do not have lib32. (Less reason to be using -m32.)]
I'll note that I would argue that requiring explicit
-m32 -target armv7-unknown-freebsd14.0-gnueabihf
like notation adds the the using code needing to track 14.x/15+/...
as things progress, even when not trying to do a cross build. Even
if made automatic, making it so ends up being explicit in more
places.
--
You are receiving this mail because:
You are the assignee for the bug.