[csw-devel] SF.net SVN: gar:[5028] csw/mgar/gar/v2-relocate
valholla at users.sourceforge.net
valholla at users.sourceforge.net
Sun May 24 19:19:50 CEST 2009
Revision: 5028
http://gar.svn.sourceforge.net/gar/?rev=5028&view=rev
Author: valholla
Date: 2009-05-24 17:19:50 +0000 (Sun, 24 May 2009)
Log Message:
-----------
patch to relocate branch
Modified Paths:
--------------
csw/mgar/gar/v2-relocate/gar.conf.mk
csw/mgar/gar/v2-relocate/gar.mk
csw/mgar/gar/v2-relocate/gar.pkg.mk
Modified: csw/mgar/gar/v2-relocate/gar.conf.mk
===================================================================
--- csw/mgar/gar/v2-relocate/gar.conf.mk 2009-05-24 17:17:52 UTC (rev 5027)
+++ csw/mgar/gar/v2-relocate/gar.conf.mk 2009-05-24 17:19:50 UTC (rev 5028)
@@ -114,6 +114,11 @@
perlcswlib ?= $(perllib)/csw
perlpackroot ?= $(perlcswlib)/auto
+# This Variable is only used if you make your package relocatable
+# using ALLOW_RELOCATE, it will allow you to change your default
+# directory for BASEDIR
+RELOCATE_PREFIX ?= $(prefix)
+
# These variables are used to construct pathes. If you temporarily reset the above
# variables for special install locations (like /opt/csw/bin/bdb44/) the definitions
# here make sure the binaries for the make process are still found.
Modified: csw/mgar/gar/v2-relocate/gar.mk
===================================================================
--- csw/mgar/gar/v2-relocate/gar.mk 2009-05-24 17:17:52 UTC (rev 5027)
+++ csw/mgar/gar/v2-relocate/gar.mk 2009-05-24 17:19:50 UTC (rev 5028)
@@ -607,14 +607,14 @@
# Copy the whole tree verbatim
merge-copy-all: $(PKGROOT) $(INSTALLISADIR)
- $(_DBG_MERGE)(cd $(INSTALLISADIR); pax -r -w -v $(_PAX_ARGS) \
+ $(_DBG_MERGE)(cd $(INSTALLISADIR)$(if $(ALLOW_RELOCATE),$(RELOCATE_PREFIX)); pax -r -w -v $(_PAX_ARGS) \
$(foreach DIR,$(MERGE_DIRS),-s ",^\(\.$(DIR)/\),.$(call mergebase,$(DIR))/,p") \
. $(PKGROOT))
@$(MAKECOOKIE)
# Copy only the merge directories
merge-copy-only: $(PKGROOT)
- $(_DBG_MERGE)(cd $(INSTALLISADIR); pax -r -w -v $(_PAX_ARGS) \
+ $(_DBG_MERGE)(cd $(INSTALLISADIR)$(if $(ALLOW_RELOCATE),$(RELOCATE_PREFIX)); pax -r -w -v $(_PAX_ARGS) \
$(foreach DIR,$(MERGE_DIRS),-s ",^\(\.$(DIR)/\),.$(call mergebase,$(DIR))/,p") -s ",.*,," \
. $(PKGROOT) \
)
@@ -622,7 +622,7 @@
# Copy the whole tree and relocate the directories in $(MERGE_DIRS)
merge-copy-relocate: $(PKGROOT) $(INSTALLISADIR)
- $(_DBG_MERGE)(cd $(INSTALLISADIR); pax -r -w -v $(_PAX_ARGS) \
+ $(_DBG_MERGE)(cd $(INSTALLISADIR)$(if $(ALLOW_RELOCATE),$(RELOCATE_PREFIX)); pax -r -w -v $(_PAX_ARGS) \
$(foreach DIR,$(MERGE_DIRS),-s ",^\(\.$(DIR)/\),.$(call mergebase,$(DIR))/$(ISA)/,p") \
. $(PKGROOT) \
)
@@ -630,7 +630,7 @@
# Copy only the relocated directories
merge-copy-relocated-only: $(PKGROOT) $(INSTALLISADIR)
- $(_DBG_MERGE)(cd $(INSTALLISADIR); pax -r -w -v $(_PAX_ARGS) \
+ $(_DBG_MERGE)(cd $(INSTALLISADIR)$(if $(ALLOW_RELOCATE),$(RELOCATE_PREFIX)); pax -r -w -v $(_PAX_ARGS) \
$(foreach DIR,$(MERGE_DIRS),-s ",^\(\.$(DIR)/\),.$(call mergebase,$(DIR))/$(ISA)/,p") -s ",.*,," \
. $(PKGROOT) \
)
@@ -638,7 +638,7 @@
# Copy
merge-copy-config-only:
- $(_DBG_MERGE)(cd $(INSTALLISADIR); pax -r -w -v $(_PAX_ARGS) \
+ $(_DBG_MERGE)(cd $(INSTALLISADIR)$(if $(ALLOW_RELOCATE),$(RELOCATE_PREFIX)); pax -r -w -v $(_PAX_ARGS) \
-s ",^\(\.$(bindir)/.*-config\)\$$,\1,p" \
-s ",.*,," \
. $(PKGROOT) \
Modified: csw/mgar/gar/v2-relocate/gar.pkg.mk
===================================================================
--- csw/mgar/gar/v2-relocate/gar.pkg.mk 2009-05-24 17:17:52 UTC (rev 5027)
+++ csw/mgar/gar/v2-relocate/gar.pkg.mk 2009-05-24 17:19:50 UTC (rev 5028)
@@ -300,7 +300,7 @@
# Pulled in from pkglib/csw_prototype.gspec
$(PROTOTYPE): $(WORKDIR) merge
- $(_DBG)cswproto -c $(GARDIR)/etc/commondirs-$(GARCH) -r $(PKGROOT) $(PKGROOT)=/ >$@
+ $(_DBG)cswproto -c $(GARDIR)/etc/commondirs-$(GARCH) -r $(PKGROOT) $(PKGROOT)=$(if $(ALLOW_RELOCATE),,'/') >$@
# The pathfilter rules are as follows:
# - include license for current package
@@ -456,6 +456,7 @@
echo "OPENCSW_REPOSITORY=$(call _URL)@$(call _REVISION)"; \
echo "OPENCSW_MODE64=$(call mode64,$*)"; \
) >$@
+ $(if $(ALLOW_RELOCATE),echo "BASEDIR=$(RELOCATE_PREFIX)" >>$@)
# findlicensefile - Find an existing file for a given license name
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