From: Tomi Ollila <tomi.ollila@iki.fi>
To: notmuch@notmuchmail.org
Cc: Tomi Ollila <tomi.ollila@iki.fi>
Subject: [PATCH 2/2] Allow selecting which version of gmime is used to build notmuch.
Date: Wed, 14 Mar 2012 17:00:00 +0200 [thread overview]
Message-ID: <1331737200-16570-2-git-send-email-tomi.ollila@iki.fi> (raw)
In-Reply-To: <1331737200-16570-1-git-send-email-tomi.ollila@iki.fi>
This allows for testing against both versions of gmime on a single
machine, without having to mess with pkg-config paths.
This is rework of Tom Prince's patch submitted in
id:"1331402091-15663-1-git-send-email-tom.prince@ualberta.net"
---
configure | 15 ++++++++++++++-
1 files changed, 14 insertions(+), 1 deletions(-)
diff --git a/configure b/configure
index 3b2b6b7..1fb6cb7 100755
--- a/configure
+++ b/configure
@@ -48,6 +48,11 @@ WITH_EMACS=1
WITH_BASH=1
WITH_ZSH=1
+GMIME_24_VERSION='gmime-2.4'
+GMIME_26_VERSION='gmime-2.6 >= 2.6.7'
+
+WITH_GMIME_VERSIONS="$GMIME_26_VERSION;$GMIME_24_VERSION"
+
usage ()
{
cat <<EOF
@@ -173,6 +178,12 @@ for option; do
fi
elif [ "${option}" = '--without-zsh-completion' ] ; then
WITH_ZSH=0
+ elif [ "${option%%=*}" = '--with-gmime-version' ] ; then
+ if [ "${option#*=}" = '2.4' ]; then
+ WITH_GMIME_VERSIONS=$GMIME_24_VERSION
+ elif [ "${option#*=}" = '2.6' ]; then
+ WITH_GMIME_VERSIONS=$GMIME_26_VERSION
+ fi
elif [ "${option%%=*}" = '--build' ] ; then
build_option="${option#*=}"
case ${build_option} in
@@ -280,7 +291,8 @@ fi
# crypto bug. We need 2.6.7 for permissive "From " header handling.
printf "Checking for GMime development files... "
have_gmime=0
-for gmimepc in 'gmime-2.6 >= 2.6.7' gmime-2.4; do
+IFS=';'
+for gmimepc in $WITH_GMIME_VERSIONS; do
if pkg-config --exists $gmimepc; then
printf "Yes ($gmimepc).\n"
have_gmime=1
@@ -289,6 +301,7 @@ for gmimepc in 'gmime-2.6 >= 2.6.7' gmime-2.4; do
break
fi
done
+IFS=$DEFAULT_IFS
if [ "$have_gmime" = "0" ]; then
printf "No.\n"
errors=$((errors + 1))
--
1.7.8.2
next prev parent reply other threads:[~2012-03-14 15:00 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-03-08 16:45 [PATCH] Fix configure script to properly detect gmime-2.6 if available Jameson Graef Rollins
2012-03-10 17:54 ` [PATCH] Allow selecting which version of gmime is used to build notmuch Tom Prince
2012-03-14 14:59 ` [PATCH 1/2] configure: store $IFS to $DEFAULT_IFS readonly variable Tomi Ollila
2012-03-14 15:00 ` Tomi Ollila [this message]
2012-03-18 13:31 ` David Bremner
2012-03-20 11:19 ` David Bremner
2012-03-11 1:48 ` [PATCH] Fix configure script to properly detect gmime-2.6 if available David Bremner
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://notmuchmail.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1331737200-16570-2-git-send-email-tomi.ollila@iki.fi \
--to=tomi.ollila@iki.fi \
--cc=notmuch@notmuchmail.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://yhetil.org/notmuch.git/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).