cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From muralire...@apache.org
Subject [3/50] [abbrv] git commit: refs/heads/gslb-wip - debian: Use some more variables in the rules file
Date Mon, 18 Mar 2013 10:14:50 GMT
debian: Use some more variables in the rules file

Makes changes easier and it less hard coded.


Project: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/commit/5b6a4a68
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/tree/5b6a4a68
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/diff/5b6a4a68

Branch: refs/heads/gslb-wip
Commit: 5b6a4a68c41099288eaf956af013f4fdfd39eb07
Parents: 9e02ed1
Author: Wido den Hollander <wido@42on.com>
Authored: Wed Mar 6 19:20:23 2013 +0100
Committer: Wido den Hollander <wido@42on.com>
Committed: Wed Mar 6 19:26:18 2013 +0100

----------------------------------------------------------------------
 debian/rules |  137 +++++++++++++++++++++++++++--------------------------
 1 files changed, 69 insertions(+), 68 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/5b6a4a68/debian/rules
----------------------------------------------------------------------
diff --git a/debian/rules b/debian/rules
index 612a154..f0cb67f 100755
--- a/debian/rules
+++ b/debian/rules
@@ -14,6 +14,7 @@ DEBVERS := $(shell dpkg-parsechangelog | sed -n -e 's/^Version: //p')
 VERSION := $(shell echo '$(DEBVERS)' | sed -e 's/^[[:digit:]]*://' -e 's/[~-].*//')
 PACKAGE = $(shell dh_listpackages|head -n 1|cut -d '-' -f 1)
 SYSCONFDIR = "/etc"
+DESTDIR = "debian/tmp"
 
 # Uncomment this to turn on verbose mode.
 export DH_VERBOSE=1
@@ -50,86 +51,86 @@ install:
 	dh_prep -s
 
 	# Common packages
-	mkdir -p debian/tmp$(SYSCONFDIR)/$(PACKAGE)
-	mkdir -p debian/tmp$(SYSCONFDIR)/init.d
-	mkdir -p debian/tmp/var/cache/$(PACKAGE)
-	mkdir -p debian/tmp/var/log/$(PACKAGE)
-	mkdir -p debian/tmp/var/lib/$(PACKAGE)
-	mkdir -p debian/tmp/usr/bin
-	mkdir -p debian/tmp/usr/share
+	mkdir -p $(DESTDIR)/$(SYSCONFDIR)/$(PACKAGE)
+	mkdir -p $(DESTDIR)/$(SYSCONFDIR)/init.d
+	mkdir -p $(DESTDIR)/var/cache/$(PACKAGE)
+	mkdir -p $(DESTDIR)/var/log/$(PACKAGE)
+	mkdir -p $(DESTDIR)/var/lib/$(PACKAGE)
+	mkdir -p $(DESTDIR)/usr/bin
+	mkdir -p $(DESTDIR)/usr/share
 
 	# cloudstack-agent
-	mkdir debian/tmp$(SYSCONFDIR)/$(PACKAGE)/agent
-	mkdir debian/tmp/var/log/$(PACKAGE)/agent
-	mkdir debian/tmp/usr/share/$(PACKAGE)-agent
-	mkdir debian/tmp/usr/share/$(PACKAGE)-agent/plugins
-	install -D agent/target/cloud-agent-4.2.0-SNAPSHOT.jar debian/tmp/usr/share/$(PACKAGE)-agent/lib/$(PACKAGE)-agent.jar
-	install -D plugins/hypervisors/kvm/target/cloud-plugin-hypervisor-kvm-4.2.0-SNAPSHOT.jar
debian/tmp/usr/share/$(PACKAGE)-agent/lib/
-	install -D plugins/hypervisors/kvm/target/dependencies/* debian/tmp/usr/share/$(PACKAGE)-agent/lib/
-	install -D packaging/debian/init/cloud-agent debian/tmp$(SYSCONFDIR)/init.d/$(PACKAGE)-agent
-	install -D agent/bindir/cloud-setup-agent.in debian/tmp/usr/bin/cloud-setup-agent
-	install -D agent/bindir/cloud-ssh.in debian/tmp/usr/bin/cloud-ssh
-	install -D agent/target/transformed/* debian/tmp$(SYSCONFDIR)/$(PACKAGE)/agent
+	mkdir $(DESTDIR)/$(SYSCONFDIR)/$(PACKAGE)/agent
+	mkdir $(DESTDIR)/var/log/$(PACKAGE)/agent
+	mkdir $(DESTDIR)/usr/share/$(PACKAGE)-agent
+	mkdir $(DESTDIR)/usr/share/$(PACKAGE)-agent/plugins
+	install -D agent/target/cloud-agent-4.2.0-SNAPSHOT.jar $(DESTDIR)/usr/share/$(PACKAGE)-agent/lib/$(PACKAGE)-agent.jar
+	install -D plugins/hypervisors/kvm/target/cloud-plugin-hypervisor-kvm-4.2.0-SNAPSHOT.jar
$(DESTDIR)/usr/share/$(PACKAGE)-agent/lib/
+	install -D plugins/hypervisors/kvm/target/dependencies/* $(DESTDIR)/usr/share/$(PACKAGE)-agent/lib/
+	install -D packaging/debian/init/cloud-agent $(DESTDIR)/$(SYSCONFDIR)/init.d/$(PACKAGE)-agent
+	install -D agent/bindir/cloud-setup-agent.in $(DESTDIR)/usr/bin/cloud-setup-agent
+	install -D agent/bindir/cloud-ssh.in $(DESTDIR)/usr/bin/cloud-ssh
+	install -D agent/target/transformed/* $(DESTDIR)/$(SYSCONFDIR)/$(PACKAGE)/agent
 
 	# cloudstack-management
-	mkdir debian/tmp$(SYSCONFDIR)/$(PACKAGE)/server
-	mkdir debian/tmp$(SYSCONFDIR)/$(PACKAGE)/management
-	mkdir -p debian/tmp/usr/share/$(PACKAGE)-management
-	mkdir -p debian/tmp/usr/share/$(PACKAGE)-management/webapps/client
-	mkdir debian/tmp/usr/share/$(PACKAGE)-management/setup
-	mkdir debian/tmp/var/log/$(PACKAGE)/management
-	mkdir debian/tmp/var/cache/$(PACKAGE)/management
-	mkdir debian/tmp/var/cache/$(PACKAGE)/management/work
-	mkdir debian/tmp/var/cache/$(PACKAGE)/management/temp
-	mkdir debian/tmp/var/log/$(PACKAGE)/ipallocator
-	mkdir debian/tmp/var/lib/$(PACKAGE)/management
-	mkdir debian/tmp/var/lib/$(PACKAGE)/mnt
-	cp -r client/target/utilities/scripts/db/* debian/tmp/usr/share/$(PACKAGE)-management/setup/
-	cp -r client/target/cloud-client-ui-4.2.0-SNAPSHOT/* debian/tmp/usr/share/$(PACKAGE)-management/webapps/client/
-	cp server/target/conf/* debian/tmp$(SYSCONFDIR)/$(PACKAGE)/server/
-	cp client/target/conf/* debian/tmp$(SYSCONFDIR)/$(PACKAGE)/management/
-	ln -s tomcat6-nonssl.conf debian/tmp$(SYSCONFDIR)/$(PACKAGE)/management/tomcat6.conf
-	mkdir -p debian/tmp$(SYSCONFDIR)/$(PACKAGE)/management/Catalina/localhost/client
-	install -D packaging/debian/init/cloud-management debian/tmp$(SYSCONFDIR)/init.d/$(PACKAGE)-management
-	install -D client/bindir/cloud-update-xenserver-licenses.in debian/tmp/usr/bin/cloud-update-xenserver-licenses
-	install -D server/target/cloud-server-4.2.0-SNAPSHOT.jar debian/tmp/usr/share/$(PACKAGE)-management/lib/$(PACKAGE)-server.jar
-	ln -s /usr/share/tomcat6/bin debian/tmp/usr/share/$(PACKAGE)-management/bin
-	ln -s ../../..$(SYSCONFDIR)/$(PACKAGE)/management debian/tmp/usr/share/$(PACKAGE)-management/conf
-	ln -s /usr/share/tomcat6/lib debian/tmp/usr/share/$(PACKAGE)-management/lib
-	ln -s ../../../var/log/$(PACKAGE)/management debian/tmp/usr/share/$(PACKAGE)-management/logs
-	ln -s ../../../var/cache/$(PACKAGE)/management/temp debian/tmp/usr/share/$(PACKAGE)-management/temp
-	ln -s ../../../var/cache/$(PACKAGE)/management/work debian/tmp/usr/share/$(PACKAGE)-management/work
+	mkdir $(DESTDIR)/$(SYSCONFDIR)/$(PACKAGE)/server
+	mkdir $(DESTDIR)/$(SYSCONFDIR)/$(PACKAGE)/management
+	mkdir -p $(DESTDIR)/usr/share/$(PACKAGE)-management
+	mkdir -p $(DESTDIR)/usr/share/$(PACKAGE)-management/webapps/client
+	mkdir $(DESTDIR)/usr/share/$(PACKAGE)-management/setup
+	mkdir $(DESTDIR)/var/log/$(PACKAGE)/management
+	mkdir $(DESTDIR)/var/cache/$(PACKAGE)/management
+	mkdir $(DESTDIR)/var/cache/$(PACKAGE)/management/work
+	mkdir $(DESTDIR)/var/cache/$(PACKAGE)/management/temp
+	mkdir $(DESTDIR)/var/log/$(PACKAGE)/ipallocator
+	mkdir $(DESTDIR)/var/lib/$(PACKAGE)/management
+	mkdir $(DESTDIR)/var/lib/$(PACKAGE)/mnt
+	cp -r client/target/utilities/scripts/db/* $(DESTDIR)/usr/share/$(PACKAGE)-management/setup/
+	cp -r client/target/cloud-client-ui-4.2.0-SNAPSHOT/* $(DESTDIR)/usr/share/$(PACKAGE)-management/webapps/client/
+	cp server/target/conf/* $(DESTDIR)/$(SYSCONFDIR)/$(PACKAGE)/server/
+	cp client/target/conf/* $(DESTDIR)/$(SYSCONFDIR)/$(PACKAGE)/management/
+	ln -s tomcat6-nonssl.conf $(DESTDIR)/$(SYSCONFDIR)/$(PACKAGE)/management/tomcat6.conf
+	mkdir -p $(DESTDIR)/$(SYSCONFDIR)/$(PACKAGE)/management/Catalina/localhost/client
+	install -D packaging/debian/init/cloud-management $(DESTDIR)/$(SYSCONFDIR)/init.d/$(PACKAGE)-management
+	install -D client/bindir/cloud-update-xenserver-licenses.in $(DESTDIR)/usr/bin/cloud-update-xenserver-licenses
+	install -D server/target/cloud-server-4.2.0-SNAPSHOT.jar $(DESTDIR)/usr/share/$(PACKAGE)-management/lib/$(PACKAGE)-server.jar
+	ln -s /usr/share/tomcat6/bin $(DESTDIR)/usr/share/$(PACKAGE)-management/bin
+	ln -s ../../..$(SYSCONFDIR)/$(PACKAGE)/management $(DESTDIR)/usr/share/$(PACKAGE)-management/conf
+	ln -s /usr/share/tomcat6/lib $(DESTDIR)/usr/share/$(PACKAGE)-management/lib
+	ln -s ../../../var/log/$(PACKAGE)/management $(DESTDIR)/usr/share/$(PACKAGE)-management/logs
+	ln -s ../../../var/cache/$(PACKAGE)/management/temp $(DESTDIR)/usr/share/$(PACKAGE)-management/temp
+	ln -s ../../../var/cache/$(PACKAGE)/management/work $(DESTDIR)/usr/share/$(PACKAGE)-management/work
 
 	# cloudstack-common
-	mkdir -p debian/tmp/usr/share/$(PACKAGE)-common
-	mkdir debian/tmp/usr/share/$(PACKAGE)-common/scripts
-	mkdir debian/tmp/usr/share/$(PACKAGE)-common/setup
-	cp -r scripts/installer debian/tmp/usr/share/$(PACKAGE)-common/scripts
-	cp -r scripts/network debian/tmp/usr/share/$(PACKAGE)-common/scripts
-	cp -r scripts/storage debian/tmp/usr/share/$(PACKAGE)-common/scripts
-	cp -r scripts/util debian/tmp/usr/share/$(PACKAGE)-common/scripts
-	cp -r scripts/vm debian/tmp/usr/share/$(PACKAGE)-common/scripts
-	install -D client/target/utilities/bin/cloud-migrate-databases debian/tmp/usr/bin
-	install -D client/target/utilities/bin/cloud-set-guest-password debian/tmp/usr/bin
-	install -D client/target/utilities/bin/cloud-set-guest-sshkey debian/tmp/usr/bin
-	install -D client/target/utilities/bin/cloud-setup-databases debian/tmp/usr/bin
-	install -D client/target/utilities/bin/cloud-setup-management debian/tmp/usr/bin
-	install -D services/console-proxy/server/dist/systemvm.iso debian/tmp/usr/share/$(PACKAGE)-common/vms/systemvm.iso
+	mkdir -p $(DESTDIR)/usr/share/$(PACKAGE)-common
+	mkdir $(DESTDIR)/usr/share/$(PACKAGE)-common/scripts
+	mkdir $(DESTDIR)/usr/share/$(PACKAGE)-common/setup
+	cp -r scripts/installer $(DESTDIR)/usr/share/$(PACKAGE)-common/scripts
+	cp -r scripts/network $(DESTDIR)/usr/share/$(PACKAGE)-common/scripts
+	cp -r scripts/storage $(DESTDIR)/usr/share/$(PACKAGE)-common/scripts
+	cp -r scripts/util $(DESTDIR)/usr/share/$(PACKAGE)-common/scripts
+	cp -r scripts/vm $(DESTDIR)/usr/share/$(PACKAGE)-common/scripts
+	install -D client/target/utilities/bin/cloud-migrate-databases $(DESTDIR)/usr/bin
+	install -D client/target/utilities/bin/cloud-set-guest-password $(DESTDIR)/usr/bin
+	install -D client/target/utilities/bin/cloud-set-guest-sshkey $(DESTDIR)/usr/bin
+	install -D client/target/utilities/bin/cloud-setup-databases $(DESTDIR)/usr/bin
+	install -D client/target/utilities/bin/cloud-setup-management $(DESTDIR)/usr/bin
+	install -D services/console-proxy/server/dist/systemvm.iso $(DESTDIR)/usr/share/$(PACKAGE)-common/vms/systemvm.iso
 
 	# cloudstack-python
-	mkdir -p debian/tmp/usr/lib/python2.7/dist-packages
-	cp -r python/lib/cloud* debian/tmp/usr/lib/python2.7/dist-packages
+	mkdir -p $(DESTDIR)/usr/lib/python2.7/dist-packages
+	cp -r python/lib/cloud* $(DESTDIR)/usr/lib/python2.7/dist-packages
 
 	# cloudstack-usage
-	mkdir debian/tmp$(SYSCONFDIR)/$(PACKAGE)/usage
-	mkdir debian/tmp/var/log/$(PACKAGE)/usage
-	install -D usage/target/cloud-usage-4.2.0-SNAPSHOT.jar debian/tmp/usr/share/$(PACKAGE)-usage/lib/$(PACKAGE)-usage.jar
-	cp usage/target/transformed/* debian/tmp$(SYSCONFDIR)/$(PACKAGE)/usage/
-	ln -s ../management/db.properties debian/tmp$(SYSCONFDIR)/$(PACKAGE)/usage/db.properties
-	install -D packaging/debian/init/cloud-usage debian/tmp$(SYSCONFDIR)/init.d/$(PACKAGE)-usage
+	mkdir $(DESTDIR)/$(SYSCONFDIR)/$(PACKAGE)/usage
+	mkdir $(DESTDIR)/var/log/$(PACKAGE)/usage
+	install -D usage/target/cloud-usage-4.2.0-SNAPSHOT.jar $(DESTDIR)/usr/share/$(PACKAGE)-usage/lib/$(PACKAGE)-usage.jar
+	cp usage/target/transformed/* $(DESTDIR)/$(SYSCONFDIR)/$(PACKAGE)/usage/
+	ln -s ../management/db.properties $(DESTDIR)/$(SYSCONFDIR)/$(PACKAGE)/usage/db.properties
+	install -D packaging/debian/init/cloud-usage $(DESTDIR)/$(SYSCONFDIR)/init.d/$(PACKAGE)-usage
 
 	# cloudstack-awsapi
-	mkdir debian/tmp/var/log/$(PACKAGE)/awsapi
+	mkdir $(DESTDIR)/var/log/$(PACKAGE)/awsapi
 
 	dh_installdirs
 	dh_install


Mime
View raw message