summaryrefslogtreecommitdiffstats
path: root/ubuntu/_base/libraries/libkdcraw/debian/cdbs/debian-tde.mk
diff options
context:
space:
mode:
Diffstat (limited to 'ubuntu/_base/libraries/libkdcraw/debian/cdbs/debian-tde.mk')
-rw-r--r--ubuntu/_base/libraries/libkdcraw/debian/cdbs/debian-tde.mk54
1 files changed, 52 insertions, 2 deletions
diff --git a/ubuntu/_base/libraries/libkdcraw/debian/cdbs/debian-tde.mk b/ubuntu/_base/libraries/libkdcraw/debian/cdbs/debian-tde.mk
index fb8c1b6c3..aba508624 100644
--- a/ubuntu/_base/libraries/libkdcraw/debian/cdbs/debian-tde.mk
+++ b/ubuntu/_base/libraries/libkdcraw/debian/cdbs/debian-tde.mk
@@ -57,6 +57,15 @@ ifndef _cdbs_class_cmake
include $(_cdbs_class_path)/autotools.mk$(_cdbs_makefile_suffix)
endif
+ifdef _cdbs_class_cmake
+ifneq "$(wildcard /usr/bin/ninja)" ""
+MAKE = ninja -v
+DEB_MAKE_ENVVARS += DESTDIR=$(DEB_DESTDIR)
+DEB_MAKE_INSTALL_TARGET = install
+DEB_CMAKE_NORMAL_ARGS += -GNinja
+endif
+endif
+
ifndef _cdbs_rules_patchsys_quilt
DEB_PATCHDIRS := debian/patches/common debian/patches
endif
@@ -73,7 +82,17 @@ DEB_SHLIBDEPS_INCLUDE = $(foreach p,$(PACKAGES_WITH_LIBS),debian/$(p)/usr/lib)
DEB_AC_AUX_DIR = $(DEB_SRCDIR)/admin
DEB_CONFIGURE_INCLUDEDIR = "\$${prefix}/include"
-DEB_COMPRESS_EXCLUDE = .dcl .docbook -license .tag .sty .el
+DEB_COMPRESS_EXCLUDE_ALL += .dcl .docbook -license .tag .sty .el
+
+# The default gzip compressor has been changed in dpkg >= 1.17.0.
+deb_default_compress = $(shell LANG=C dpkg-deb --version | head -n1 | \
+ sed -e "s|.*version ||" -e "s| .*||" | \
+ xargs -r dpkg --compare-versions 1.17.0 lt \
+ && echo xz || echo gzip)
+ifeq ($(deb_default_compress),gzip)
+DEB_DH_BUILDDEB_ARGS += -- -Z$(shell dpkg-deb --help | grep -q ":.* xz[,.]" \
+ && echo xz || echo bzip2)
+endif
ifeq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
cdbs_treat_me_gently_arches := arm m68k alpha ppc64 armel armeb
@@ -95,6 +114,8 @@ ifneq (,$(filter debug,$(DEB_BUILD_OPTIONS)))
cdbs_kde_enable_debug = --enable-debug=full
endif
+DEB_BUILD_PARALLEL ?= true
+
cdbs_configure_flags += \
--with-qt-dir=/usr/share/qt3 \
--disable-rpath \
@@ -111,6 +132,14 @@ ifndef _cdbs_class_cmake
endif
debian/rules clean
+.tdepkginfo:
+ echo "# TDE package information" >.tdepkginfo
+ dpkg-parsechangelog | sed -n "s|^Source: |Name: |p" >>.tdepkginfo
+ dpkg-parsechangelog | sed -n "s|^Version: |Version: |p" >>.tdepkginfo
+ date +"DateTime: %m/%d/%Y %H:%M" -u -d "$$(dpkg-parsechangelog | sed -n 's|^Date: ||p')" >>.tdepkginfo
+
+post-patches:: .tdepkginfo
+
common-build-arch:: debian/stamp-man-pages
debian/stamp-man-pages:
if ! test -d debian/man/out; then mkdir -p debian/man/out; fi
@@ -140,12 +169,27 @@ common-binary-arch::
cat $$tmpf >>debian/$$p.substvars; \
done; \
rm -f $$tmpf )
+ # update multi-arch path in install files
+ ls -d debian/* | \
+ grep -E "(install|links)$$" | \
+ while read a; do \
+ [ -d $$a ] || [ -f $$a.arch ] || \
+ ! grep -q "\$$(DEB_HOST_MULTIARCH)" $$a || \
+ sed -i.arch "s|\$$(DEB_HOST_MULTIARCH)|$(DEB_HOST_MULTIARCH)|g" $$a; \
+ done
clean::
rm -rf debian/man/out
-rmdir debian/man
rm -f debian/stamp-man-pages
rm -rf debian/shlibs-check
+ # revert multi-arch path in install files
+ ls -d debian/* | \
+ grep -E "(install|links)$$" | \
+ while read a; do \
+ [ ! -f $$a.arch ] || \
+ mv $$a.arch $$a; \
+ done
$(patsubst %,binary-install/%,$(DEB_PACKAGES)) :: binary-install/%:
if test -x /usr/bin/dh_icons; then dh_icons -p$(cdbs_curpkg) $(DEB_DH_ICONCACHE_ARGS); fi
@@ -158,6 +202,11 @@ $(patsubst %,binary-install/%,$(DEB_PACKAGES)) :: binary-install/%:
install -p -D -m644 debian/$(cdbs_curpkg).presubj \
debian/$(cdbs_curpkg)/usr/share/bug/$(cdbs_curpkg)/presubj; \
fi
+ if test -d debian/$(cdbs_curpkg)/opt/trinity/lib && \
+ test $$(find debian/$(cdbs_curpkg)/opt/trinity/lib -name "*.so" | wc -l) -gt 0; then \
+ echo "# Triggers added by cdbs/debian-tde.mk" >> debian/.debhelper/generated/$(cdbs_curpkg)/triggers; \
+ echo "activate-noawait ldconfig" >> debian/.debhelper/generated/$(cdbs_curpkg)/triggers; \
+ fi
binary-install/$(DEB_SOURCE_PACKAGE)-doc-html::
set -e; \
@@ -179,7 +228,7 @@ debian/stamp-kde-apidox:
common-install-indep:: common-install-kde-apidox
common-install-kde-apidox::
- $(if $(DEB_KDE_APIDOX),+$(DEB_MAKE_INVOKE) install-apidox DESTDIR=$(DEB_DESTDIR))
+ $(if $(DEB_KDE_APIDOX),+DESTDIR=$(DEB_DESTDIR) $(DEB_MAKE_INVOKE) install-apidox)
cleanbuilddir::
-$(if $(call cdbs_streq,$(DEB_BUILDDIR),$(DEB_SRCDIR)),,rm -rf $(DEB_BUILDDIR))
@@ -195,6 +244,7 @@ ifndef _cdbs_class_cmake
subdirs; \
fi
endif
+ rm -f .tdepkginfo
rm -f debian/stamp-kde-apidox
rm -f debian/stamp-cvs-make