[Bug 294062] lang/gcc16-devel: does not build from source on arm64

From: <bugzilla-noreply_at_freebsd.org>
Date: Thu, 26 Mar 2026 11:56:56 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=294062

            Bug ID: 294062
           Summary: lang/gcc16-devel: does not build from source on arm64
           Product: Ports & Packages
           Version: Latest
          Hardware: arm64
                OS: Any
            Status: New
          Severity: Affects Many People
          Priority: ---
         Component: Individual Port(s)
          Assignee: salvadore@freebsd.org
          Reporter: jing@jing.rocks
          Assignee: salvadore@freebsd.org
             Flags: maintainer-feedback?(salvadore@freebsd.org)

Hi!

gcc16-devel fails to build from source on arm64:

/usr/ports/lang/gcc16-devel/work/.build/./gcc/xgcc
-B/usr/ports/lang/gcc16-devel/work/.build/./gcc/
-B/usr/local/aarch64-portbld-freebsd16.0/bin/
-B/usr/local/aarch64-portbld-freebsd16.0/lib/ -isystem
/usr/local/aarch64-portbld-freebsd16.0/include -isystem
/usr/local/aarch64-portbld-freebsd16.0/sys-include   -fno-checking -g -O2 -pipe
-D__USE_ISOC11 -DLIBICONV_PLUG -fstack-protector-strong -fno-strict-aliasing
-O2  -g -O2 -pipe  -D__USE_ISOC11 -DLIBICONV_PLUG -fstack-protector-strong
-fno-strict-aliasing  -DIN_GCC   -W -Wall -Wno-error=narrowing -Wwrite-strings
-Wcast-qual -Wno-format -Wstrict-prototypes -Wmissing-prototypes
-Wold-style-definition  -isystem ./include  -fPIC -pthread -g -DIN_LIBGCC2
-fbuilding-libgcc -fno-stack-protector  -Werror -Wno-prio-ctor-dtor -fPIC
-pthread -I. -I. -I../.././gcc
-I/usr/ports/lang/gcc16-devel/work/gcc-16-20260315/libgcc
-I/usr/ports/lang/gcc16-devel/work/gcc-16-20260315/libgcc/.
-I/usr/ports/lang/gcc16-devel/work/gcc-16-20260315/libgcc/../gcc
-I/usr/ports/lang/gcc16-devel/work/gcc-16-20260315/libgcc/../include
-I/usr/ports/lang/gcc16-devel/work/gcc-16-20260315/libgcc/config/aarch64
-I/usr/ports/lang/gcc16-devel/work/gcc-16-20260315/libgcc/config/libbid
-DENABLE_DECIMAL_BID_FORMAT -DHAVE_CC_TLS   -o cpuinfo.o -MT cpuinfo.o -MD -MP
-MF cpuinfo.dep  -c
/usr/ports/lang/gcc16-devel/work/gcc-16-20260315/libgcc/config/aarch64/cpuinfo.c
-fvisibility=hidden -DHIDE_EXPORTS
/usr/ports/lang/gcc16-devel/work/gcc-16-20260315/libgcc/config/aarch64/cpuinfo.c:51:9:
error: 'AT_HWCAP' redefined [-Werror]
   51 | #define AT_HWCAP 16
      |         ^~~~~~~~
In file included from /usr/include/sys/elf32.h:32,
                 from /usr/include/machine/elf.h:38,
                 from /usr/include/sys/auxv.h:33,
                 from
/usr/ports/lang/gcc16-devel/work/gcc-16-20260315/libgcc/config/aarch64/cpuinfo.c:35:
/usr/include/sys/elf_common.h:1018:9: note: this is the location of the
previous definition
 1018 | #define AT_HWCAP        25      /* CPU feature flags. */
      |         ^~~~~~~~
/usr/ports/lang/gcc16-devel/work/gcc-16-20260315/libgcc/config/aarch64/cpuinfo.c:53:9:
error: 'AT_HWCAP3' redefined [-Werror]
   53 | #define AT_HWCAP3 29
      |         ^~~~~~~~~
/usr/include/sys/elf_common.h:1031:9: note: this is the location of the
previous definition
 1031 | #define AT_HWCAP3       38      /* CPU feature flags 3. */
      |         ^~~~~~~~~
/usr/ports/lang/gcc16-devel/work/gcc-16-20260315/libgcc/config/aarch64/cpuinfo.c:54:9:
error: 'AT_HWCAP4' redefined [-Werror]
   54 | #define AT_HWCAP4 30
      |         ^~~~~~~~~
/usr/include/sys/elf_common.h:1032:9: note: this is the location of the
previous definition
 1032 | #define AT_HWCAP4       39      /* CPU feature flags 4. */
      |         ^~~~~~~~~
/usr/ports/lang/gcc16-devel/work/gcc-16-20260315/libgcc/config/aarch64/cpuinfo.c:
In function '__init_cpu_features':
/usr/ports/lang/gcc16-devel/work/gcc-16-20260315/libgcc/config/aarch64/cpuinfo.c:245:11:
error: implicit declaration of function 'getauxval'
[-Wimplicit-function-declaration]
  245 |   hwcap = getauxval (AT_HWCAP);
      |           ^~~~~~~~~
cc1: all warnings being treated as errors
gmake[3]: ***
[/usr/ports/lang/gcc16-devel/work/gcc-16-20260315/libgcc/shared-object.mk:14:
cpuinfo.o] Error 1
gmake[3]: Leaving directory
'/usr/ports/lang/gcc16-devel/work/.build/aarch64-portbld-freebsd16.0/libgcc'
gmake[2]: *** [Makefile:18532: all-stage1-target-libgcc] Error 2
gmake[2]: Leaving directory '/usr/ports/lang/gcc16-devel/work/.build'
gmake[1]: *** [Makefile:25261: stage1-bubble] Error 2
gmake[1]: Leaving directory '/usr/ports/lang/gcc16-devel/work/.build'
gmake: *** [Makefile:25593: bootstrap-lean] Error 2
*** Error code 1

Stop.
make[1]: stopped making
"/usr/ports/lang/gcc16-devel/work/.install_done.gcc._usr_local" in
/usr/ports/lang/gcc16-devel
*** Error code 1

Stop.
make: stopped making "install clean" in /usr/ports/lang/gcc16-devel

-- 
You are receiving this mail because:
You are the assignee for the bug.