Merge pull request #5859 from kmk3/build-remove-retpoline

build: remove -mretpoline and NO_EXTRA_CFLAGS
This commit is contained in:
Kelvin M. Klann 2023-06-20 05:26:23 +00:00 committed by GitHub
commit a8f01a383a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 2 additions and 48 deletions

View file

@ -105,7 +105,7 @@ jobs:
--enable-selinux
|| (cat config.log; exit 1)
- name: scan-build
run: NO_EXTRA_CFLAGS="yes" scan-build-14 --status-bugs make
run: scan-build-14 --status-bugs make
cppcheck:
runs-on: ubuntu-22.04
steps:

View file

@ -358,7 +358,7 @@ cppcheck: clean
.PHONY: scan-build
scan-build: clean
NO_EXTRA_CFLAGS="yes" scan-build make
scan-build make
.PHONY: codespell
codespell: clean

View file

@ -61,9 +61,5 @@ LDFLAGS=@LDFLAGS@
# Project variables
LIBS=@LIBS@
ifdef NO_EXTRA_CFLAGS
else
EXTRA_CFLAGS +=@EXTRA_CFLAGS@
endif
EXTRA_LDFLAGS +=@EXTRA_LDFLAGS@

38
configure vendored
View file

@ -2925,44 +2925,6 @@ else
:
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mretpoline" >&5
$as_echo_n "checking whether C compiler accepts -mretpoline... " >&6; }
if ${ax_cv_check_cflags___mretpoline+:} false; then :
$as_echo_n "(cached) " >&6
else
ax_check_save_flags=$CFLAGS
CFLAGS="$CFLAGS -mretpoline"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
main ()
{
;
return 0;
}
_ACEOF
if ac_fn_c_try_compile "$LINENO"; then :
ax_cv_check_cflags___mretpoline=yes
else
ax_cv_check_cflags___mretpoline=no
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
CFLAGS=$ax_check_save_flags
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mretpoline" >&5
$as_echo "$ax_cv_check_cflags___mretpoline" >&6; }
if test "x$ax_cv_check_cflags___mretpoline" = xyes; then :
HAVE_SPECTRE="yes"
EXTRA_CFLAGS="$EXTRA_CFLAGS -mretpoline"
else
:
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fstack-clash-protection" >&5
$as_echo_n "checking whether C compiler accepts -fstack-clash-protection... " >&6; }
if ${ax_cv_check_cflags___fstack_clash_protection+:} false; then :

View file

@ -25,10 +25,6 @@ AX_CHECK_COMPILE_FLAG([-mindirect-branch=thunk], [
HAVE_SPECTRE="yes"
EXTRA_CFLAGS="$EXTRA_CFLAGS -mindirect-branch=thunk"
])
AX_CHECK_COMPILE_FLAG([-mretpoline], [
HAVE_SPECTRE="yes"
EXTRA_CFLAGS="$EXTRA_CFLAGS -mretpoline"
])
AX_CHECK_COMPILE_FLAG([-fstack-clash-protection], [
HAVE_SPECTRE="yes"
EXTRA_CFLAGS="$EXTRA_CFLAGS -fstack-clash-protection"