| 1 |
#!/usr/bin/make -f |
| 2 |
|
| 3 |
include /usr/share/dpkg/buildflags.mk |
| 4 |
include /usr/share/dpkg/architecture.mk |
| 5 |
|
| 6 |
export LDFLAGS += -Wl,--as-needed -Wl,-z,defs |
| 7 |
|
| 8 |
GEANY_VERSION = $(shell pkg-config --modversion geany) |
| 9 |
|
| 10 |
override_dh_autoreconf: |
| 11 |
rm -rf build/cache |
| 12 |
dh_autoreconf --as-needed |
| 13 |
|
| 14 |
# specify libexecdir to avoid cascading geany-plugins directories in /usr/lib |
| 15 |
override_dh_auto_configure: |
| 16 |
dh_auto_configure -- \ |
| 17 |
--libexecdir='$${exec_prefix}/lib' \ |
| 18 |
--enable-largefile \ |
| 19 |
--enable-addons \ |
| 20 |
--enable-autoclose \ |
| 21 |
--enable-automark \ |
| 22 |
--enable-codenav \ |
| 23 |
--enable-commander \ |
| 24 |
--enable-debugger \ |
| 25 |
--enable-defineformat \ |
| 26 |
--enable-geanyctags \ |
| 27 |
--enable-geanydoc \ |
| 28 |
--enable-geanyextrasel \ |
| 29 |
--enable-geanygendoc \ |
| 30 |
--enable-geanyinsertnum \ |
| 31 |
--enable-geanylua \ |
| 32 |
--enable-geanymacro \ |
| 33 |
--enable-geanyminiscript \ |
| 34 |
--enable-geanynumberedbookmarks \ |
| 35 |
--enable-geanypg \ |
| 36 |
--enable-geanyprj \ |
| 37 |
--enable-geanyvc \ |
| 38 |
--enable-geniuspaste \ |
| 39 |
--enable-gitchangebar \ |
| 40 |
--enable-keyrecord \ |
| 41 |
--enable-latex \ |
| 42 |
--enable-lineoperations \ |
| 43 |
--enable-lipsum \ |
| 44 |
--enable-lsp \ |
| 45 |
--enable-system-jsonrpc \ |
| 46 |
--enable-markdown \ |
| 47 |
--enable-overview \ |
| 48 |
--enable-pairtaghighlighter \ |
| 49 |
--enable-pohelper \ |
| 50 |
--enable-pretty-printer \ |
| 51 |
--enable-projectorganizer \ |
| 52 |
--enable-scope \ |
| 53 |
--enable-sendmail \ |
| 54 |
--enable-shiftcolumn \ |
| 55 |
--enable-spellcheck \ |
| 56 |
--enable-tableconvert \ |
| 57 |
--enable-treebrowser \ |
| 58 |
--enable-updatechecker \ |
| 59 |
--enable-vimode \ |
| 60 |
--enable-webhelper \ |
| 61 |
--enable-workbench \ |
| 62 |
--enable-xmlsnippets |
| 63 |
|
| 64 |
# install separate ChangeLogs for each different plugin |
| 65 |
override_dh_installchangelogs: |
| 66 |
for changelog in */ChangeLog; do \ |
| 67 |
[ ! -s $$changelog ] && continue; \ |
| 68 |
if [ $$changelog = po/ChangeLog ]; then \ |
| 69 |
pkg=geany-plugins-common; \ |
| 70 |
else \ |
| 71 |
pkg=geany-plugin-$$(dirname $$changelog | sed -e's/^geany//'); \ |
| 72 |
fi; \ |
| 73 |
dh_installchangelogs \ |
| 74 |
-p$$pkg \ |
| 75 |
$$changelog; \ |
| 76 |
done |
| 77 |
dh_installchangelogs |
| 78 |
|
| 79 |
# add geany:Version substvar to debian/*.substvars |
| 80 |
override_dh_gencontrol: |
| 81 |
. /usr/lib/$(DEB_HOST_MULTIARCH)/geany/debian-abi-helper && \ |
| 82 |
dh_gencontrol -- \ |
| 83 |
"-Vgeany:Version=$(GEANY_VERSION)" \ |
| 84 |
"-Vgeany:API=$${GEANY_ABI}" \ |
| 85 |
"-Vgeany:ABI=$${GEANY_ABI}" |
| 86 |
|
| 87 |
# Don't make shlibs (false positive on pretty-printer.so |
| 88 |
override_dh_makeshlibs: |
| 89 |
dh_makeshlibs -n -p geany-plugins-common -V |
| 90 |
|
| 91 |
override_dh_install: |
| 92 |
find debian/tmp/ -name '*.pyc' -delete |
| 93 |
dh_install |
| 94 |
|
| 95 |
execute_after_dh_installdocs-arch: |
| 96 |
cd $(CURDIR)/debian/geany-plugin-latex/usr/share/doc/geany-plugin-latex/ && \ |
| 97 |
ls -1 *.html | \ |
| 98 |
while read -r file; do \ |
| 99 |
iconv --from=iso-8859-1 --to=utf-8 "$$file" | \ |
| 100 |
sponge "$$file"; \ |
| 101 |
done |
| 102 |
|
| 103 |
override_dh_missing: |
| 104 |
dh_missing --fail-missing -Xusr/share/doc/geany-plugins/ -X.la |
| 105 |
|
| 106 |
%: |
| 107 |
dh $@ --with=autoreconf |