summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSol Jerome <sol.jerome@gmail.com>2010-11-15 19:42:04 -0600
committerSol Jerome <sol.jerome@gmail.com>2010-11-15 19:42:04 -0600
commit3cc5a7e114a5e38b22776993271a8f0a2f54a8e8 (patch)
treed512bcfddafd300b41ecdad2c2873d736598482d
parenta58895db0f037bf3a28e33e950a3cfc3d22f45ff (diff)
downloadbcfg2-3cc5a7e114a5e38b22776993271a8f0a2f54a8e8.tar.gz
bcfg2-3cc5a7e114a5e38b22776993271a8f0a2f54a8e8.tar.bz2
bcfg2-3cc5a7e114a5e38b22776993271a8f0a2f54a8e8.zip
redhat: Fix Makefile so that building from git works
Signed-off-by: Sol Jerome <sol.jerome@gmail.com>
-rw-r--r--redhat/Makefile19
1 files changed, 8 insertions, 11 deletions
diff --git a/redhat/Makefile b/redhat/Makefile
index bf7c69591..7533b98da 100644
--- a/redhat/Makefile
+++ b/redhat/Makefile
@@ -11,15 +11,15 @@
.PHONY: cvs-export git-export svn-export test-export
.PHONY: cvs-clean git-clean svn-clean test-clean
-SCM_TYPE := svn
+SCM_TYPE := git
SCM_PATH := ../
#CVSROOT := $(shell cat 2>/dev/null src/CVS/Root)
-SVN_PATH := $(shell svn info ${SCM_PATH} 2>/dev/null | awk '/^URL:/{print $$2}')
-SVN_REV := $(shell svn info ${SVN_PATH} 2>/dev/null | awk '/^Last Changed Rev:/{print $$4}')
+#SVN_PATH := $(shell svn info ${SCM_PATH} 2>/dev/null | awk '/^URL:/{print $$2}')
+#SVN_REV := $(shell svn info ${SVN_PATH} 2>/dev/null | awk '/^Last Changed Rev:/{print $$4}')
PACKAGE := $(shell cat PACKAGE)
VERSION := $(shell cat VERSION)
-RELEASE := $(shell cat RELEASE)r${SVN_REV}
+RELEASE := $(shell cat RELEASE)
BASE_VER := ${VERSION}-${RELEASE}
CURRENT_PACKAGE := $(PACKAGE)-$(BASE_VER)
TARBALL := $(CURRENT_PACKAGE).tar
@@ -80,8 +80,8 @@ buildtargz: buildtarball
# This target copies files that are not in svn into the build tree
prepbuildtarball: $(SCM_TYPE)-export
- @cp ${PACKAGE}.spec ./build/${CURRENT_PACKAGE}/redhat && \
- cp -R scripts ./build/${CURRENT_PACKAGE}/redhat
+ @cp ${PACKAGE}.spec ./build/${CURRENT_PACKAGE}/redhat/ && \
+ cp -R scripts ./build/${CURRENT_PACKAGE}/redhat/
specfile: $(PACKAGE).spec
@@ -113,11 +113,8 @@ test-export: builddir
--file -
git-export: builddir prepclean
- @git-tar-tree HEAD $(PACKAGE)-$(VERSION) \
- | tar \
- --extract \
- --directory ./build/ \
- --file -
+ @cd ../ && git archive --format=tar --prefix=$(CURRENT_PACKAGE)/ HEAD \
+ | (cd redhat/build && tar xf -)
git-clean:
@: