aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--configure.ac5
-rw-r--r--libsandbox/Makefile.am8
-rw-r--r--libsbutil/Makefile.am9
-rw-r--r--src/Makefile.am8
4 files changed, 18 insertions, 12 deletions
diff --git a/configure.ac b/configure.ac
index f142cb7..5235aae 100644
--- a/configure.ac
+++ b/configure.ac
@@ -232,6 +232,11 @@ dnl the variables ($sysconfdir defaults to "$prefix/etc")
SANDBOX_DEFINES='-DETCDIR="\"$(sysconfdir)\"" -DLIBSANDBOX_PATH="\"$(libdir)\"" -DSANDBOX_BASHRC_PATH="\"$(pkgdatadir)\""'
AC_SUBST([SANDBOX_DEFINES])
+CPPFLAGS="$CPPFLAGS -D_REENTRANT"
+if test "$GCC" = yes; then
+ CFLAGS="$CFLAGS -Wall"
+fi
+
AC_OUTPUT([
Makefile
scripts/Makefile
diff --git a/libsandbox/Makefile.am b/libsandbox/Makefile.am
index bf5708e..9b4a9b8 100644
--- a/libsandbox/Makefile.am
+++ b/libsandbox/Makefile.am
@@ -3,12 +3,12 @@ AUTOMAKE_OPTIONS = foreign
lib_LTLIBRARIES = libsandbox.la
AM_CPPFLAGS = \
- $(SANDBOX_DEFINES) \
- -DPIC -fPIC -D_REENTRANT \
- -I$(top_srcdir) -Wall
+ $(SANDBOX_DEFINES) \
+ -DPIC -fPIC
INCLUDES = \
- -I$(top_srcdir)/libsbutil \
+ -I$(top_srcdir) \
+ -I$(top_srcdir)/libsbutil \
-I$(top_srcdir)/libsbutil/include
# We need -fexceptions here, else we do not catch exceptions
diff --git a/libsbutil/Makefile.am b/libsbutil/Makefile.am
index 7d890d0..2f3f4a5 100644
--- a/libsbutil/Makefile.am
+++ b/libsbutil/Makefile.am
@@ -1,11 +1,12 @@
AUTOMAKE_OPTIONS = foreign
AM_CPPFLAGS = \
- $(SANDBOX_DEFINES) \
- -DPIC -fPIC -D_REENTRANT \
- -I$(top_srcdir) -Wall
+ $(SANDBOX_DEFINES) \
+ -DPIC -fPIC
-INCLUDES = -I$(srcdir)/include
+INCLUDES = \
+ -I$(top_srcdir) \
+ -I$(srcdir)/include
LOCAL_INCLUDES = $(top_srcdir)/localdecls.h
noinst_LTLIBRARIES = libsbutil.la
diff --git a/src/Makefile.am b/src/Makefile.am
index 0493a4c..2f3123f 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -3,12 +3,12 @@ AUTOMAKE_OPTIONS = foreign
bin_PROGRAMS = sandbox
AM_CPPFLAGS = \
- $(SANDBOX_DEFINES) \
- -DPIC -fPIC -D_REENTRANT \
- -I$(top_srcdir) -Wall
+ $(SANDBOX_DEFINES) \
+ -DPIC -fPIC
INCLUDES = \
- -I$(top_srcdir)/libsbutil \
+ -I$(top_srcdir) \
+ -I$(top_srcdir)/libsbutil \
-I$(top_srcdir)/libsbutil/include
sandbox_CFLAGS = -DOUTSIDE_LIBSANDBOX