[libcatalyst-modules-perl] 01/01: unpack/patch/build/unpatch seem to work

Damyan Ivanov dmn at moszumanska.debian.org
Wed Apr 30 08:42:10 UTC 2014


This is an automated email from the git hooks/post-receive script.

dmn pushed a commit to branch dam-bundle-2.0
in repository libcatalyst-modules-perl.

commit b206f93d9541c92cbf2835b266df20eff9a427b6
Author: Damyan Ivanov <dmn at debian.org>
Date:   Wed Apr 30 08:41:55 2014 +0000

    unpack/patch/build/unpatch seem to work
    
    well, build fails because of stripped out inc/* from the bundled sources
---
 debian/make-module.sh | 59 ++++++++++++++++++---------------------------------
 debian/rules          | 15 +++++++------
 2 files changed, 29 insertions(+), 45 deletions(-)

diff --git a/debian/make-module.sh b/debian/make-module.sh
index 164ee60..c0f80e6 100755
--- a/debian/make-module.sh
+++ b/debian/make-module.sh
@@ -15,22 +15,17 @@ echo "==========================================================================
 
 #--- unpacking tar.gz in proper folders
 if [ "$1" = "unpack" ]; then
-	test -d build-area || mkdir build-area
-	
-	cd tarballs
-	for dir in *
-	do
-		if [ -d $dir ]; then
-			cd $dir
-			for file in *.tar.gz
-			do
-				test -d ../../build-area/$dir || mkdir ../../build-area/$dir
-				tar -C ../../build-area/$dir -xzf $file
-			done
-			cd ..
-		fi
+	if [ -d build-area ]; then rm -rf build-area; fi
+	mkdir build-area
+
+	cd bundle
+	for m in `find . -type l`; do
+		name=$(basename $m | sed 's,-[^-]*$,,')
+		order=$(dirname $m)
+
+		mkdir -p ../build-area/$order
+		cp -a ../sources/$name ../build-area/$order/
 	done
-	cd ..
 fi
 
 if [ "$1" = patch -o "$1" = unpatch ]; then
@@ -46,11 +41,10 @@ if [ "$1" = patch -o "$1" = unpatch ]; then
 		cd $dir
 		for module in *
 		do
-			name=$(echo $module | sed 's,-[^-]*$,,')
-			[ -d $ROOT/debian/patches/$name ] || continue
-			echo "Applying patches for $name:"
+			[ -d $ROOT/debian/patches/$module ] || continue
+			echo "Applying patches for $module:"
 			cd $module
-			[ -h patches ] || ln -s ../../../debian/patches/$name patches
+			[ -h patches ] || ln -s $ROOT/debian/patches/$module patches
 			QUILT_PATCHES=patches quilt --quiltrc /dev/null $action -a || test $? = 2
 			cd ..
 		done
@@ -60,25 +54,14 @@ fi
 
 if [ "$1" = "build" ]; then
 	
-	cd build-area
-	for dir in *
+    for module in $(find build-area -type d -mindepth 2 -maxdepth 2 | sort)
 	do
-		if [ -d $dir ]; then
-			cd $dir
-			for module in *
-			do
-				cd ../..
-				set -e
-				d=build-area/$dir/$module
-				dh_auto_configure -D $d
-				dh_auto_build -D $d
-				dh_auto_test -D $d
-				dh_auto_install -D $d
-				set +e
-				cd build-area/$dir
-			done
-			cd ..
-		fi
+		set -e -x
+		d=$module
+		dh_auto_configure -D $d
+		dh_auto_build -D $d
+		dh_auto_test -D $d
+		dh_auto_install -D $d
+		set +e +x
 	done
-	cd ..
 fi
diff --git a/debian/rules b/debian/rules
index 232137a..fedcab9 100755
--- a/debian/rules
+++ b/debian/rules
@@ -7,20 +7,21 @@ PERL5LIB= $(TMP)/usr/share/perl5
 %:
 	dh $@ --with quilt
 
+unpack: unpack-stamp
+unpack-stamp:
+	debian/make-module.sh unpack
+	touch $@
+
 override_dh_clean:
 	dh_clean
 	rm -rf build-area
+	rm -f unpack-stamp
 
-override_dh_auto_configure: configure-stamp
-configure-stamp:
-	DESTDIR=$(TMP) debian/make-module.sh unpack
-	touch configure-stamp
-
-override_dh_auto_install: patch-stamp
+override_dh_auto_build: patch-stamp
 	DESTDIR=$(TMP) TEST_POD=0 debian/make-module.sh build
 
 patch: patch-stamp
-patch-stamp: configure-stamp
+patch-stamp: unpack-stamp
 	DESTDIR=$(TMP) debian/make-module.sh patch
 	touch patch-stamp
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libcatalyst-modules-perl.git



More information about the Pkg-perl-cvs-commits mailing list