#!/usr/bin/make -f # -*- makefile -*- # The magic debhelper rule %: dh $@ # Uncomment this to turn on verbose mode. export DH_VERBOSE=1 export QT_SELECT=5 DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH) AUTOGENERATED:= libterralib-dev.links libterralib3.install libterralib-dev.install libterralib.pc # To enable all, uncomment following line DEB_BUILD_MAINT_OPTIONS:= hardening=+all DEB_CFLAGS_MAINT_APPEND:= -Wall -pedantic export DEB_BUILD_MAINT_OPTIONS export DEB_CFLAGS_MAINT_APPEND CXXFLAGS:= $(shell dpkg-buildflags --get CXXFLAGS) -std=c++11 CXXFLAGS:= '$(CXXFLAGS) -fpermissive -I/usr/include/geotiff -I/usr/include/dxflib -I/usr/include/qwt' override_dh_auto_build: find examples -type f -exec chmod 644 {} \; for f in ${AUTOGENERATED} ; do \ sed -e 's%@DEB_HOST_MULTIARCH@%${DEB_HOST_MULTIARCH}%g' < debian/$$f.in > debian/$$f ; \ done for d in terralib te_functions te_utils image_processing PostgreSQL MySQL shapelib stat te_dxf te_shapelib ; do \ ( cd build/qt4/$$d && qmake QMAKE_CXXFLAGS=$(CXXFLAGS) $$d.pro && $(MAKE) ) ; \ done # Disable qwt, terraView work until after libqwt-qt5-dev transition #for d in qwt ; do \ # ( cd build/qt/$$d && qmake QMAKE_CXXFLAGS=$(CXXFLAGS) $$d.pro && $(MAKE) ) ; \ # done for d in terralib te_functions te_utils terralibpdi shapelib te_shapelib te_mysql te_postgresql te_dxf stat ; do \ ar rcs Release/lib$$d.a `LC_ALL=C ls Release/linux-g++/obj/$$d/*.o` ;\ done override_dh_clean: dh_clean rm -rf Release rm -f $(patsubst %, debian/%, ${AUTOGENERATED}) find . -name '.cvsignore' -delete for d in terralib te_functions te_utils image_processing PostgreSQL MySQL shapelib stat te_dxf te_shapelib ; do \ ( $(MAKE) -C build/qt4/$$d distclean || echo "$$d already clean" ) ; \ done