Skip to content

Commit

Permalink
debian packaging update
Browse files Browse the repository at this point in the history
* sync other branches
* avoid testing and installing twice
* manually merge PR#2524
  • Loading branch information
jef-n committed Dec 6, 2015
1 parent b29cbbc commit 3907acd
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 24 deletions.
13 changes: 7 additions & 6 deletions debian/control.in
Expand Up @@ -7,6 +7,7 @@ Build-Depends:
bison,
cmake (>= 2.8),
#sid stretch jessie wheezy saucy trusty utopic vivid wily# debhelper (>= 9),
#sid stretch jessie trusty vivid wily# dh-python,
#precise# debhelper (>= 7),
flex,
grass-dev,
Expand All @@ -17,14 +18,14 @@ Build-Depends:
#saucy# libgdal-dev (>= 1.9.0),
#wheezy# libgdal1-dev,
libgeos-dev (>= 3.0.0),
libgsl0-dev,
libgsl-dev | libgsl0-dev,
libpq-dev,
libproj-dev,
libqt4-dev (>= 4.7.0),
libqt4-opengl-dev,
libqtwebkit-dev,
#stretch jessie wheezy# libqwt-dev,
#precise saucy trusty utopic vivid wily stretch sid# libqwt5-qt4-dev,
#precise saucy trusty utopic vivid wily sid# libqwt5-qt4-dev,
libspatialite-dev,
libsqlite3-dev,
libspatialindex-dev,
Expand All @@ -38,7 +39,7 @@ Build-Depends:
#saucy wheezy# python-dev,
#saucy# libpython2.7-dev,
#sid stretch jessie trusty utopic vivid wily# python-all (>= 2.6.6-3~), python-all-dev (>= 2.6.6-3~),
#sid stretch jessie# pyqt4.qsci-dev,
#sid stretch jessie wily# pyqt4.qsci-dev,
#sid stretch jessie trusty utopic vivid wily# python-pyspatialite,
python-sip (>= 4.5.0),
python-sip-dev (>= 4.5.0),
Expand Down Expand Up @@ -220,7 +221,7 @@ Depends:
#saucy# libgdal-dev (>= 1.9.0),
#wheezy# libgdal1-dev,
libgeos-dev (>= 3.0.0),
libgsl0-dev,
libgsl-dev | libgsl0-dev,
libpq-dev,
libproj-dev,
libqgis-core{QGIS_ABI} (= ${binary:Version}),
Expand Down Expand Up @@ -253,8 +254,8 @@ Depends:
qgis (= ${binary:Version}),
${shlibs:Depends},
${misc:Depends}
#grass7#Breaks: qgis-plugin-grass
#grass7#Replaces: qgis-plugin-grass
#grass7#Breaks: qgis-plugin-grass (<< 1:2.8.4)
#grass7#Replaces: qgis-plugin-grass (<< 1:2.8.4)
Description: GRASS plugin for QGIS
QGIS is a Geographic Information System (GIS) which manages, analyzes and
display databases of geographic information.
Expand Down
4 changes: 2 additions & 2 deletions debian/qgis-provider-grass.lintian-overrides
@@ -1,2 +1,2 @@
qgis-plugin-grass: package-name-doesnt-match-sonames
qgis-plugin-grass: no-symbols-control-file
qgis-provider-grass: package-name-doesnt-match-sonames
qgis-provider-grass: no-symbols-control-file
44 changes: 28 additions & 16 deletions debian/rules
Expand Up @@ -16,9 +16,9 @@ DEB_BUILD_MULTIARCH ?= $(shell dpkg-architecture -qDEB_BUILD_MULTIARCH)
QT_PLUGIN_DIR = usr/lib/$(DEB_BUILD_MULTIARCH)/qt4/plugins

DEB_TEST_TARGET ?= Experimental
BUILDDIR ?= debian/build
QGIS_BUILDDIR ?= debian/build

QGIS_VERSION=$(shell dpkg-parsechangelog | sed -ne 's/^Version: \(.*\)-.*/\1/p')
QGIS_VERSION=$(shell dpkg-parsechangelog | sed -ne 's/^Version: \([0-9]\+:\)\?\([^+-]\+\).*$$/\2/p')

ifeq (,$(DISTRIBUTION))
DISTRIBUTION := $(shell dpkg-parsechangelog --format rfc822 | sed -ne "s/^Distribution: //p")
Expand Down Expand Up @@ -77,7 +77,7 @@ ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
MAKEFLAGS += -j$(NUMJOBS)
endif

ifneq (,$(findstring $(DISTRIBUTION),"wheezy jessie sid precise"))
ifneq (,$(findstring $(DISTRIBUTION),"wheezy precise"))
CMAKE_OPTS += -DWITH_PYSPATIALITE=TRUE
endif

Expand All @@ -103,9 +103,6 @@ endif

ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS)))
CMAKE_OPTS += -DCMAKE_BUILD_TYPE=Debug
ifneq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
CMAKE_OPTS += -DENABLE_COVERAGE=TRUE
endif
endif

ifneq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
Expand Down Expand Up @@ -139,6 +136,7 @@ ifneq (,$(findstring profile,$(DEB_BUILD_OPTIONS)))
LDFLAGS += -pg
endif


# multi distribution support:
# - remove lines with applicable excludes
# - remove prefixes with applicable includes
Expand Down Expand Up @@ -178,8 +176,13 @@ cleantemplates:
$(MAKE) -f debian/rules templateclean
$(MAKE) -f debian/rules debian/control debian/compat

binary binary-arch binary-indep build build-arch build-indep clean install install-arch install-indep:
dh $@ --with python2 --parallel --builddirectory=$(BUILDDIR)
build: ;

binary binary-arch binary-indep build-arch build-indep clean install install-arch install-indep:
dh $@ --with python2 --parallel --builddirectory=$(QGIS_BUILDDIR)

override_dh_auto_build-arch:
dh_auto_build

override_dh_clean: cleantemplates
dh_clean
Expand All @@ -188,27 +191,32 @@ override_dh_clean: cleantemplates
-$(RM) $(CURDIR)/src/core/qgscontexthelp_texts.cpp
-$(RM) $(CURDIR)/src/core/qgsexpression_texts.cpp

-$(RM) -r $(CURDIR)/$(BUILDDIR)/
-$(RM) -r $(CURDIR)/$(QGIS_BUILDDIR)/

override_dh_auto_configure: templates
override_dh_auto_configure-arch: templates
dh_auto_configure -- $(CMAKE_OPTS)

override_dh_auto_test-arch:
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
override_dh_auto_test:
# Code to run the package test suite - and ignore the outcome for now
mkdir -p debian/tmp/locale/
localedef -f UTF-8 -i en_US ./debian/tmp/locale/en_US.UTF-8/
-LOCPATH=$(CURDIR)/debian/tmp/locale/ \
LC_ALL=en_US.UTF-8 \
LD_LIBRARY_PATH=$(CURDIR)/$(BUILDDIR)/output/lib:$(LD_LIBRARY_PATH) \
LD_LIBRARY_PATH=$(CURDIR)/$(QGIS_BUILDDIR)/output/lib:$(LD_LIBRARY_PATH) \
PATH=/usr/sbin:$(PATH) \
$(TESTMAKE) -C $(BUILDDIR) $(DEB_TEST_TARGET)
$(TESTMAKE) -C $(QGIS_BUILDDIR) $(DEB_TEST_TARGET)
else
override_dh_auto_test:
@echo Skipping tests.
endif

override_dh_auto_install:
override_dh_auto_configure-indep: ;
override_dh_auto_test-indep: ;
override_dh_auto_install-indep: ;
override_dh_auto_build-indep: ;
override_dh_install-indep: ;

override_dh_auto_install-arch:
dh_auto_install

# Install menu pixmap
Expand Down Expand Up @@ -252,7 +260,7 @@ override_dh_auto_install:
install -o root -g root -m 755 $(CURDIR)/debian/qgis.sh $(CURDIR)/debian/qgis-provider-grass/usr/bin/qgis
install -o root -g root -m 755 $(CURDIR)/debian/qgis.sh $(CURDIR)/debian/qgis-provider-grass/usr/bin/qbrowser

override_dh_install:
override_dh_install-arch:
# Don't ship srs.db, automatically updated in postinst with crssync
mv $(CURDIR)/debian/tmp/usr/share/qgis/resources/srs.db $(CURDIR)/debian/tmp/usr/share/qgis/resources/srs-template.db

Expand Down Expand Up @@ -298,3 +306,7 @@ override_dh_makeshlibs:

override_dh_shlibdeps:
dh_shlibdeps -l/usr/lib/$(GRASS)/lib

override_dh_strip:
dh_strip --dbg-package=qgis-dbg

0 comments on commit 3907acd

Please sign in to comment.