2.00 fails to build with gcc7
Executando (%prep): /bin/sh -e /var/tmp/rpm-tmp.6YFHxR
+ umask 022
+ cd /home/filiperosset/rpmbuild/extras/blobwars
+ cd /home/filiperosset/rpmbuild/extras/blobwars
+ rm -rf blobwars-2.00
+ /usr/bin/gzip -dc /home/filiperosset/rpmbuild/extras/blobwars/blobwars-2.00.tar.gz
+ /usr/bin/tar -xof -
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ cd blobwars-2.00
+ /usr/bin/chmod -Rf a+rX,u+w,g-w,o-w .
+ exit 0
Executando (%build): /bin/sh -e /var/tmp/rpm-tmp.5v41Ev
+ umask 022
+ cd /home/filiperosset/rpmbuild/extras/blobwars
+ cd blobwars-2.00
+ make -j8 'CFLAGS=-O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic' RELEASE=1 DOCDIR=/usr/share/doc/blobwars/
g++ pkg-config --cflags sdl2 SDL2_mixer SDL2_image SDL2_ttf SDL2_net
-DVERSION=2.00 -DRELEASE=1 -DUSEPAK=0 -DPAKNAME=\"blobwars.pak\" -DPAKLOCATION=\"/usr/share/games/blobwars/\" -DUNIX -DGAMEPLAYMANUAL=\"/usr/share/doc/blobwars/index.html\" -Wall -DLOCALEDIR=\"/usr/share/locale/\" -DMEDAL_SERVER_HOST=\"www.parallelrealities.co.uk\" -DMEDAL_SERVER_PORT=80 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -Werror -c src/CAudio.cpp
g++ pkg-config --cflags sdl2 SDL2_mixer SDL2_image SDL2_ttf SDL2_net
-DVERSION=2.00 -DRELEASE=1 -DUSEPAK=0 -DPAKNAME=\"blobwars.pak\" -DPAKLOCATION=\"/usr/share/games/blobwars/\" -DUNIX -DGAMEPLAYMANUAL=\"/usr/share/doc/blobwars/index.html\" -Wall -DLOCALEDIR=\"/usr/share/locale/\" -DMEDAL_SERVER_HOST=\"www.parallelrealities.co.uk\" -DMEDAL_SERVER_PORT=80 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -Werror -c src/CBoss.cpp
g++ pkg-config --cflags sdl2 SDL2_mixer SDL2_image SDL2_ttf SDL2_net
-DVERSION=2.00 -DRELEASE=1 -DUSEPAK=0 -DPAKNAME=\"blobwars.pak\" -DPAKLOCATION=\"/usr/share/games/blobwars/\" -DUNIX -DGAMEPLAYMANUAL=\"/usr/share/doc/blobwars/index.html\" -Wall -DLOCALEDIR=\"/usr/share/locale/\" -DMEDAL_SERVER_HOST=\"www.parallelrealities.co.uk\" -DMEDAL_SERVER_PORT=80 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -Werror -c src/CCollision.cpp
g++ pkg-config --cflags sdl2 SDL2_mixer SDL2_image SDL2_ttf SDL2_net
-DVERSION=2.00 -DRELEASE=1 -DUSEPAK=0 -DPAKNAME=\"blobwars.pak\" -DPAKLOCATION=\"/usr/share/games/blobwars/\" -DUNIX -DGAMEPLAYMANUAL=\"/usr/share/doc/blobwars/index.html\" -Wall -DLOCALEDIR=\"/usr/share/locale/\" -DMEDAL_SERVER_HOST=\"www.parallelrealities.co.uk\" -DMEDAL_SERVER_PORT=80 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -Werror -c src/CCutscene.cpp
g++ pkg-config --cflags sdl2 SDL2_mixer SDL2_image SDL2_ttf SDL2_net
-DVERSION=2.00 -DRELEASE=1 -DUSEPAK=0 -DPAKNAME=\"blobwars.pak\" -DPAKLOCATION=\"/usr/share/games/blobwars/\" -DUNIX -DGAMEPLAYMANUAL=\"/usr/share/doc/blobwars/index.html\" -Wall -DLOCALEDIR=\"/usr/share/locale/\" -DMEDAL_SERVER_HOST=\"www.parallelrealities.co.uk\" -DMEDAL_SERVER_PORT=80 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -Werror -c src/CConfig.cpp
g++ pkg-config --cflags sdl2 SDL2_mixer SDL2_image SDL2_ttf SDL2_net
-DVERSION=2.00 -DRELEASE=1 -DUSEPAK=0 -DPAKNAME=\"blobwars.pak\" -DPAKLOCATION=\"/usr/share/games/blobwars/\" -DUNIX -DGAMEPLAYMANUAL=\"/usr/share/doc/blobwars/index.html\" -Wall -DLOCALEDIR=\"/usr/share/locale/\" -DMEDAL_SERVER_HOST=\"www.parallelrealities.co.uk\" -DMEDAL_SERVER_PORT=80 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -Werror -c src/CData.cpp
g++ pkg-config --cflags sdl2 SDL2_mixer SDL2_image SDL2_ttf SDL2_net
-DVERSION=2.00 -DRELEASE=1 -DUSEPAK=0 -DPAKNAME=\"blobwars.pak\" -DPAKLOCATION=\"/usr/share/games/blobwars/\" -DUNIX -DGAMEPLAYMANUAL=\"/usr/share/doc/blobwars/index.html\" -Wall -DLOCALEDIR=\"/usr/share/locale/\" -DMEDAL_SERVER_HOST=\"www.parallelrealities.co.uk\" -DMEDAL_SERVER_PORT=80 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -Werror -c src/CEffect.cpp
g++ pkg-config --cflags sdl2 SDL2_mixer SDL2_image SDL2_ttf SDL2_net
-DVERSION=2.00 -DRELEASE=1 -DUSEPAK=0 -DPAKNAME=\"blobwars.pak\" -DPAKLOCATION=\"/usr/share/games/blobwars/\" -DUNIX -DGAMEPLAYMANUAL=\"/usr/share/doc/blobwars/index.html\" -Wall -DLOCALEDIR=\"/usr/share/locale/\" -DMEDAL_SERVER_HOST=\"www.parallelrealities.co.uk\" -DMEDAL_SERVER_PORT=80 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -Werror -c src/CEngine.cpp
g++ pkg-config --cflags sdl2 SDL2_mixer SDL2_image SDL2_ttf SDL2_net
-DVERSION=2.00 -DRELEASE=1 -DUSEPAK=0 -DPAKNAME=\"blobwars.pak\" -DPAKLOCATION=\"/usr/share/games/blobwars/\" -DUNIX -DGAMEPLAYMANUAL=\"/usr/share/doc/blobwars/index.html\" -Wall -DLOCALEDIR=\"/usr/share/locale/\" -DMEDAL_SERVER_HOST=\"www.parallelrealities.co.uk\" -DMEDAL_SERVER_PORT=80 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -Werror -c src/CEntity.cpp
g++ pkg-config --cflags sdl2 SDL2_mixer SDL2_image SDL2_ttf SDL2_net
-DVERSION=2.00 -DRELEASE=1 -DUSEPAK=0 -DPAKNAME=\"blobwars.pak\" -DPAKLOCATION=\"/usr/share/games/blobwars/\" -DUNIX -DGAMEPLAYMANUAL=\"/usr/share/doc/blobwars/index.html\" -Wall -DLOCALEDIR=\"/usr/share/locale/\" -DMEDAL_SERVER_HOST=\"www.parallelrealities.co.uk\" -DMEDAL_SERVER_PORT=80 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -Werror -c src/CFileData.cpp
g++ pkg-config --cflags sdl2 SDL2_mixer SDL2_image SDL2_ttf SDL2_net
-DVERSION=2.00 -DRELEASE=1 -DUSEPAK=0 -DPAKNAME=\"blobwars.pak\" -DPAKLOCATION=\"/usr/share/games/blobwars/\" -DUNIX -DGAMEPLAYMANUAL=\"/usr/share/doc/blobwars/index.html\" -Wall -DLOCALEDIR=\"/usr/share/locale/\" -DMEDAL_SERVER_HOST=\"www.parallelrealities.co.uk\" -DMEDAL_SERVER_PORT=80 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -Werror -c src/CGame.cpp
g++ pkg-config --cflags sdl2 SDL2_mixer SDL2_image SDL2_ttf SDL2_net
-DVERSION=2.00 -DRELEASE=1 -DUSEPAK=0 -DPAKNAME=\"blobwars.pak\" -DPAKLOCATION=\"/usr/share/games/blobwars/\" -DUNIX -DGAMEPLAYMANUAL=\"/usr/share/doc/blobwars/index.html\" -Wall -DLOCALEDIR=\"/usr/share/locale/\" -DMEDAL_SERVER_HOST=\"www.parallelrealities.co.uk\" -DMEDAL_SERVER_PORT=80 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -Werror -c src/CGameData.cpp
src/CConfig.cpp: In member function 'bool Config::loadJoystickConfig()':
src/CConfig.cpp:89:6: error: 'joystick.cfg' directive output may be truncated writing 12 bytes into a region of size between 1 and 4096 [-Werror=format-truncation=]
bool Config::loadJoystickConfig()
^~~~~~
In file included from /usr/include/stdio.h:889:0,
from src/headers.h:23,
from src/CConfig.cpp:1:
/usr/include/bits/stdio2.h:65:44: note: 'builtinsnprintf_chk' output between 13 and 4108 bytes into a destination of size 4096
bos (s), fmt, va_arg_pack ());
^
src/CConfig.cpp: In member function 'bool Config::saveJoystickConfig()':
src/CConfig.cpp:114:6: error: 'joystick.cfg' directive output may be truncated writing 12 bytes into a region of size between 1 and 4096 [-Werror=format-truncation=]
bool Config::saveJoystickConfig()
^~~~~~
In file included from /usr/include/stdio.h:889:0,
from src/headers.h:23,
from src/CConfig.cpp:1:
/usr/include/bits/stdio2.h:65:44: note: '__builtinsnprintf_chk' output between 13 and 4108 bytes into a destination of size 4096
bos (s), fmt, va_arg_pack ());
^
src/CConfig.cpp: In member function 'bool Config::loadKeyConfig()':
src/CConfig.cpp:141:6: error: 'keyboard.cfg' directive output may be truncated writing 12 bytes into a region of size between 1 and 4096 [-Werror=format-truncation=]
bool Config::loadKeyConfig()
^~~~~~
In file included from /usr/include/stdio.h:889:0,
from src/headers.h:23,
from src/CConfig.cpp:1:
/usr/include/bits/stdio2.h:65:44: note: 'builtinsnprintf_chk' output between 13 and 4108 bytes into a destination of size 4096
bos (s), fmt, va_arg_pack ());
^
src/CConfig.cpp: In member function 'bool Config::saveKeyConfig()':
src/CConfig.cpp:169:6: error: 'keyboard.cfg' directive output may be truncated writing 12 bytes into a region of size between 1 and 4096 [-Werror=format-truncation=]
bool Config::saveKeyConfig()
^~~~~~
In file included from /usr/include/stdio.h:889:0,
from src/headers.h:23,
from src/CConfig.cpp:1:
/usr/include/bits/stdio2.h:65:44: note: '__builtinsnprintf_chk' output between 13 and 4108 bytes into a destination of size 4096
bos (s), fmt, va_arg_pack ());
^
cc1plus: all warnings being treated as errors
make: [Makefile:82: CConfig.o] Error 1
make: Waiting for unfinished jobs....
src/CAudio.cpp: In member function 'bool Audio::loadMusic(const char)':
src/CAudio.cpp:101:6: error: 'music.mod' directive output may be truncated writing 9 bytes into a region of size between 1 and 4096 [-Werror=format-truncation=]
bool Audio::loadMusic(const char filename)
^~~~~
In file included from /usr/include/stdio.h:889:0,
from src/headers.h:23,
from src/CAudio.cpp:22:
/usr/include/bits/stdio2.h:65:44: note: 'builtinsnprintf_chk' output between 10 and 4105 bytes into a destination of size 4096
bos (s), fmt, va_arg_pack ());
^
src/CAudio.cpp: In member function 'bool Audio::loadGameOverMusic()':
src/CAudio.cpp:246:6: error: 'music.mod' directive output may be truncated writing 9 bytes into a region of size between 1 and 4096 [-Werror=format-truncation=]
bool Audio::loadGameOverMusic()
^~~~~
In file included from /usr/include/stdio.h:889:0,
from src/headers.h:23,
from src/CAudio.cpp:22:
/usr/include/bits/stdio2.h:65:44: note: '__builtinsnprintf_chk' output between 10 and 4105 bytes into a destination of size 4096
bos (s), fmt, __va_arg_pack ());
^
cc1plus: all warnings being treated as errors
make: [Makefile:82: CAudio.o] Error 1
src/CEngine.cpp: In member function 'bool Engine::unpack(const char, int)':
src/CEngine.cpp:374:6: error: 'music.tags' directive output may be truncated writing 10 bytes into a region of size between 1 and 4096 [-Werror=format-truncation=]
bool Engine::unpack(const char filename, int fileType)
^~~~~~
In file included from /usr/include/stdio.h:889:0,
from src/headers.h:23,
from src/CEngine.cpp:22:
/usr/include/bits/stdio2.h:65:44: note: 'builtin_snprintf_chk' output between 11 and 4106 bytes into a destination of size 4096
bos (s), fmt, va_arg_pack ());
^
src/CEngine.cpp:374:6: error: 'music.mod' directive output may be truncated writing 9 bytes into a region of size between 1 and 4096 [-Werror=format-truncation=]
bool Engine::unpack(const char filename, int fileType)
^~~~~~
In file included from /usr/include/stdio.h:889:0,
from src/headers.h:23,
from src/CEngine.cpp:22:
/usr/include/bits/stdio2.h:65:44: note: 'builtin_snprintf_chk' output between 10 and 4105 bytes into a destination of size 4096
bos (s), fmt, va_arg_pack ());
^
src/CEngine.cpp:374:6: error: 'font.ttf' directive output may be truncated writing 8 bytes into a region of size between 1 and 4096 [-Werror=format-truncation=]
bool Engine::unpack(const char filename, int fileType)
^~~~~~
In file included from /usr/include/stdio.h:889:0,
from src/headers.h:23,
from src/CEngine.cpp:22:
/usr/include/bits/stdio2.h:65:44: note: 'builtin_snprintf_chk' output between 9 and 4104 bytes into a destination of size 4096
bos (s), fmt, va_arg_pack ());
^
cc1plus: all warnings being treated as errors
make: [Makefile:82: CEngine.o] Error 1
erro: Status de saída de /var/tmp/rpm-tmp.5v41Ev inválido (%build)
Erros na construção do RPM:
Status de saída de /var/tmp/rpm-tmp.5v41Ev inválido (%build)
fixed with -> https://src.fedoraproject.org/rpms/blobwars/raw/f4b6c16932f41913e7cc7cb20eee370e2ca8a531/f/blobwars-2.00-Werror.patch
building fine with gcc version 9.1.1 20190605 (Red Hat 9.1.1-2) (GCC)