2.7.2: is not gcc 14.x ready
Brought to you by:
kmatsui
Looks like last version build fails with latest gcc 14.x which is now used in fedora rawhide.
[tkloczko@pers-jacek mcpp-2.7.2]$ make
Making all in src
make[1]: Entering directory '/home/tkloczko/rpmbuild/BUILD/mcpp-2.7.2/src'
make all-am
make[2]: Entering directory '/home/tkloczko/rpmbuild/BUILD/mcpp-2.7.2/src'
/bin/sh ../libtool --tag=CC --mode=compile /usr/bin/gcc -DHAVE_CONFIG_H -I. -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -O2 -g -grecord-gcc-switches -pipe -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -fdata-sections -ffunction-sections -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -flto=auto -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -Wall -Werror=format-security -c -o expand.lo expand.c
libtool: compile: /usr/bin/gcc -DHAVE_CONFIG_H -I. -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -O2 -g -grecord-gcc-switches -pipe -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -fdata-sections -ffunction-sections -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -flto=auto -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -Wall -Werror=format-security -c expand.c -fPIC -DPIC -o .libs/expand.o
expand.c: In function 'chk_magic_balance':
expand.c:503:13: warning: variable 'mac_loc' set but not used [-Wunused-but-set-variable]
503 | char * mac_loc[ MAX_NEST_MAGICS];
| ^~~~~~~
expand.c: In function 'replace':
expand.c:713:21: error: assignment to 'char *' from incompatible pointer type 'LOCATION *' {aka 'struct location *'} [-Wincompatible-pointer-types]
713 | m_inf->args = m_inf->loc_args = NULL; /* Default args */
| ^
expand.c: In function 'substitute':
expand.c:1753:13: warning: variable 'gvar_arg' set but not used [-Wunused-but-set-variable]
1753 | int gvar_arg; /* gvar_arg'th argument is GCC variable argument */
| ^~~~~~~~
expand.c:1751:21: warning: unused variable 'arg' [-Wunused-variable]
1751 | const char * arg;
| ^~~
expand.c:1750:13: warning: unused variable 'out_start' [-Wunused-variable]
1750 | char * out_start = out;
| ^~~~~~~~~
expand.c: In function 'rescan':
expand.c:1975:41: warning: assignment discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
1975 | mgc_cleared = remove_magics(
| ^
make[2]: *** [Makefile:590: expand.lo] Error 1
make[2]: Leaving directory '/home/tkloczko/rpmbuild/BUILD/mcpp-2.7.2/src'
BTW is it possible to move git repo to github/gitlab or at least organize live mirror?
sf.net rest interface do not allow download exact git commit patch over REST interface.
FWIW, I've imported the SourceForge mcpp repo into github, applied the patches from the Fedora package (except for the Japanese html one, which breaks the file because it isn't actually encoded in UTF-8).
I've also started to apply other fixes, including a commit for this gcc 14.x build problem.
https://github.com/jbrandwood/mcpp/commit/3b274fe8f31d61996343b17402f30408a6e447cf
Best wishes,
John
Last edit: John Brandwood 2024-03-16