+2017-10-31 Sandra Loosemore <sandra@codesourcery.com>
+
+ * configure.ac (--enable-libssp): New.
+ (gcc_cv_libc_provides_ssp): Check for explicit setting before
+ trying to determine target-specific default. Adjust indentation.
+ * configure: Regenerated.
+ * doc/install.texi (Configuration): Expand --disable-libssp
+ documentation.
+
2017-10-31 Daniel Santos <daniel.santos@pobox.com>
config/i386/i386.c (ix86_expand_epilogue): Correct stack
with_glibc_version
enable_gnu_unique_object
enable_linker_build_id
+enable_libssp
enable_default_ssp
with_long_double_128
with_gc
extension on glibc systems
--enable-linker-build-id
compiler will always pass --build-id to linker
+ --enable-libssp enable linking against libssp
--enable-default-ssp enable Stack Smashing Protection as default
--enable-maintainer-mode
enable make rules and dependencies not useful (and
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 18443 "configure"
+#line 18445 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 18549 "configure"
+#line 18551 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
fi
+# Check whether --enable-libssp was given.
+if test "${enable_libssp+set}" = set; then :
+ enableval=$enable_libssp; case "${enableval}" in
+ yes|no)
+ ;;
+ *)
+ as_fn_error "unknown libssp setting $enableval" "$LINENO" 5
+ ;;
+esac
+fi
+
+
# Test for stack protector support in target C library.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking __stack_chk_fail in target C library" >&5
$as_echo_n "checking __stack_chk_fail in target C library... " >&6; }
$as_echo_n "(cached) " >&6
else
gcc_cv_libc_provides_ssp=no
+ if test "x$enable_libssp" = "xno"; then
+ gcc_cv_libc_provides_ssp=yes
+ elif test "x$enable_libssp" = "xyes"; then
+ gcc_cv_libc_provides_ssp=no
+ else
case "$target" in
*-*-musl*)
# All versions of musl provide stack protector
fi
;;
- *) gcc_cv_libc_provides_ssp=no ;;
+ *) gcc_cv_libc_provides_ssp=no ;;
esac
+ fi
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_libc_provides_ssp" >&5
$as_echo "$gcc_cv_libc_provides_ssp" >&6; }
[Define if the system-provided CRTs are present on Solaris.])
fi
+AC_ARG_ENABLE(libssp,
+[AS_HELP_STRING([--enable-libssp], [enable linking against libssp])],
+[case "${enableval}" in
+ yes|no)
+ ;;
+ *)
+ AC_MSG_ERROR([unknown libssp setting $enableval])
+ ;;
+esac], [])
+
# Test for stack protector support in target C library.
AC_CACHE_CHECK(__stack_chk_fail in target C library,
- gcc_cv_libc_provides_ssp,
- [gcc_cv_libc_provides_ssp=no
+ gcc_cv_libc_provides_ssp,
+ [gcc_cv_libc_provides_ssp=no
+ if test "x$enable_libssp" = "xno"; then
+ gcc_cv_libc_provides_ssp=yes
+ elif test "x$enable_libssp" = "xyes"; then
+ gcc_cv_libc_provides_ssp=no
+ else
case "$target" in
*-*-musl*)
# All versions of musl provide stack protector
AC_CHECK_FUNC(__stack_chk_fail,[gcc_cv_libc_provides_ssp=yes],
[echo "no __stack_chk_fail on this target"])
;;
- *) gcc_cv_libc_provides_ssp=no ;;
- esac])
+ *) gcc_cv_libc_provides_ssp=no ;;
+ esac
+ fi])
if test x$gcc_cv_libc_provides_ssp = xyes; then
AC_DEFINE(TARGET_LIBC_PROVIDES_SSP, 1,
@item --disable-libssp
Specify that the run-time libraries for stack smashing protection
-should not be built.
+should not be built or linked against. On many targets library support
+is provided by the C library instead.
@item --disable-libquadmath
Specify that the GCC quad-precision math library should not be built.