[hdf5] 03/22: debian/rule: cleanup

Gilles Filippini pini at debian.org
Fri Apr 22 13:48:42 UTC 2016


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

pini pushed a commit to branch master-1.10
in repository hdf5.

commit c14ffd455d42d35786bf9f9cff19a09afc8da2a2
Author: Gilles Filippini <pini at debian.org>
Date:   Sat Apr 16 15:06:26 2016 +0200

    debian/rule: cleanup
---
 debian/rules | 31 +++++++++++++++----------------
 1 file changed, 15 insertions(+), 16 deletions(-)

diff --git a/debian/rules b/debian/rules
index fefc16a..88a4792 100755
--- a/debian/rules
+++ b/debian/rules
@@ -5,7 +5,7 @@
 # (c) 2003 Josselin Mouette
 # (c) 2007-2009 Francesco P. Lovergine.
 # (c) 2010-2013 Sylvestre Ledru
-# (c) 2014 Gilles Filippini
+# (c) 2014-2016 Gilles Filippini
 
 # Uncomment this to turn on verbose mode.
 #export DH_VERBOSE=1
@@ -14,7 +14,7 @@ include /usr/share/dpkg/buildflags.mk
 
 package = libhdf5
 pkgversion ?= $(shell dpkg-parsechangelog | awk '/^Version:/ {print $$2}')
-version ?= $(shell echo $(pkgversion) | sed 's/\([0-9\.]\)\(+docs[0-9]*\)\?-[^-]*$$/\1/')
+libversion ?= $(shell echo $(pkgversion) | sed 's/^\([0-9\.]*\)\(~[^~+]*\)\?\(+docs[0-9]*\)\?-[^-]*$$/\1/')
 
 # Get sonames from config/lt_vers.am
 include config/lt_vers.am
@@ -29,20 +29,20 @@ $(foreach interface,$(INTERFACES),$(eval \
   SONAME$(istr) := $(shell soname=$(SONAME$(istr)); echo $${soname:-$(SONAME)})))
 
 # Informative target
-sonames:
-	@$(foreach interface,$(INTERFACES),echo "SONAME$(istr)=$(SONAME$(istr))" &&) true
+info: VARIABLES := package pkgversion libversion $(foreach interface,$(INTERFACES),SONAME$(istr))
+info:
+	@echo $(VARIABLES)
+	@$(foreach var,$(VARIABLES), echo "$(shell printf "%30s" "$(var)") = $($(var))" &&) true
 
-# Targets used by helper script make-version-scripts
+# Targets used by helper script debian/make-version-scripts
 SONAM%: interface = $(subst SONAME,,$@)
 SONAM%:
 	@echo $(SONAME$(istr))
 
-major_version = $(shell echo $(version) | cut -d. -f1,2)
 serpack = $(package)-$(SONAME)
 sercpppack = $(package)-cpp-$(SONAME_CXX)
 openmpipack = $(package)-openmpi-$(SONAME)
 mpichpack = $(package)-mpich-$(SONAME)
-virtpack = $(package)-$(major_version)
 
 DEB_HOST_GNU_TYPE   ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
 DEB_BUILD_GNU_TYPE  ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
@@ -180,7 +180,7 @@ configure-stamp-debian: debian/control.in
 configure-stamp: configure-stamp-debian
 	dh_testdir
 	-mkdir debian/build
-# configure serial version
+# configure serial flavor
 	cd debian/build && CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" FFLAGS="$(FFLAGS)" CC=/usr/bin/cc CXX=/usr/bin/c++ FC=gfortran \
 		H5_LDFLAGS="-Wl,--version-script,\$$(top_srcdir)/debian/map_serial.ver" \
 		../../configure $(CONFIGURE_FLAGS) $(SERIAL_FLAGS) || { cat config.log; exit 1; }
@@ -189,7 +189,7 @@ configure-stamp: configure-stamp-debian
 configure-stamp-openmpi: configure-stamp-debian
 	dh_testdir
 	-mkdir debian/build-openmpi
-# configure version with openmpi
+# configure openmpi flavor
 	cd debian/build-openmpi && CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" FFLAGS="$(FFLAGS)" \
 		H5_LDFLAGS="-Wl,--version-script,\$$(top_srcdir)/debian/map_mpi.ver" \
 		CC=mpicc.openmpi FC=mpif90.openmpi F9X=mpif90.openmpi RUNPARALLEL=/usr/bin/mpirun.openmpi \
@@ -202,7 +202,7 @@ configure-stamp-openmpi: configure-stamp-debian
 configure-stamp-mpich: configure-stamp-debian
 	dh_testdir
 	-mkdir debian/build-mpich
-# configure version with mpich
+# configure mpich flavor
 	cd debian/build-mpich && CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" FFLAGS="$(FFLAGS)" \
 		H5_LDFLAGS="-Wl,--version-script,\$$(top_srcdir)/debian/map_mpi.ver" \
 		CC=mpicc.mpich \
@@ -248,7 +248,7 @@ build-stamp-doc: configure-stamp
 	touch $@
 
 #
-# Be sure to not have a previous version installed before running
+# Be sure to not have a previous release installed before running
 # the test suite
 #
 test: build-stamp
@@ -264,7 +264,6 @@ clean:
 	  -e "s/@SONAME_CXX@/$(SONAME_CXX)/g" \
 	  -e "s/@OMPIARCHS@/$(filter-out !%,$(OMPIARCHS))/" \
 	  -e "s/@MPICHARCHS@/$(filter-out !%,$(MPICHARCHS))/" \
-	  -e "s/@MAJOR_VERSION@/$(major_version)/" \
 	  -e "s/@NODOCARCHS@/$(NODOCARCHS)/g" \
 	  > debian/control
 	dh_autoreconf_clean
@@ -365,13 +364,13 @@ endif
 	dh_compress $(ARCH_FLAG)
 	dh_fixperms $(ARCH_FLAG)
 ifeq ($(build_openmpi),yes)
-	dh_makeshlibs -p$(openmpipack) -V $(openmpipack) -- -v$(version)
+	dh_makeshlibs -p$(openmpipack) -V $(openmpipack) -- -v$(libversion)
 endif
 ifeq ($(build_mpich),yes)
-	dh_makeshlibs -p$(mpichpack) -V $(mpichpack) -- -v$(version)
+	dh_makeshlibs -p$(mpichpack) -V $(mpichpack) -- -v$(libversion)
 endif
-	dh_makeshlibs -p$(serpack) -V $(serpack) -- -v$(version)
-	dh_makeshlibs -p$(sercpppack) -V $(sercpppack) -- -v$(version)
+	dh_makeshlibs -p$(serpack) -V $(serpack) -- -v$(libversion)
+	dh_makeshlibs -p$(sercpppack) -V $(sercpppack) -- -v$(libversion)
 	dh_installdeb $(ARCH_FLAG)
 	dh_shlibdeps -p$(serpack) -L$(serpack) -lusr/lib/$(DEB_HOST_MULTIARCH)
 	dh_shlibdeps -p$(sercpppack) -L$(serpack) -lusr/lib/$(DEB_HOST_MULTIARCH)

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-grass/hdf5.git



More information about the Pkg-grass-devel mailing list