From e6c086bb348b85d8008f61fa0b3d50a1d3e380cf Mon Sep 17 00:00:00 2001 From: fche Date: Sat, 12 Jan 2008 18:31:00 +0000 Subject: add --enable-ssp configure option so developers can build like fedora does 2008-01-12 Frank Ch. Eigler PR 5603. * configure.ac: Add "--enable-ssp" to select -fstack-protector-all and similar runtime checking directives. * configure: Regenerated. --- configure.ac | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index d2a150b0..522af8d7 100644 --- a/configure.ac +++ b/configure.ac @@ -25,6 +25,8 @@ AC_PROG_MAKE_SET AC_SUBST(CFLAGS) AC_SUBST(CXXFLAGS) + + dnl enable option to generate code for using perfmon AC_ARG_ENABLE(perfmon, [ --enable-perfmon enable perfmon support (default is disabled)], @@ -81,6 +83,14 @@ sqlite3_LIBS="$LIBS" AC_SUBST(sqlite3_LIBS) LIBS="$SAVE_LIBS" + +AC_ARG_ENABLE([ssp], + [AC_HELP_STRING([--enable-ssp], [enable gcc stack-protector])]) +AS_IF([test "x$enable_ssp" == xyes], + [CFLAGS="$CFLAGS -fstack-protector-all -D_FORTIFY_SOURCE=2" + CXXFLAGS="$CXXFLAGS -fstack-protector-all -D_FORTIFY_SOURCE=2" + AC_MSG_NOTICE([Compiling with gcc -fstack-protector-all et al.])]) + build_elfutils=no AC_ARG_WITH([elfutils], AC_HELP_STRING([--with-elfutils=DIRECTORY], -- cgit