Skip to content

Commit

Permalink
remove -fstack-clash-protection warnings on FreeBSD/arm64
Browse files Browse the repository at this point in the history
FreeBSD on arm64 gives warnings like this:

```
DEP gbsinfo.c -o gbsinfo.d
cc: warning: argument unused during compilation: '-fstack-clash-protection' [-Wunused-command-line-argument]
DEP plugout_wav.c -o plugout_wav.d
cc: warning: argument unused during compilation: '-fstack-clash-protection' [-Wunused-command-line-argument]
```

Fix these warnings by not setting -fstack-clash-protection if it would
not get used.
  • Loading branch information
mmitch committed Jan 29, 2024
1 parent cb63cc4 commit d990afa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion configure
Original file line number Diff line number Diff line change
Expand Up @@ -1126,7 +1126,7 @@ EOF
append_nodupe CFLAGS "--param=ssp-buffer-size=4"
fi
if cc_has_flag "-fstack-clash-protection" \
&& cc_check "checking if -fstack-clash-protection actually works" "" "-fstack-clash-protection" "yes" "no" <<EOF; then
&& cc_check "checking if -fstack-clash-protection actually works" "" "-fstack-clash-protection -Wunused-command-line-argument" "yes" "no" <<EOF; then
int main(int argc, char **argv)
{
char buf[65536];
Expand Down

0 comments on commit d990afa

Please sign in to comment.