[pkg-fgfs-crew] [simgear] 01/01: * rules: rewrite to use dh7, simplify a lot, drop the static libraries from the -dev package. * Bump compat level to 8.

Markus Wanner markus_wanner-guest at alioth.debian.org
Sat Aug 10 07:07:47 UTC 2013


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

markus_wanner-guest pushed a commit to branch master
in repository simgear.

commit 50749745069d43efb5def8b1f2cad8982f87037a
Author: Markus Wanner <markus at bluegap.ch>
Date:   Sat Aug 10 09:05:24 2013 +0200

    * rules: rewrite to use dh7, simplify a lot, drop the static libraries
      from the -dev package.
    * Bump compat level to 8.
---
 debian/changelog                     |    3 +
 debian/compat                        |    2 +-
 debian/libsimgear-dev.install        |    2 +
 debian/libsimgearcore2.10.0.install  |    1 +
 debian/libsimgearscene2.10.0.install |    1 +
 debian/rules                         |  114 +++++-----------------------------
 6 files changed, 22 insertions(+), 101 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index 21594a5..eb5d3ad 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -14,6 +14,9 @@ simgear (2.10.0-1) UNRELEASED; urgency=low
   * Add patch osg-compat.diff for compatibility with OSG 3.1.8 and newer.
   * Compile against the system's expat library. Closes: #560937.
   * control: let VCS point to new git repo in collab-maint
+  * Bump compat level to 8.
+  * rules: rewrite to use dh7, simplify a lot, drop the static libraries
+    from the -dev package.
 
  -- Markus Wanner <markus at bluegap.ch>  Wed, 31 Jul 2013 21:20:51 +0200
 
diff --git a/debian/compat b/debian/compat
index 7ed6ff8..45a4fb7 100644
--- a/debian/compat
+++ b/debian/compat
@@ -1 +1 @@
-5
+8
diff --git a/debian/libsimgear-dev.install b/debian/libsimgear-dev.install
new file mode 100644
index 0000000..b02ffd9
--- /dev/null
+++ b/debian/libsimgear-dev.install
@@ -0,0 +1,2 @@
+usr/lib/*/lib*.so
+usr/include
diff --git a/debian/libsimgearcore2.10.0.install b/debian/libsimgearcore2.10.0.install
new file mode 100644
index 0000000..3f0efdf
--- /dev/null
+++ b/debian/libsimgearcore2.10.0.install
@@ -0,0 +1 @@
+usr/lib/*/libSimGearCore.so.2.10*
diff --git a/debian/libsimgearscene2.10.0.install b/debian/libsimgearscene2.10.0.install
new file mode 100644
index 0000000..42683b0
--- /dev/null
+++ b/debian/libsimgearscene2.10.0.install
@@ -0,0 +1 @@
+usr/lib/*/libSimGearScene.so.2.10*
diff --git a/debian/rules b/debian/rules
index 5f5821b..7278efd 100755
--- a/debian/rules
+++ b/debian/rules
@@ -1,19 +1,8 @@
 #!/usr/bin/make -f
-# Sample debian/rules that uses debhelper.
-# GNU copyright 1997 to 1999 by Joey Hess.
-
-# Uncomment this to turn on verbose mode.
-#export DH_VERBOSE=1
-
-ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
-NUMJOBS = $(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
-MAKEFLAGS += -j$(NUMJOBS)
-endif
-
-DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
-
-deb_version := $(lastword $(shell dpkg-parsechangelog|grep "^Version: "))
-version := $(shell echo $(deb_version)|sed -n 's,^\(.*\)-[^-]*$$,\1,p')
+# -*- makefile -*-
+#
+# debian/rules for simgear, by Markus Wanner
+# based on the dh7 template provided by dh_make(1)
 
 #http://wiki.debian.org/Hardening#Notes_for_packages_using_CMake
 CPPFLAGS:=$(shell dpkg-buildflags --get CPPFLAGS)
@@ -26,95 +15,20 @@ CMAKE_FLAGS = \
 	-DCMAKE_C_FLAGS="$(CFLAGS)" \
 	-DCMAKE_CXX_FLAGS="$(CXXFLAGS)" \
 	-DCMAKE_CXX_FLAGS_RELWITHDEBINFO="-g -DNDEBUG" \
+	-DCMAKE_SIMGEAR_SHARED=ON \
 	-DCMAKE_SHARED_LINKER_FLAGS="$(LDFLAGS)" \
 	-DCMAKE_VERBOSE_MAKEFILE=ON \
 	-DCMAKE_INSTALL_PREFIX:PATH=/usr \
+	-DSYSTEM_EXPAT=ON \
 	-DJPEG_FACTORY=ON
-CMAKE_SOFLAGS=-DSIMGEAR_SHARED=ON -DSYSTEM_EXPAT=ON
-CMAKE_LIBFLAGS=
-
-configure: configure-stamp
-configure-stamp:
-	dh_testdir
-
-	mkdir build-so
-	cd build-so && cmake .. $(CMAKE_FLAGS) $(CMAKE_SOFLAGS)
-
-	mkdir build-lib
-	cd build-lib && cmake .. $(CMAKE_FLAGS) $(CMAKE_LIBFLAGS)
-
-	touch configure-stamp
-
-build-arch: configure-stamp build-stamp
-build-stamp: configure-stamp
-	dh_testdir
-
-	cd build-so && $(MAKE)
-	cd build-lib && $(MAKE)
-
-	touch build-stamp
-
-build-indep:
-build: build-arch build-indep
-
-clean:
-	dh_testdir
-	dh_testroot
-	rm -f build-stamp configure-stamp
-
-	rm -rf build-so
-	rm -rf build-lib
-
-	dh_clean
-
-install: build
-	dh_testdir
-	dh_testroot
-	dh_prep
-
-	# Install libraries and headers
-	cd build-so && \
-	$(MAKE) install DESTDIR=$(CURDIR)/debian/tmp
-	cd build-lib && \
-	$(MAKE) install DESTDIR=$(CURDIR)/debian/tmp
-
-	# Install shared libraries
-	dh_install -plibsimgearcore$(version) --autodest \
-		debian/tmp/usr/lib/$(DEB_HOST_MULTIARCH)/libSimGearCore.so.*
-	dh_install -plibsimgearscene$(version) --autodest \
-		debian/tmp/usr/lib/$(DEB_HOST_MULTIARCH)/libSimGearScene.so.*
-	dh_install -plibsimgear-dev --autodest \
-		debian/tmp/usr/lib/$(DEB_HOST_MULTIARCH)/*.so
-
-	# Install static libraries
-	dh_install -plibsimgear-dev --autodest debian/tmp/usr/lib/$(DEB_HOST_MULTIARCH)/*.a
-	# Install headers
-	dh_install -plibsimgear-dev --autodest debian/tmp/usr/include
-
-	dh_install --list-missing
-
-# Build architecture-independent files here.
-binary-indep: build install
-# We have nothing to do by default.
 
-# Build architecture-dependent files here.
-binary-arch: build install
-	dh_testdir
-	dh_testroot
+%:
+	dh $@ --buildsystem=cmake --builddirectory=build --parallel
 
-	dh_installdocs
-	dh_installchangelogs ChangeLog
-	dh_link
-	dh_strip -plibsimgearcore$(version) --dbg-package=libsimgearcore$(version)-dbg
-	dh_strip -plibsimgearscene$(version) --dbg-package=libsimgearscene$(version)-dbg
-	dh_compress
-	dh_fixperms
-	dh_makeshlibs -V
-	dh_installdeb
-	dh_shlibdeps
-	dh_gencontrol
-	dh_md5sums
-	dh_builddeb
+override_dh_auto_configure:
+	mkdir build
+	cd build && cmake .. $(CMAKE_FLAGS)
 
-binary: binary-indep binary-arch
-.PHONY: build clean binary-indep binary-arch binary install configure
+override_dh_strip:
+	dh_strip -plibsimgearcore2.10.0 --dbg-package=libsimgearcore2.10.0-dbg
+	dh_strip -plibsimgearscene2.10.0 --dbg-package=libsimgearscene2.10.0-dbg

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/collab-maint/simgear.git



More information about the pkg-fgfs-crew mailing list