1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62
|
#!/usr/bin/make -f
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
NULL =
export DEB_BUILD_MAINT_OPTIONS = hardening=+all
DPKG_EXPORT_BUILDFLAGS = 1
include /usr/share/dpkg/buildflags.mk
export QT_SELECT := qt5
include /usr/share/dpkg/architecture.mk
QT_MODULE_VERSION = $(shell cat .qmake.conf | grep MODULE_VERSION | sed -re 's/MODULE_VERSION\s*=\s*([^\s]+)\s*/\1/')
%:
dh $@ --with pkgkde_symbolshelper
override_dh_auto_build:
dh_auto_build
# only build doc files for architectures that have qt5-qtdoc
if [ -e /usr/lib/$(DEB_HOST_MULTIARCH)/qt5/bin/qdoc ]; then \
make docs; \
fi
override_dh_auto_configure:
cd src/feedback/ && perl /usr/lib/qt5/bin/syncqt.pl -module QtFeedback -version $(QT_MODULE_VERSION) -outdir $(CURDIR) -builddir $(CURDIR) $(CURDIR) && cd - 1>/dev/null
dh_auto_configure
override_dh_auto_install:
dh_auto_install
# only install doc files for architectures that have qt5-qtdoc
if [ -e /usr/lib/$(DEB_HOST_MULTIARCH)/qt5/bin/qdoc ]; then \
$(MAKE) INSTALL_ROOT=$(CURDIR)/debian/tmp install_docs; \
fi
# Fix wrong path in pkgconfig files
find $(CURDIR)/debian/tmp/usr/lib/$(DEB_HOST_MULTIARCH)/pkgconfig -type f -name '*.pc' \
-exec sed -i -e 's/$(DEB_HOST_MULTIARCH)\/$(DEB_HOST_MULTIARCH)/$(DEB_HOST_MULTIARCH)/g' {} \;
# Remove private stuff
rm -rfv debian/tmp/usr/include/*/qt5/QtFeedback/*/QtFeedback/private/
rm -fv $(CURDIR)/debian/tmp/usr/lib/*/qt5/mkspecs/modules/qt_lib_*_private.pri
# Remove broken .cmake file
rm -fv $(CURDIR)/debian/tmp/usr/lib/*/cmake/Qt5Feedback/Qt5Feedback_.cmake
# Remove libtool-like files
rm -f debian/tmp/usr/lib/$(DEB_HOST_MULTIARCH)/*.la
override_dh_auto_test:
# Copy missing qmldir file to have tests running successfully
cp -a src/imports/feedback/qmldir qml/QtFeedback/
cd tests ; qmake ; make
cd tests ; xvfb-run -a make check QML2_IMPORT_PATH=../../../qml QT_PLUGIN_PATH=$(CURDIR)/plugins LD_LIBRARY_PATH=$(CURDIR)/lib
get-orig-source:
uscan --noconf --force-download --rename --download-current-version --destdir=..
|