Permalink
Browse files

improve rpm building

  • Loading branch information...
1 parent c73372e commit 14adf2261ba6f221d7d3c7212ab7b94b613d72c9 dancy committed Mar 24, 2006
Showing with 15 additions and 5 deletions.
  1. +3 −0 .cvsignore
  2. +12 −5 Makefile
View
3 .cvsignore
@@ -8,3 +8,6 @@ sync-ext
maild-greylist.cl
maild.spec
maild-suse.spec
+BUILD
+RPMS
+SRPMS
View
17 Makefile
@@ -1,4 +1,4 @@
-# $Id: Makefile,v 1.34 2006/03/02 00:54:42 dancy Exp $
+# $Id: Makefile,v 1.35 2006/03/24 22:10:34 dancy Exp $
preferred_lisp=/fi/cl/8.0/bin/mlisp
alt_lisp0=/usr/local/acl80/mlisp
@@ -124,11 +124,18 @@ src-tarball: FORCE
%.spec: %.spec.in
sed -e "s/__VERSION__/$(version)/" < $< > $@
-%-rpm: maild-%.spec src-tarball
- rpmbuild -ba $<
+rpm-setup: FORCE
+ mkdir -p BUILD RPMS/i386 SRPMS
-redhat-rpm: maild.spec src-tarball
- rpmbuild -ba maild.spec
+%-rpm: maild-%.spec src-tarball rpm-setup
+ rpmbuild --define "_sourcedir $(CURDIR)" \
+ --define "_topdir $(CURDIR)" \
+ -ba $<
+
+redhat-rpm: maild.spec src-tarball rpm-setup
+ rpmbuild --define "_sourcedir $(CURDIR)" \
+ --define "_topdir $(CURDIR)" \
+ -ba maild.spec
ifeq ($(VENDOR),suse)
rpm: suse-rpm

0 comments on commit 14adf22

Please sign in to comment.