Page MenuHomeFreeBSD

aarch64: disable LIB32 with gcc
ClosedPublic

Authored by brooks on May 3 2024, 10:23 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Nov 4, 10:12 AM
Unknown Object (File)
Sat, Oct 19, 4:47 PM
Unknown Object (File)
Oct 8 2024, 1:53 PM
Unknown Object (File)
Oct 8 2024, 1:53 PM
Unknown Object (File)
Oct 8 2024, 1:53 PM
Unknown Object (File)
Oct 8 2024, 1:53 PM
Unknown Object (File)
Oct 8 2024, 1:28 PM
Unknown Object (File)
Oct 4 2024, 12:52 AM

Details

Summary

gcc doesn't have -m32 support on aarch64 so mark LIB32 broken there.

We have to check both COMPILER_TYPE and X_COMPILER_TYPE becuase
X_COMPILER_TYPE is only conditionally set and COMPILER_TYPE is the host
compiler in Makefile.inc1.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

The easiest way to address this would probably be a cross toolchain wrapper script that picks the right compiler when -m32 is on the command line, but just disabling it for now seems reasonable. (I'm trying to test make tinderbox with gcc13 and this was one of the issues I encountered.)

share/mk/src.opts.mk
306

Won't this do weird things at the top level if CC is gcc but XCC is clang?

share/mk/src.opts.mk
306

I guess we might want ((defined(X_COMPILER_TYPE) && ${X_COMPILER_TYPE} != "gcc") || (!defined(X_COMPILER_TYPE) && ${COMPILER_TYPE} != "gcc")) instead so we only consider COMPILER_TYPE when X_COMPILER_TYPE is not defined.

  • sort arch list
  • examine X_COMPILER_TYPE if defined and COMPILER_TYPE iff X_COMPILER_TYPE is not defined.

I have no objection to this, but don't know the vagaries of the different compilers.

Is there an issue open somewhere for the gcc deficiency?

This revision is now accepted and ready to land.May 9 2024, 12:29 PM
This revision was automatically updated to reflect the committed changes.