Frankie, as recently discussed on IRC, I took a stab at upgrading ossim to a current release. Attached is a patch against the svn repo (do I have commit access to that, given that IIRC I'm a member of pkg-grass-devel?).
Please review and comment whether or not you agree with the general direction. Some comments and lose ends: - lintian complains about hardening issues, looks like I don't properly pass the LDFLAGS through cmake, yet. - I dropped the static library build for now. How important is that? - ossim-config isn't built, anymore, nor is there an ossim.pc (for pkg-config) - I didn't do any testing of the resulting library or utilities, but am happy it builds at all, for now. Regards Markus Wanner
Index: debian/changelog =================================================================== --- debian/changelog (revision 3124) +++ debian/changelog (working copy) @@ -1,3 +1,21 @@ +ossim (1.8.16-1) unstable; urgency=low + + * New upstream release. Closes: #640010. + * Revamp rules, adjusting it to the new build toolchain used (cmake); + adapt build dependencies. + * Add -dbg packages with debug symbols, but drop the static variant of + the library from from the -dev package. + * Add at least a libossim1.shlibs (symbols don't match between i386 and + amd64). + * Bump Standards-Version to 3.9.5. + * Switch to dpkg-source 3.0 (quilt) format. + * Add a watch file. + * Drop initial article from description. + * Canonicalize Vcs-* fields. + * Add myself as an uploader. + + -- Markus Wanner <[email protected]> Fri, 24 Jan 2014 14:18:09 +0100 + ossim (1.7.21-3) unstable; urgency=low * Truly fixed dependency on virtual package libcurl4-dev. Index: debian/control =================================================================== --- debian/control (revision 3124) +++ debian/control (working copy) @@ -2,20 +2,22 @@ Section: science Priority: extra Maintainer: Debian GIS Project <[email protected]> -Uploaders: Francesco Paolo Lovergine <[email protected]> -Build-Depends: cdbs, debhelper (>= 7), libopenscenegraph-dev, libzzip-dev, zlib1g-dev, libtiff4-dev, - libjpeg-dev, libexpat1-dev, libcurl4-gnutls-dev|libcurl4-dev, libpng12-dev, libgif-dev, libgeotiff-dev, quilt, libopenthreads-dev, - libtar-dev, libfreetype6-dev -Standards-Version: 3.9.2 +Uploaders: Francesco Paolo Lovergine <[email protected]>, + Markus Wanner <[email protected]> +Build-Depends: debhelper (>= 7), cmake, libopenscenegraph-dev, + libzzip-dev, zlib1g-dev, libtiff4-dev, libjpeg-dev, libexpat1-dev, + libcurl4-gnutls-dev | libcurl4-dev, libpng12-dev, libgif-dev, + libgeotiff-dev, libtar-dev, libfreetype6-dev +Standards-Version: 3.9.5 Homepage: http://www.ossim.org/ -Vcs-Browser: http://svn.debian.org/viewsvn/pkg-grass/packages/ossim/trunk -Vcs-Svn: svn://svn.debian.org/svn/pkg-grass/packages/ossim/trunk +Vcs-Browser: http://anonscm.debian.org/viewsvn/pkg-grass/packages/ossim/trunk +Vcs-Svn: svn://anonscm.debian.org/pkg-grass/packages/ossim/trunk Package: libossim1 Section: libs Architecture: any Depends: ${shlibs:Depends}, ${misc:Depends} -Description: The OSSIM library -- shared library +Description: OSSIM library -- shared library Open Source Software Image Map (OSSIM) is a high performance engine for remote sensing, image processing, geographical information systems and photogrammetry. It has been actively developed since 1996. @@ -41,7 +43,7 @@ Section: libdevel Depends: libossim1 (= ${binary:Version}), ${shlibs:Depends}, ${misc:Depends}, libgeotiff-dev -Description: The OSSIM library -- development files +Description: OSSIM library -- development files Open Source Software Image Map (OSSIM) is a high performance engine for remote sensing, image processing, geographical information systems and photogrammetry. It has been actively developed since 1996. @@ -63,10 +65,35 @@ This package includes the development files to build programs that use the OSSIM library. +Package: libossim-dbg +Architecture: any +Section: debug +Depends: libossim1 (= ${binary:Version}), ${misc:Depends} +Description: OSSIM library -- debugging symbols + Open Source Software Image Map (OSSIM) is a high performance engine for + remote sensing, image processing, geographical information systems and + photogrammetry. It has been actively developed since 1996. + . + Designed as a series of high performance software libraries, it is + written in C++ employing the latest techniques in object-oriented + software design. + . + The library provides advanced remote sensing, image processing, and + geo-spatial functionality. A quick summary of OSSIM functionality + includes ortho-rectification, precision terrain correction, rigorous + sensor models, very large mosaics, and cross sensor fusions, a wide + range of map projections anddatums, and a large range of commercial + and government data formats. The architecture of the library supports + parallel processing with mpi, a dynamic plugin architecture, and + dynamically connectable objects allowing rapid prototyping of custom + image processing chains. + . + This package contains the debugging symbols. + Package: ossim-core Architecture: any Depends: libossim1 (= ${binary:Version}), ${shlibs:Depends}, ${misc:Depends} -Description: The OSSIM core utilities +Description: OSSIM core utilities Open Source Software Image Map (OSSIM) is a high performance engine for remote sensing, image processing, geographical information systems and photogrammetry. It has been actively developed since 1996. @@ -87,3 +114,29 @@ . This package includes core tools that use the OSSIM library to perform some basic tasks. + +Package: ossim-core-dbg +Architecture: any +Section: debug +Depends: ossim-core (= ${binary:Version}), ${misc:Depends} +Description: OSSIM core utilities -- debugging symbols + Open Source Software Image Map (OSSIM) is a high performance engine for + remote sensing, image processing, geographical information systems and + photogrammetry. It has been actively developed since 1996. + . + Designed as a series of high performance software libraries, it is + written in C++ employing the latest techniques in object-oriented + software design. + . + The library provides advanced remote sensing, image processing, and + geo-spatial functionality. A quick summary of OSSIM functionality + includes ortho-rectification, precision terrain correction, rigorous + sensor models, very large mosaics, and cross sensor fusions, a wide + range of map projections anddatums, and a large range of commercial + and government data formats. The architecture of the library supports + parallel processing with mpi, a dynamic plugin architecture, and + dynamically connectable objects allowing rapid prototyping of custom + image processing chains. + . + This package contains the debugging symbols for the core tools of the + OSSIM library. Index: debian/libossim-dev.install =================================================================== --- debian/libossim-dev.install (revision 3124) +++ debian/libossim-dev.install (working copy) @@ -1,4 +1,2 @@ usr/lib/libossim.so -usr/lib/libossim.a usr/include -usr/bin/ossim-config Index: debian/libossim1.shlib =================================================================== --- debian/libossim1.shlib (revision 0) +++ debian/libossim1.shlib (working copy) @@ -0,0 +1 @@ +libossim 1 libossim1 Index: debian/ossim-core.install =================================================================== --- debian/ossim-core.install (revision 3124) +++ debian/ossim-core.install (working copy) @@ -1,8 +1,8 @@ -usr/share/ossim/templates +# usr/share/ossim/templates usr/bin/ossim-adrg-dump usr/bin/ossim-applanix2ogeom usr/bin/ossim-band-merge -usr/bin/ossim-bmvstager +# usr/bin/ossim-bmvstager usr/bin/ossim-btoa usr/bin/ossim-chgkwval usr/bin/ossim-cmm @@ -11,10 +11,10 @@ usr/bin/ossim-create-cg usr/bin/ossim-create-histo usr/bin/ossim-dump-ocg -usr/bin/ossim-ecg2ocg +# usr/bin/ossim-ecg2ocg usr/bin/ossim-extract-vertices -usr/bin/ossim-foo -usr/bin/ossim-height +# usr/bin/ossim-foo +# usr/bin/ossim-height usr/bin/ossim-icp usr/bin/ossim-igen usr/bin/ossim-img2md Index: debian/rules =================================================================== --- debian/rules (revision 3124) +++ debian/rules (working copy) @@ -1,42 +1,68 @@ #!/usr/bin/make -f -DEB_TAR_SRCDIR = ossim -DEB_TARBALL = $(CURDIR)/upstream/$(DEB_TAR_SRCDIR).tar.gz -SRC_TREE = $(CURDIR)/build-tree/$(DEB_TAR_SRCDIR) -OSSIM_VERSION=$(shell dpkg-parsechangelog|grep Version:|cut -d' ' -f2|cut -d- -f1) -OSSIM_VERSION_TAG=$(subst .,_,$(OSSIM_VERSION)) +# Uncomment this to turn on verbose mode. +export DH_VERBOSE=1 -ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) - CFLAGS += -O0 - OPTFLAG = -else - CFLAGS += -O2 - OPTFLAG = --enable-optimization -endif +#http://wiki.debian.org/Hardening#Notes_for_packages_using_CMake +CXXFLAGS:=$(shell dpkg-buildflags --get CXXFLAGS) $(CPPFLAGS) +LDFLAGS:=$(shell dpkg-buildflags --get LDFLAGS) -include /usr/share/cdbs/1/rules/tarball.mk -include /usr/share/cdbs/1/rules/debhelper.mk -include /usr/share/cdbs/1/class/autotools.mk -include /usr/share/cdbs/1/rules/patchsys-quilt.mk -clean:: - rm -f $(CURDIR)/upstream/ossim.tar.gz.cdbs-config_list +CMAKE_FLAGS = \ + -DCMAKE_BUILD_TYPE="RelWithDebInfo" \ + -DCMAKE_CXX_FLAGS="$(CXXFLAGS)" \ + -DCMAKE_CXX_FLAGS_RELWITHDEBINFO="$(CXXFLAGS) -g -DNDEBUG" \ + -DCMAKE_EXE_LINKER_FLAGS="$(LDFLAGS)" \ + -DCMAKE_SHARED_LINKER_FLAGS="$(LDFLAGS)" \ + -DCMAKE_VERBOSE_MAKEFILE=ON \ + -DCMAKE_MODULE_PATH=$(CURDIR)/ossim_package_support/cmake/CMakeModules \ + -DCMAKE_INSTALL_PREFIX:PATH=/usr \ + -DBUILD_OSSIM_FREETYPE_SUPPORT=ON \ + -DBUILD_OSSIM_MPI_SUPPORT=OFF \ + -DBUILD_OSSIM_ID_SUPPORT=ON \ + -DBUILD_OSSIM_TEST_APPS=ON -install/ossim-core:: - -find debian/tmp/usr/share/ossim/templates -type f -exec chmod a-x {} \; +%: + dh $@ --sourcedirectory=ossim --buildsystem=cmake \ + --builddirectory=build --parallel -# Add here any variable or target overrides you need. +override_dh_auto_configure: + mkdir build + cd build && cmake ../ossim $(CMAKE_FLAGS) -DEB_CONFIGURE_EXTRA_FLAGS = --prefix=/usr --datadir=/usr/share --includedir=/usr/include --with-jpeg=/usr \ - --with-libtiff=/usr --with-geotiff=/usr/include/geotiff --with-openthreads= \ - --enable-singleSharedOssimLibrary --enable-singleStaticOssimLibrary \ - --with-freetype=/usr --with-mpi=no $(OPTFLAG) +override_dh_strip: + dh_strip -plibossim1 --dbg-package=libossim-dbg + dh_strip -possim-core --dbg-package=ossim-core-dbg +override_dh_auto_clean: + rm -f ossim/include/ossim/ossimConfig.h + rm -f ossim/include/ossim/ossimVersion.h + dh_auto_clean + + +# The following make target generates a custom tarball from SVN using +# the appropriate tag. Mainly because the (ossim) release tarball +# doesn't ship the necessary cmake files to build, but keeps these in +# a separate tree. + +OSSIM_VERSION=$(shell dpkg-parsechangelog|grep Version:|cut -d' ' -f2|cut -d- -f1) +OSSIM_TAG=v1.8.16-5 + get-orig-source: - cd /tmp && svn export http://svn.osgeo.org/ossim/tags/v$(OSSIM_VERSION_TAG)/ossim - # removes JAR archives - cd /tmp && find ossim -name "*.jar" -delete - mkdir -p /tmp/ossim-$(OSSIM_VERSION)/upstream - tar czvf /tmp/ossim-$(OSSIM_VERSION)/upstream/ossim.tar.gz -C /tmp ossim - tar czvf ossim_$(OSSIM_VERSION).orig.tar.gz -C /tmp ossim-$(OSSIM_VERSION) +# Download from subversion + mkdir -p /tmp/ossim-$(OSSIM_VERSION) + svn export -q \ + http://svn.osgeo.org/ossim/tags/$(OSSIM_TAG)/ossim \ + /tmp/ossim-$(OSSIM_VERSION)/ossim + svn export -q \ + http://svn.osgeo.org/ossim/tags/$(OSSIM_TAG)/ossim_package_support \ + /tmp/ossim-$(OSSIM_VERSION)/ossim_package_support + +# Get rid of some deprecated autoconf stuff to make lintian happier. + find /tmp/ossim-$(OSSIM_VERSION) -iname "config.guess" -delete + find /tmp/ossim-$(OSSIM_VERSION) -iname "config.sub" -delete + find /tmp/ossim-$(OSSIM_VERSION) -iname "ltmain.sh" -delete + + tar czf ../ossim_$(OSSIM_VERSION).orig.tar.gz \ + -C /tmp ossim-$(OSSIM_VERSION) rm -rf /tmp/ossim /tmp/ossim-$(OSSIM_VERSION) Index: debian/source/format =================================================================== --- debian/source/format (revision 0) +++ debian/source/format (working copy) @@ -0,0 +1 @@ +3.0 (quilt) Index: debian/watch =================================================================== --- debian/watch (revision 0) +++ debian/watch (working copy) @@ -0,0 +1,5 @@ +version=3 + +opts=uversionmangle=s/(\d)[_\.\-\+]?((RC|rc|pre|dev|beta|alpha|b|a)\d*)$/$1~$2/ \ + http://download.osgeo.org/ossim/source/latest/ \ + (?:.*/|)ossim[\-\._]?([\d\.]+(?:(?:RC|rc|pre|dev|beta|alpha|b|a)\d+)?)\.(?:tar\.xz|txz|tar\.bz2|tbz2|tar\.gz|tgz)
signature.asc
Description: OpenPGP digital signature
_______________________________________________ Pkg-grass-devel mailing list [email protected] http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-grass-devel

