| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
include /usr/share/dpkg/pkg-info.mk |
| 8 |
|
| 9 |
|
| 10 |
include /usr/share/dpkg/architecture.mk |
| 11 |
|
| 12 |
export DEB_BUILD_MAINT_OPTIONS = hardening=+all |
| 13 |
|
| 14 |
|
| 15 |
export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed |
| 16 |
|
| 17 |
plugins := applix babelfish bmp clarisworks command docbook \ |
| 18 |
eml epub freetranslation garble gdict gimp google grammar hancom \ |
| 19 |
hrtext iscii kword latex loadbindings mht mif mswrite \ |
| 20 |
opendocument openwriter openxml opml ots paint passepartout pdb \ |
| 21 |
pdf presentation s5 sdw t602 urldict wikipedia wmf wml \ |
| 22 |
wordperfect wpg xslfo goffice |
| 23 |
|
| 24 |
|
| 25 |
|
| 26 |
|
| 27 |
|
| 28 |
|
| 29 |
PKD = $(abspath $(dir $(MAKEFILE_LIST))) |
| 30 |
PKG = $(DEB_SOURCE) |
| 31 |
ifneq (,$(wildcard configure.*)) |
| 32 |
|
| 33 |
apiver:=$(shell perl -0ne 'print "$$1.$$2" if m{\[abi_version_major\],\s+\[(\d+)\].*?\[abi_version_minor\],\s+\[(\d+)\]}s' configure.*) |
| 34 |
endif |
| 35 |
|
| 36 |
plib=lib$(PKG)-$(apiver) |
| 37 |
|
| 38 |
%: |
| 39 |
dh $@ |
| 40 |
|
| 41 |
override_dh_clean: |
| 42 |
|
| 43 |
|
| 44 |
[ ! -x "$(which flex)" ] || $(RM) -v plugins/mathview/itex2mml/lex.yy.c |
| 45 |
[ ! -x "tools/cdump/xp/cdump.pl" ] || $(RM) -v src/wp/ap/xp/ap_wp_sidebar.cpp |
| 46 |
[ ! -x "./autogen-common.sh" ] || $(RM) -v plugin*.m4 po/*.strings |
| 47 |
dh_clean |
| 48 |
|
| 49 |
override_dh_autoreconf: |
| 50 |
$(info I: library-name=$(plib)) |
| 51 |
$(if $(wildcard debian/$(plib).install),,$(error invalid package/library name.)) |
| 52 |
|
| 53 |
[ ! -x "./autogen-common.sh" ] || ./autogen-common.sh |
| 54 |
dh_autoreconf --as-needed |
| 55 |
|
| 56 |
|
| 57 |
|
| 58 |
override_dh_auto_configure: |
| 59 |
PATH=$(PATH):/usr/lib/$(DEB_HOST_MULTIARCH)/libwmf/bin \ |
| 60 |
dh_auto_configure -- \ |
| 61 |
--with-gio \ |
| 62 |
--with-redland \ |
| 63 |
--with-libtidy \ |
| 64 |
--with-goffice \ |
| 65 |
--enable-shared \ |
| 66 |
--enable-clipart \ |
| 67 |
--enable-templates \ |
| 68 |
--with-gnomevfs \ |
| 69 |
--enable-collab-backend-tcp \ |
| 70 |
--enable-collab-backend-xmpp \ |
| 71 |
--enable-collab-backend-sugar \ |
| 72 |
--enable-collab-backend-service \ |
| 73 |
--enable-collab-backend-telepathy \ |
| 74 |
--enable-dependency-tracking \ |
| 75 |
--enable-plugins="$(plugins)" \ |
| 76 |
--enable-introspection |
| 77 |
|
| 78 |
|
| 79 |
override_dh_auto_test: |
| 80 |
|
| 81 |
-dh_auto_test |
| 82 |
|
| 83 |
override_dh_makeshlibs: |
| 84 |
dh_makeshlibs -V |
| 85 |
|
| 86 |
override_dh_strip: |
| 87 |
dh_strip --dbgsym-migration='abiword-dbg (<< 3.0.1-7~)' |
| 88 |
|
| 89 |
override_dh_install: |
| 90 |
find debian/tmp -name '*.la' -print -delete |
| 91 |
dh_install |
| 92 |
|
| 93 |
$(RM) -v debian/abiword/usr/lib/*/abiword-*/plugins/grammar.* |
| 94 |
|
| 95 |
override_dh_missing: |
| 96 |
dh_missing --fail-missing |