[ATTN] GCC and make Maintainers: SUS V5 POSIX 2024 make CC default c17
ASSI
Stromeko@nexgo.de
Sun Nov 1 18:08:18 GMT 2026
ASSI via Cygwin-apps writes:
> I'll add the c17 wrapper with the same semantics as the existing ones
> (i.e. strict compliance, which is useless for just about all sources)
> for the next update.
That'll be the new .ccwrapper going forward for Cygwin:
--8<---------------cut here---------------start------------->8---
#!/bin/dash
error () {
echo "$std called with non ISO ${STD} option '$1'" >&2
exit 1
}
std="$(basename $0)"
STD=$(printf "%s" "$std" | tr [:lower:] [:upper:])
flg="-std=$std"
iso="_unknown_"
case "$std" in
c89) iso="iso9899:1990";;
c94) iso="iso9899:199409";;
c95) iso="iso9899:199409";;
c99) iso="iso9899:1999";;
c11) iso="iso9899:2011";;
c17) iso="iso9899:2017";;
c23) iso="iso9899:2024";;
esac
[ "_unknown_" = "$iso" ] && error "$iso"
for opt; do
case "$opt" in
-ansi) [ "c89" = "$std" ] && unset flg || error "$opt";;
-std="$std"|-std="$iso") unset flg;;
-std=*) error "$opt"
esac
done
exec /usr/bin/gcc ${flg+"$flg" }${1+"$@"}
--8<---------------cut here---------------end--------------->8---
Put it in /bin and link c17 to it (the existing c89 and c99 scripts will
become links as well, I'm not going to provide the other wrappers that
are possible based on GCC documentation, but not required by any
standard I know of.
Regards,
Achim.
--
+<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+
Wavetables for the Terratec KOMPLEXER:
http://Synth.Stromeko.net/Downloads.html#KomplexerWaves
More information about the Cygwin-apps
mailing list