[PATCH 1/2] configure: store $IFS to $DEFAULT_IFS readonly variable
authorTomi Ollila <tomi.ollila@iki.fi>
Wed, 14 Mar 2012 14:59:59 +0000 (16:59 +0200)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:45:29 +0000 (09:45 -0800)
79/1c92d9fd7b8ebd376f401ce4423a45025e4c3c [new file with mode: 0644]

diff --git a/79/1c92d9fd7b8ebd376f401ce4423a45025e4c3c b/79/1c92d9fd7b8ebd376f401ce4423a45025e4c3c
new file mode 100644 (file)
index 0000000..a10655f
--- /dev/null
@@ -0,0 +1,93 @@
+Return-Path: <too@guru.guru-group.fi>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+       by olra.theworths.org (Postfix) with ESMTP id AD455431FC0\r
+       for <notmuch@notmuchmail.org>; Wed, 14 Mar 2012 08:00:09 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: 0\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none]\r
+       autolearn=disabled\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+       by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+       with ESMTP id Jz5xoAiw5TcN for <notmuch@notmuchmail.org>;\r
+       Wed, 14 Mar 2012 08:00:07 -0700 (PDT)\r
+Received: from guru.guru-group.fi (guru-group.fi [87.108.86.66])\r
+       by olra.theworths.org (Postfix) with ESMTP id 9AF69431FBC\r
+       for <notmuch@notmuchmail.org>; Wed, 14 Mar 2012 08:00:07 -0700 (PDT)\r
+Received: by guru.guru-group.fi (Postfix, from userid 501)\r
+       id 4257068055; Wed, 14 Mar 2012 17:00:06 +0200 (EET)\r
+From: Tomi Ollila <tomi.ollila@iki.fi>\r
+To: notmuch@notmuchmail.org\r
+Subject: [PATCH 1/2] configure: store $IFS to $DEFAULT_IFS readonly variable\r
+Date: Wed, 14 Mar 2012 16:59:59 +0200\r
+Message-Id: <1331737200-16570-1-git-send-email-tomi.ollila@iki.fi>\r
+X-Mailer: git-send-email 1.7.6.1\r
+In-Reply-To: <1331402091-15663-1-git-send-email-tom.prince@ualberta.net>\r
+References: <1331402091-15663-1-git-send-email-tom.prince@ualberta.net>\r
+Cc: Tomi Ollila <tomi.ollila@iki.fi>\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+       <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Wed, 14 Mar 2012 15:00:10 -0000\r
+\r
+In the future, IFS value needs to be changed in a few places\r
+in configure -- and then restored. Store the original value\r
+to $DEFAULT_IFS for easy restoration.\r
+---\r
+ configure |    8 +++++---\r
+ 1 files changed, 5 insertions(+), 3 deletions(-)\r
+\r
+diff --git a/configure b/configure\r
+index ee0ae73..3b2b6b7 100755\r
+--- a/configure\r
++++ b/configure\r
+@@ -1,5 +1,8 @@\r
+ #! /bin/sh\r
\r
++# Store original IFS value so it can be changed (and restored) in many places.\r
++readonly DEFAULT_IFS=$IFS\r
++\r
+ srcdir=$(dirname "$0")\r
\r
+ # For a non-srcdir configure invocation (such as ../configure), create\r
+@@ -379,7 +382,6 @@ elif [ $uname = "Linux" ] ; then\r
+     # IFS=$(printf '\n')\r
+     #\r
+     # because the shell's command substitution deletes any trailing newlines.\r
+-    OLD_IFS=$IFS\r
+     IFS="\r
+ "\r
+     for path in $ldconfig_paths; do\r
+@@ -387,7 +389,7 @@ elif [ $uname = "Linux" ] ; then\r
+           libdir_in_ldconfig=1\r
+       fi\r
+     done\r
+-    IFS=$OLD_IFS\r
++    IFS=$DEFAULT_IFS\r
+     if [ "$libdir_in_ldconfig" = '0' ]; then\r
+       printf "No (will set RPATH)\n"\r
+     else\r
+@@ -536,7 +538,7 @@ done\r
+ printf "\n\t${WARN_CFLAGS}\n"\r
\r
+ rm -f minimal minimal.c\r
+-      \r
++\r
+ cat <<EOF\r
\r
+ All required packages were found. You may now run the following\r
+-- \r
+1.7.8.2\r
+\r