[csw-devel] SF.net SVN: gar:[13027] csw/mgar/gar/v2/gar.lib.mk
bdwalton at users.sourceforge.net
bdwalton at users.sourceforge.net
Fri Jan 21 02:39:54 CET 2011
Revision: 13027
http://gar.svn.sourceforge.net/gar/?rev=13027&view=rev
Author: bdwalton
Date: 2011-01-21 01:39:53 +0000 (Fri, 21 Jan 2011)
Log Message:
-----------
gar/v2: correct patch handling when NOGITPATCH is set
Modified Paths:
--------------
csw/mgar/gar/v2/gar.lib.mk
Modified: csw/mgar/gar/v2/gar.lib.mk
===================================================================
--- csw/mgar/gar/v2/gar.lib.mk 2011-01-20 11:42:36 UTC (rev 13026)
+++ csw/mgar/gar/v2/gar.lib.mk 2011-01-21 01:39:53 UTC (rev 13027)
@@ -493,37 +493,51 @@
xz-patch-%:
@echo " ==> Applying patch $(DOWNLOADDIR)/$*"
@xz -dc $(DOWNLOADDIR)/$* | $(GARPATCH)
- @( cd $(WORKSRC); git add -A; \
- git commit -am "old xz-style patch: $*"; )
+ @( if [ -z "$(NOGITPATCH)" ]; then \
+ cd $(WORKSRC); git add -A; \
+ git commit -am "old xz-style patch: $*"; \
+ fi )
@$(MAKECOOKIE)
# apply bzipped patches
bz-patch-%:
@echo " ==> Applying patch $(DOWNLOADDIR)/$*"
@bzip2 -dc $(DOWNLOADDIR)/$* | $(GARPATCH)
- @( cd $(WORKSRC); git add -A; \
- git commit -am "old bz-style patch: $*"; )
+ @( if [ -z "$(NOGITPATCH)" ]; then \
+ cd $(WORKSRC); git add -A; \
+ git commit -am "old bz-style patch: $*"; \
+ fi )
@$(MAKECOOKIE)
# apply gzipped patches
gz-patch-%:
@echo " ==> Applying patch $(DOWNLOADDIR)/$*"
@gzip -dc $(DOWNLOADDIR)/$* | $(GARPATCH)
- @( cd $(WORKSRC); git add -A; \
- git commit -am "old gz-style patch: $*"; )
+ @( if [ -z "$(NOGITPATCH)" ]; then \
+ cd $(WORKSRC); git add -A; \
+ git commit -am "old gz-style patch: $*"; \
+ fi )
@$(MAKECOOKIE)
# apply normal patches (git format-patch output or old-style diff -r)
normal-patch-%:
@echo " ==> Applying patch $(DOWNLOADDIR)/$*"
@( if ggrep -q 'diff --git' $(abspath $(DOWNLOADDIR)/$*); then \
- cd $(WORKSRC); git am --ignore-space-change --ignore-whitespace $(abspath $(DOWNLOADDIR)/$*); \
- else \
+ if [ -z "$(NOGITPATCH)" ]; then \
+ cd $(WORKSRC);\
+ git am --ignore-space-change --ignore-whitespace $(abspath $(DOWNLOADDIR)/$*); \
+ else \
+ $(GARPATCH) < $(DOWNLOADDIR)/$*; \
+ fi; \
+ else \
echo Adding old-style patch...; \
$(GARPATCH) < $(DOWNLOADDIR)/$*; \
- cd $(WORKSRC); git add -A; \
- git commit -am "old style patch: $*"; \
- fi )
+ if [ -z "$(NOGITPATCH)" ]; then \
+ cd $(WORKSRC); \
+ git add -A; \
+ git commit -am "old style patch: $*"; \
+ fi; \
+ fi )
@$(MAKECOOKIE)
### PATCH FILE TYPE MAPPINGS ###
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the devel
mailing list