summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2012-01-18 08:33:37 +0100
committerKarolin Seeger <kseeger@samba.org>2012-09-28 09:23:07 +0200
commit4ee9a57f4ee14812b636e1e5036bec1b9189dc2e (patch)
tree577fa07c478abf59bc62d993621e851398d28981
parent4c97f0dc4fa4cff95d91056579a226ca75048b5c (diff)
downloadsamba-4ee9a57f4ee14812b636e1e5036bec1b9189dc2e.tar.gz
dynconfig/config.m4: disallow --prefix=/usr and --prefix=/usr/local without --enable-fhs
This matches the waf configure behavior and catches the case where old build scripts try '--with-fhs' instead of '--enable-fhs'. metze (cherry picked from commit ae037670b83557d8591c633896186a3634de30cc) Fix bug #9194 - dynconfig/config.m4: disallow --prefix=/usr and --prefix=/usr/local without --enable-fhs.
-rw-r--r--dynconfig/config.m44
1 files changed, 4 insertions, 0 deletions
diff --git a/dynconfig/config.m4 b/dynconfig/config.m4
index 842a960cd6a..6b5dfdbadde 100644
--- a/dynconfig/config.m4
+++ b/dynconfig/config.m4
@@ -19,6 +19,10 @@ AC_ARG_ENABLE(fhs,
[AS_HELP_STRING([--enable-fhs], [Turn on FHS support (default=no)])])
if test x$enable_fhs != xyes; then
+ if test x"$prefix" = x"/usr" -o x"$prefix" = x"/usr/local"; then
+ AC_MSG_WARN([Don't install directly under /usr or /usr/local without using the FHS option (--enable-fhs)])
+ AC_MSG_ERROR([invalid --prefix=$prefix])
+ fi
MODULESDIR="${libdir}"
INCLUDEDIR="${includedir}"
SETUPDIR="${datadir}/setup"