The following commit has been merged in the master branch:
commit a530908631a3e6c99210b0779b5d94ffc36e284f
Author: Bas Couwenberg <sebas...@xs4all.nl>
Date:   Fri Jan 10 17:08:59 2014 +0100

    Use minimal dh rules with dh-autoreconf.

diff --git a/debian/changelog b/debian/changelog
index ddad24e..45162a7 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -7,6 +7,8 @@ spatialindex (1.8.1-1) UNRELEASED; urgency=low
   * Use canonical URLs in Vcs-* fields.
   * Change priority from extra to optional.
   * Bump debhelper compatibility to 9.
+  * Use minimal dh rules with dh-autoreconf.
+    (closes: #734827)
 
  -- Bas Couwenberg <sebas...@xs4all.nl>  Fri, 10 Jan 2014 16:38:53 +0100
 
diff --git a/debian/control b/debian/control
index b053a2e..1813a47 100644
--- a/debian/control
+++ b/debian/control
@@ -5,7 +5,8 @@ Uploaders: Francesco Paolo Lovergine <fran...@debian.org>,
 Section: science
 Priority: optional
 Build-Depends: debhelper (>= 9),
-               autotools-dev
+               autotools-dev,
+               dh-autoreconf
 Standards-Version: 3.9.2
 Vcs-Browser: http://anonscm.debian.org/gitweb/?p=pkg-grass/libspatialindex.git
 Vcs-Git: git://anonscm.debian.org/pkg-grass/libspatialindex.git
diff --git a/debian/rules b/debian/rules
index b46616b..b0c3f8d 100755
--- a/debian/rules
+++ b/debian/rules
@@ -1,96 +1,25 @@
 #!/usr/bin/make -f
 # -*- makefile -*-
-# Sample debian/rules that uses debhelper.
-# This file was originally written by Joey Hess and Craig Small.
-# As a special exception, when this file is copied by dh-make into a
-# dh-make output file, you may use that output file without restriction.
-# This special exception was added by Craig Small in version 0.37 of dh-make.
 
 # Uncomment this to turn on verbose mode.
 #export DH_VERBOSE=1
 
+# This has to be exported to make some magic below work.
+export DH_OPTIONS
 
-# These are used for cross-compiling and for saving the configure script
-# from having to guess our platform (since we know it already)
-DEB_HOST_GNU_TYPE   ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
-DEB_BUILD_GNU_TYPE  ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
-ifneq ($(DEB_HOST_GNU_TYPE),$(DEB_BUILD_GNU_TYPE))
-CROSS= --build $(DEB_BUILD_GNU_TYPE) --host $(DEB_HOST_GNU_TYPE)
-else
-CROSS= --build $(DEB_BUILD_GNU_TYPE)
-endif
+# Enable hardening build flags
+export DEB_BUILD_MAINT_OPTIONS=hardening=+all
 
-config.status: configure
-       dh_testdir
-       # Add here commands to configure the package.
-ifneq "$(wildcard /usr/share/misc/config.sub)" ""
-       cp -f config.sub config.sub.orig
-       cp -f /usr/share/misc/config.sub config.sub
-endif
-ifneq "$(wildcard /usr/share/misc/config.guess)" ""
-       cp -f config.guess config.guess.orig
-       cp -f /usr/share/misc/config.guess config.guess
-endif
-       ./configure $(CROSS) --prefix=/usr --mandir=\$${prefix}/share/man 
--infodir=\$${prefix}/share/info \
-               CFLAGS="$(CFLAGS)" LDFLAGS="-Wl,-z,defs" \
-               CC=g++ # a dirty hack to force using of g++ at libtool linking 
time
+DEB_HOST_MULTIARCH?=$(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
 
-build: build-stamp
-build-stamp:  config.status
-       dh_testdir
-       
-       # Add here commands to compile the package.
-       $(MAKE) 
-       
-       touch $@
+SPATIALINDEX_VERSION = $(shell dpkg-parsechangelog | sed -ne 's/^Version: 
\(.*\)-.*/\1/p' | sed -e 's/^\(.*\)~.*/\1/' | sed -e 's/dev.*/.0/')
 
-clean: 
-       dh_testdir
-       dh_testroot
-       rm -f build-stamp 
-       
-       # Add here commands to clean up after the build process.
-       [ ! -f Makefile ] || $(MAKE) distclean
-       [ ! -f config.sub.orig ] || mv -f config.sub.orig config.sub
-       [ ! -f config.guess.orig ] || mv -f config.guess.orig config.guess
-       rm -rf *.log autom4ate.cache
-       rm -rf debian/tmp
-       
-       dh_clean 
+%:
+       dh $@ --with autoreconf
 
-install: build
-       dh_testdir
-       dh_testroot
-       dh_prep  
-       dh_installdirs
-       
-       # Add here commands to install the package into debian/tmp
-       $(MAKE) DESTDIR=$(CURDIR)/debian/tmp install
+override_dh_install:
+       dh_install --autodest --list-missing
 
+override_dh_makeshlibs:
+       dh_makeshlibs -- -c0 -v$(SPATIALINDEX_VERSION)
 
-# Build architecture-independent files here.
-binary-indep: install
-# We have nothing to do by default.
-
-# Build architecture-dependent files here.
-binary-arch: install
-       dh_testdir
-       dh_testroot
-       dh_installchangelogs ChangeLog
-       dh_installdocs
-       dh_installexamples
-       dh_install --list-missing
-       dh_installman
-       dh_link
-       dh_strip
-       dh_compress
-       dh_fixperms
-       dh_makeshlibs
-       dh_installdeb
-       dh_shlibdeps
-       dh_gencontrol
-       dh_md5sums
-       dh_builddeb
-
-binary: binary-indep binary-arch
-.PHONY: build clean binary-indep binary-arch binary install 

-- 
A general framework for developing spatial indices

_______________________________________________
Pkg-grass-devel mailing list
Pkg-grass-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-grass-devel

Reply via email to