X-Git-Url: https://git.notmuchmail.org/git?p=notmuch;a=blobdiff_plain;f=configure;h=ea8a1ad5d996cecff184d449318c46ea9a01feea;hp=ace465ba4ebfdee60a011ab7775501a01c76805a;hb=c158201ee217740cb1b64858df8c7d39cf7793d0;hpb=3c7d97c3c742fdf1b9a531ae639ce9ed6d4f5166 diff --git a/configure b/configure index ace465ba..ea8a1ad5 100755 --- a/configure +++ b/configure @@ -1,7 +1,21 @@ #! /bin/sh +# Test whether this shell is capable of parameter substring processing. +( option='a/b'; : ${option#*/} ) 2>/dev/null || { + echo " +The shell interpreting '$0' is lacking some required features. + +To work around this problem you may try to execute: + + ksh $0 $* + or + bash $0 $* +" + exit 1 +} + # Store original IFS value so it can be changed (and restored) in many places. -readonly DEFAULT_IFS=$IFS +readonly DEFAULT_IFS="$IFS" srcdir=$(dirname "$0") @@ -114,6 +128,10 @@ Fine tuning of some installation directories is available: --bashcompletiondir=DIR Bash completions files [SYSCONFDIR/bash_completion.d] --zshcompletiondir=DIR Zsh completions files [PREFIX/share/zsh/functions/Completion/Unix] +Some specific library versions can be specified (auto-detected otherwise): + + --with-gmime-version=VERS Specify GMIME version (2.4 or 2.6) + Some features can be disabled (--with-feature=no is equivalent to --without-feature) : @@ -356,6 +374,14 @@ elif [ $uname = "SunOS" ] ; then printf "Solaris.\n" platform=SOLARIS linker_resolves_library_dependencies=0 +elif [ $uname = "FreeBSD" ] ; then + printf "FreeBSD.\n" + platform=FREEBSD + linker_resolves_library_dependencies=0 +elif [ $uname = "OpenBSD" ] ; then + printf "OpenBSD.\n" + platform=OPENBSD + linker_resolves_library_dependencies=0 elif [ $uname = "Linux" ] || [ $uname = "GNU" ] ; then printf "$uname\n" platform="$uname" @@ -427,7 +453,7 @@ case a simple command will install everything you need. For example: On Debian and similar systems: - sudo apt-get install libxapian-dev libgmime-2.4-dev libtalloc-dev + sudo apt-get install libxapian-dev libgmime-2.6-dev libtalloc-dev Or on Fedora and similar systems: @@ -510,7 +536,7 @@ fi WARN_CXXFLAGS="" printf "Checking for available C++ compiler warning flags... " -for flag in -Wall -Wextra -Wwrite-strings -Wswitch-enum; do +for flag in -Wall -Wextra -Wwrite-strings; do if ${CC} $flag -o minimal minimal.c > /dev/null 2>&1 then WARN_CXXFLAGS="${WARN_CXXFLAGS}${WARN_CXXFLAGS:+ }${flag}" @@ -645,7 +671,7 @@ HAVE_GETLINE = ${have_getline} # build its own version) HAVE_STRCASESTR = ${have_strcasestr} -# Supported platforms (so far) are: LINUX, MACOSX, SOLARIS +# Supported platforms (so far) are: LINUX, MACOSX, SOLARIS, FREEBSD, OPENBSD PLATFORM = ${platform} # Whether the linker will automatically resolve the dependency of one