nmh-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Nmh-commits] [SCM] The nmh Mail Handling System branch, master, updated


From: David Levine
Subject: [Nmh-commits] [SCM] The nmh Mail Handling System branch, master, updated. 96bc1e4a303b5e1a43323a1f9186138cb921f0a3
Date: Sat, 24 Dec 2011 15:59:57 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "The nmh Mail Handling System".

The branch, master has been updated
       via  96bc1e4a303b5e1a43323a1f9186138cb921f0a3 (commit)
      from  9942b58b26bffd699b980b1b0a1f977df384a47b (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://git.savannah.gnu.org/cgit/nmh.git/commit/?id=96bc1e4a303b5e1a43323a1f9186138cb921f0a3


commit 96bc1e4a303b5e1a43323a1f9186138cb921f0a3
Author: David Levine <address@hidden>
Date:   Sat Dec 24 09:59:45 2011 -0600

    Added --with-rpmdir configure option so that user can set location of RPM 
build root.

diff --git a/Makefile.in b/Makefile.in
index 38a9c1d..598173f 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -9,6 +9,7 @@ SHELL = /bin/sh
 @SET_MAKE@
 
 srcdir = @srcdir@
+abs_srcdir = @abs_srcdir@
 VPATH  = @srcdir@
 
 # ========== USER CONFIGURATION SECTION ==========
@@ -32,6 +33,9 @@ etcdir      = @sysconfdir@
 # location of man pages
 mandir      = @mandir@
 
+# RPM build root
+rpmdir      = @rpmdir@
+
 # location of incoming mail
 mailspool   = @mailspool@
 
@@ -198,15 +202,15 @@ nmhrelease:
 
 # Create binary and source RPMs.  Assumes that configure had already
 # been run.  Otherwise, there wouldn't be a Makefile.
-# _topdir puts build area in the RPM/ directory below the current one.
-# _tmppath uses the specified local TMP.
-# srcdir is this current, top level nmh directory.
+# _topdir is the specified RPM build root.
+# _tmppath is TMP below _topdir.
+# srcdir is the top level nmh source directory.
 # tarfile and version are as specified in this file.  rpmbuild does
 #   not allow Version to contain any dashes.
 rpm: all nmhdist
-       @rpmbuild --define '_topdir '`pwd`'/RPM' \
+       @rpmbuild --define '_topdir $(rpmdir)' \
           --define '_tmppath %{_topdir}/TMP' \
-          --define 'srcdir '`pwd` \
+          --define 'srcdir $(abs_srcdir)' \
           --define 'tarfile $(tarfile)' \
           --define 'version '`echo $(VERSION) | sed "s/-/_/g"` \
           -ba nmh.spec
diff --git a/configure.in b/configure.in
index e93e173..3bba22c 100644
--- a/configure.in
+++ b/configure.in
@@ -659,6 +659,18 @@ else
   AC_SUBST(NDBM_LIBS)
 fi
 
+dnl ------------------
+dnl Set RPM build root
+dnl ------------------
+dnl nmhrpm is used in the final summary, see below.  The default value is
+dnl reported there as ./RPM, consistent with the reporting of the default
+dnl source code location as ., but its absolute path is used in the Makefile.
+AC_ARG_WITH(rpmdir,
+  AS_HELP_STRING([--with-rpmdir=RPMDIR], [RPM build directory @<:@RPM@:>@]))
+  AS_IF([test x"$with_rpmdir" = x], [rpmdir='$(abs_srcdir)/RPM'; nmhrpm=./RPM],
+          [rpmdir="$with_rpmdir"; eval "nmhrpm=${rpmdir}"])
+AC_SUBST(rpmdir)
+
 
 dnl --------------------
 dnl CHECK FOR CYRUS-SASL
@@ -978,6 +990,7 @@ eval "nmhbin=${bindir}";         eval "nmhbin=${nmhbin}"
 eval "nmhsysconf=${sysconfdir}"; eval "nmhsysconf=${nmhsysconf}"
 eval "nmhlib=${libdir}";         eval "nmhlib=${nmhlib}"
 eval "nmhman=${mandir}";         eval "nmhman=${nmhman}"
+eval "nmhrpm=${nmhrpm}";
 
 pop_kinds=no
 if test x"$enable_pop" = x"yes"; then
@@ -1004,6 +1017,7 @@ binary install path        : ${nmhbin}
 library install path       : ${nmhlib}
 config files install path  : ${nmhsysconf}
 man page install path      : ${nmhman}
+RPM build root             : ${nmhrpm}
 backup prefix              : ${backup_prefix}
 transport system           : ${MTS}
 file locking type          : ${LOCKTYPE}
diff --git a/nmh.spec b/nmh.spec
index 57c6d2f..35de0c8 100644
--- a/nmh.spec
+++ b/nmh.spec
@@ -1,6 +1,5 @@
 # Assumes that rpmbuild was invoked in main nmh directory using "make
-# rpm".  Therefore, configure must already have been run.  "make rpm"
-# uses an RPM directory below the current directory.
+# rpm".  Therefore, configure must already have been run.
 #
 # This file is intended to be zero maintenance, that's why it relies
 # on the Makefile (and specifically on the nmhdist target).  If you
@@ -53,7 +52,7 @@ find $RPM_BUILD_ROOT ! -type d -print | sed 
"s#^$RPM_BUILD_ROOT##" > nmh_files
 
 
 %clean
-rm -rf $RPM_BUILD_ROOT $RPM_SOURCE_DIR/%tarfile nmh_files doc
+rm -rf $RPM_BUILD_ROOT doc $RPM_SOURCE_DIR/%tarfile nmh_files
 
 
 %files -f nmh_files

-----------------------------------------------------------------------

Summary of changes:
 Makefile.in  |   14 +++++++++-----
 configure.in |   14 ++++++++++++++
 nmh.spec     |    5 ++---
 3 files changed, 25 insertions(+), 8 deletions(-)


hooks/post-receive
-- 
The nmh Mail Handling System



reply via email to

[Prev in Thread] Current Thread [Next in Thread]