Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

glib2, libfido2: remove PKG_FORTIFY_SOURCE workarounds #21467

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

ynezz
Copy link
Member

@ynezz ynezz commented Jun 29, 2023

Maintainer: @neheb @stintel @linosgian
Compile tested: snapshot, aarch64_cortex-a53_gcc-12.3.0_musl, PKG_FORTIFY_SOURCE_2=y
Run tested: N/A

Description:

While reviewing openwrt/openwrt#13001 I've tried to reproduce the mentioned issue with glib2 and libfido2 and found out, that this workaround is probably not needed anymore and should be removed.

This reverts commit 723c436 as it
seems, that its not needed anymore, build tested with
aarch64_cortex-a53_gcc-12.3.0_musl and PKG_FORTIFY_SOURCE_2=y

Signed-off-by: Petr Štetiar <ynezz@true.cz>
Its not needed anymore, build tested with
aarch64_cortex-a53_gcc-12.3.0_musl and PKG_FORTIFY_SOURCE_2=y.

Signed-off-by: Petr Štetiar <ynezz@true.cz>
@neheb
Copy link
Contributor

neheb commented Jun 29, 2023

@stintel can still reproduce AFAIK.

edit: btw issues show up with fortify source 1, not 2.

@ynezz
Copy link
Member Author

ynezz commented Jun 29, 2023

@stintel can still reproduce AFAIK.

Ok, what is the magic combination?

edit: btw issues show up with fortify source 1, no 2.

Both should work fine.

@ynezz ynezz force-pushed the ynezz/remove-fortify-workarounds branch from cd05aa5 to 0403e4a Compare June 29, 2023 09:08
Library forces _FORTIFY_SOURCE=2 and thus when we configure
_FORTIFY_SOURCE=1 we create following compile failure:

 <command-line>: error: "_FORTIFY_SOURCE" redefined

Signed-off-by: Petr Štetiar <ynezz@true.cz>
@stintel
Copy link
Member

stintel commented Jun 29, 2023

Confirmed, glib2 still fails to build for me on qoriq.
compile.txt
qoriq-m300-diffconfig.txt

It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
@ynezz
Copy link
Member Author

ynezz commented Jun 29, 2023

Confirmed, glib2 still fails to build for me on qoriq.

Thanks, looks like some powerpc64 related issue, so lets keep it disabled on that platform only? I would love to check what is failing, but its probably too deep rabbit hole and don't have much time right now to fix that properly, sorry.

@ksperling-apple
Copy link

Please see my comment here: openwrt/openwrt#13001 (comment)

stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Jul 15, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Jul 17, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Jul 23, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Jul 24, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Jul 26, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Jul 27, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Aug 2, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Aug 2, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Aug 2, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Aug 4, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Aug 30, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Sep 27, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Sep 30, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Oct 19, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Oct 29, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Oct 31, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Nov 8, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Nov 9, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Nov 23, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Nov 30, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Dec 2, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Dec 21, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Dec 29, 2023
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Jan 2, 2024
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Feb 7, 2024
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Feb 20, 2024
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Feb 24, 2024
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Feb 27, 2024
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Feb 27, 2024
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Mar 19, 2024
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Mar 23, 2024
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Mar 30, 2024
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Apr 4, 2024
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Apr 15, 2024
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Apr 23, 2024
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Apr 26, 2024
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Apr 29, 2024
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request Apr 30, 2024
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request May 3, 2024
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request May 5, 2024
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request May 16, 2024
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
stintel pushed a commit to stintel/openwrt-packages that referenced this pull request May 22, 2024
It seems, that powerpc64 is still not able to compile glib2 with
FORTIFY_SOURCE enabled:

 [81/481] Compiling C object glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 FAILED: glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o
 powerpc64-openwrt-linux-musl-gcc -Iglib/libglib-2.0.so.0.7400.0.p -Iglib -I../glib -I. -I.. -Iopenwrt/staging_dir/target-powerpc64_e5500_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/usr/include -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify -Iopenwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include -flto=auto -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu99 -D_GNU_SOURCE -fno-strict-aliasing -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wduplicated-branches -Wimplicit-fallthrough -Wmisleading-indentation -Wunused -Wno-unused-parameter -Wno-cast-function-type -Wno-pedantic -Wno-format-zero-length -Wno-variadic-macros -Werror=format=2 -Werror=init-self -Werror=missing-include-dirs -Werror=pointer-arith -Werror=unused-result -Wstrict-prototypes -Wno-bad-function-cast -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=pointer-sign -Os -pipe -mcpu=e5500 -g3 -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=openwrt/build_dir/target-powerpc64_e5500_musl/glib-2.74.0=glib-2.74.0 -ffunction-sections -fdata-sections -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -MF glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o.d -o glib/libglib-2.0.so.0.7400.0.p/gkeyfile.c.o -c ../glib/gkeyfile.c
 In file included from ../glib/gkeyfile.c:35:
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'snprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:101:9: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   101 |         return __orig_snprintf(__s, __n, __f, __builtin_va_arg_pack());
       |         ^~~~~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h: In function 'sprintf':
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:110:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   110 |                 __r = __orig_snprintf(__s, __b, __f, __builtin_va_arg_pack());
       |                 ^~~
 openwrt/staging_dir/toolchain-powerpc64_e5500_gcc-12.3.0_musl/include/fortify/stdio.h:114:17: error: format not a string literal, argument types not checked [-Werror=format-nonliteral]
   114 |                 __r = __orig_sprintf(__s, __f, __builtin_va_arg_pack());
       |                 ^~~
 cc1: some warnings being treated as errors

So lets enable PKG_FORTIFY_SOURCE workaround on the affected platform
only.

References: openwrt#21467 (comment)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants