[osmpbf] 09/11: Various fixes for easier Debian packaging
Bas Couwenberg
sebastic at xs4all.nl
Sun Mar 16 10:08:45 UTC 2014
This is an automated email from the git hooks/post-receive script.
sebastic-guest pushed a commit to tag v1.3.2
in repository osmpbf.
commit 237240107f3460818f85001945a617bacd931fc2
Author: Jochen Topf <jochen at topf.org>
Date: Wed Mar 12 14:09:13 2014 +0100
Various fixes for easier Debian packaging
---
debian/control | 31 ++++++++++++++++---------------
debian/{docs => libosmpbf-dev.docs} | 0
debian/rules | 27 ++++++++++++++++++---------
debian/watch | 2 ++
src/Makefile | 10 ++++++----
tools/Makefile | 8 +++++---
6 files changed, 47 insertions(+), 31 deletions(-)
diff --git a/debian/control b/debian/control
index 0505b01..9baa678 100644
--- a/debian/control
+++ b/debian/control
@@ -1,19 +1,18 @@
Source: osmpbf
+Maintainer: Jochen Topf <jochen at topf.org>
Section: java
-Priority: extra
-Maintainer: Debian GIS Team <pkg-grass-devel at lists.alioth.debian.org>
-Build-Depends:
- debhelper (>= 9~)
- , protobuf-compiler
- , libprotobuf-java
- , ant
- , default-jdk
- , libprotobuf-dev
- , maven-repo-helper
+Priority: optional
+Build-Depends: debhelper (>= 9~),
+ protobuf-compiler,
+ libprotobuf-java,
+ ant,
+ default-jdk,
+ libprotobuf-dev,
+ maven-repo-helper
Standards-Version: 3.9.5
-Homepage: http://github.com/scrosby/OSM-binary
-Vcs-Git: git://anonscm.debian.org/pkg-grass/osmpbf.git
Vcs-Browser: http://anonscm.debian.org/gitweb/?p=pkg-grass/osmpbf.git;a=summary
+Vcs-Git: git://anonscm.debian.org/pkg-grass/osmpbf.git
+Homepage: http://github.com/scrosby/OSM-binary
Package: libosmpbf-java
Architecture: all
@@ -26,8 +25,8 @@ Description: Java access library for OpenStreetMap PBF file format
This package provides a Java library.
Package: libosmpbf-dev
-Section: libdevel
Architecture: any
+Section: libdevel
Depends: ${misc:Depends}
Description: C headers for OpenStreetMap PBF file format
Osmpbf is a Java/C library to read and write OpenStreetMap PBF files.
@@ -38,9 +37,10 @@ Description: C headers for OpenStreetMap PBF file format
applications.
Package: osmpbf-bin
-Section: utils
Architecture: any
-Depends: ${shlibs:Depends}, ${misc:Depends}
+Section: utils
+Depends: ${shlibs:Depends},
+ ${misc:Depends}
Description: OpenStreetMap PBF file format library - tools
Osmpbf is a Java/C library to read and write OpenStreetMap PBF files.
PBF (Protocol buffer Binary Format) is a binary file format for OpenStreetMap
@@ -48,3 +48,4 @@ Description: OpenStreetMap PBF file format library - tools
.
This package provides various tools to deal with OpenStreetMap PBF file
format.
+
diff --git a/debian/docs b/debian/libosmpbf-dev.docs
similarity index 100%
rename from debian/docs
rename to debian/libosmpbf-dev.docs
diff --git a/debian/rules b/debian/rules
index 5a09543..5492959 100755
--- a/debian/rules
+++ b/debian/rules
@@ -4,27 +4,36 @@
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
+CXXFLAGS += $(CPPFLAGS)
+
%:
- dh $@
+ dh $@ --buildsystem makefile --parallel
override_dh_auto_clean:
- $(MAKE) -C src clean
- $(MAKE) -C tools clean
+ dh_auto_clean --buildsystem ant
+ dh_auto_clean -Dsrc
+ dh_auto_clean -Dtools
mh_clean
+override_dh_auto_configure:
+ dh_auto_configure --buildsystem ant
+ dh_auto_configure -Dsrc
+ dh_auto_configure -Dtools
+
override_dh_auto_build:
- ant
- $(MAKE) -C src
- $(MAKE) -C tools
+ dh_auto_build --buildsystem ant
+ dh_auto_build -Dsrc
+ dh_auto_build -Dtools
override_dh_auto_install:
- $(MAKE) -C src DESTDIR=$(CURDIR)/debian/libosmpbf-dev PREFIX=/usr install
- $(MAKE) -C tools DESTDIR=$(CURDIR)/debian/osmpbf-bin PREFIX=/usr install
+ dh_auto_install --buildsystem ant
+ dh_auto_install -Dsrc -- PREFIX=/usr
+ dh_auto_install -Dtools -- PREFIX=/usr
override_dh_installchangelogs:
dh_installchangelogs -- ReleaseNotes.txt
override_dh_install:
+ dh_install
mh_installjar -plibosmpbf-java -l pom.xml osmpbf.jar
mh_installpom -plibosmpbf-java pom.xml
-
diff --git a/debian/watch b/debian/watch
new file mode 100644
index 0000000..dabf08d
--- /dev/null
+++ b/debian/watch
@@ -0,0 +1,2 @@
+version=3
+http://githubredir.debian.net/github/scrosby/OSM-binary/v(\d+.*)\.tar\.gz
diff --git a/src/Makefile b/src/Makefile
index 3818b98..a7fa8e8 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -1,10 +1,12 @@
-PREFIX ?= /usr/local
-CXX ?= g++
+# these default settings can be overridden by setting environment variables
+PREFIX ?= /usr/local
+CXX ?= g++
CXXFLAGS ?= -O3
+AR ?= ar
+PROTOC ?= protoc
-AR ?= ar
-PROTOC ?= protoc
+CXXFLAGS += -Wall -Wextra -pedantic -Wredundant-decls -Wdisabled-optimization -Wctor-dtor-privacy -Wnon-virtual-dtor -Woverloaded-virtual -Wsign-promo -Wno-long-long
.PHONY: clean install
diff --git a/tools/Makefile b/tools/Makefile
index 888d56c..5051d52 100644
--- a/tools/Makefile
+++ b/tools/Makefile
@@ -1,9 +1,11 @@
-PREFIX ?= /usr/local
-CXX ?= g++
+# these default settings can be overridden by setting environment variables
+PREFIX ?= /usr/local
+CXX ?= g++
CXXFLAGS ?= -g
+
CXXFLAGS += -I../include -Wall -Wextra -pedantic -Wredundant-decls -Wdisabled-optimization -Wctor-dtor-privacy -Wnon-virtual-dtor -Woverloaded-virtual -Wsign-promo -Wno-long-long
-LDFLAGS += -L../src -pthread -lz -lprotobuf-lite -losmpbf
+LDFLAGS += -L../src -pthread -lz -lprotobuf-lite -losmpbf
.PHONY: clean install
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-grass/osmpbf.git
More information about the Pkg-grass-devel
mailing list