unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
* [PATCH 1/3] fix configure script to handle --prefix= and properly create Makefile.config
@ 2009-11-28 23:57 Jameson Graef Rollins
  2009-11-28 23:57 ` [PATCH 2/3] add checking for zlib development libraries to configure script Jameson Graef Rollins
  2009-12-05  0:12 ` [PATCH 1/3] fix configure script to handle --prefix= and properly create Makefile.config Carl Worth
  0 siblings, 2 replies; 12+ messages in thread
From: Jameson Graef Rollins @ 2009-11-28 23:57 UTC (permalink / raw)
  To: notmuch

This also removes the Makefile.config from the repository, since it
shouldn't be kept in the repository and should be created by the
configure script.
---
 Makefile.config |    3 ---
 configure       |   12 +++++++++++-
 2 files changed, 11 insertions(+), 4 deletions(-)
 delete mode 100644 Makefile.config

diff --git a/Makefile.config b/Makefile.config
deleted file mode 100644
index ddc7436..0000000
--- a/Makefile.config
+++ /dev/null
@@ -1,3 +0,0 @@
-prefix = /usr/local
-bash_completion_dir = /etc/bash_completion.d
-CFLAGS += -DHAVE_VALGRIND
diff --git a/configure b/configure
index e55f067..ab28fa3 100755
--- a/configure
+++ b/configure
@@ -1,5 +1,15 @@
 #! /bin/sh
 
+# defaults
+PREFIX=/usr/local
+
+# option parsing
+for option; do
+    if [ "${option%=*}" = '--prefix' ] ; then
+	PREFIX="${option#*=}"
+    fi
+done
+
 cat <<EOF
 Welcome to Notmuch, a system for indexing, searching and tagging your email.
 
@@ -130,7 +140,7 @@ EOF
 
 # construct the Makefile.config
 cat > Makefile.config <<EOF
-prefix = /usr/local
+prefix = $PREFIX
 bash_completion_dir = /etc/bash_completion.d
 CFLAGS += ${have_valgrind}
 EOF
-- 
1.6.5

^ permalink raw reply related	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2009-12-05 23:05 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-11-28 23:57 [PATCH 1/3] fix configure script to handle --prefix= and properly create Makefile.config Jameson Graef Rollins
2009-11-28 23:57 ` [PATCH 2/3] add checking for zlib development libraries to configure script Jameson Graef Rollins
2009-11-28 23:57   ` [PATCH 3/3] fix Makefile.local to install bash completion definitions as not executable Jameson Graef Rollins
2009-12-05  0:16     ` Carl Worth
2009-12-05  0:21       ` Jameson Graef Rollins
2009-11-29 10:46   ` [PATCH 2/3] add checking for zlib development libraries to configure script Mikhail Gusarov
2009-11-29 12:50     ` david
2009-12-05  0:12 ` [PATCH 1/3] fix configure script to handle --prefix= and properly create Makefile.config Carl Worth
2009-12-05  0:20   ` Jameson Graef Rollins
2009-12-05  0:56     ` Carl Worth
2009-12-05  8:59       ` Ingmar Vanhassel
2009-12-05 23:05         ` Carl Worth

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).