Building elfutils with GCC 9 instead of older versions results in on amd64 platforms: In file included from ../config.h:132, from elf32_fsize.c:31: libelfP.h:47:30: error: '__elf32_msize' specifies less restrictive attribute than its target 'elf32_fsize': 'const' [-Werror=missing-attributes] 47 | #define __elfw2_(Bits, Name) __elf##Bits##_##Name | ^~~~~ This currently blocks the update of GCC_DEFAULT to that newer version, cf. PR 238330. Logs at http://package22.nyi.freebsd.org/data/112amd64-default-PR238330/2019-06-09_20h29m30s/logs/errors/elfutils-0.174_2.log http://package18.nyi.freebsd.org/data/120amd64-default-PR238330/2019-06-09_20h26m27s/logs/errors/elfutils-0.174_2.log https://gcc.gnu.org/gcc-9/porting_to.html and the general release notes https://gcc.gnu.org/gcc-9/changes.html may prove useful.
Created attachment 205449 [details] elfutils.diff - Cherry pick upstream commit be8080bdd746ac2b07fb0bcad23a9677844bb200 [1] to fix build with GCC 9 [1] https://sourceware.org/git/?p=elfutils.git;a=commitdiff;h=be8080bdd746ac2b07fb0bcad23a9677844bb200
No objection to backporting an upstream fix. Thanks!
Committed, thanks!
A commit references this bug: Author: tobik Date: Mon Jul 1 14:55:02 UTC 2019 New revision: 505576 URL: https://svnweb.freebsd.org/changeset/ports/505576 Log: devel/elfutils: Fix build with GCC 9 In file included from ../config.h:132, from elf32_fsize.c:31: libelfP.h:47:30: error: '__elf32_msize' specifies less restrictive attribute than its target 'elf32_fsize': 'const' [-Werror=missing-attributes] 47 | #define __elfw2_(Bits, Name) __elf##Bits##_##Name | ^~~~~ http://package22.nyi.freebsd.org/data/112amd64-default-PR238330/2019-06-09_20h29m30s/logs/errors/elfutils-0.174_2.log Cherry pick upstream commit be8080bdd746ac2b07fb0bcad23a9677844bb200 PR: 238538 Submitted by: tobik Reported by: gerald, antoine (via exp-run) Approved by: cem (maintainer) Changes: head/devel/elfutils/Makefile head/devel/elfutils/files/patch-git_be8080bdd746