On Mon, 23 Nov 2026 22:12, Rene Engelhard <[email protected]> wrote:
Hi,

Am 23.11.26 um 21:37 schrieb Matthias Geiger:
> as the current packaging prevents from adding a new dict-opemthesaurus
package.


How?

Neither the old rules nor the old dh compat should prevent doing so if you do necessary adaptions.


I just found it cleaner to work on it that way. Attached is a patch that greatly reduces d/rules, and converts the package to DH 14 with .install and .links files.

best,

--

Matthias Geiger <werdahias>

Debian Developer -- KiCad Contributor
GPG: ECBEDBB607B9B2BE
From 280e573352b5b8531c0e0ceea572da1e20063504 Mon Sep 17 00:00:00 2001
From: Matthias Geiger <[email protected]>
Date: Tue, 24 Nov 2026 14:57:14 +0100
Subject: [PATCH] Modernize packaging (Closes: #1155069)

    - Switch to DH 14
    - d/rules: Use standard dh sequence
    - Use install files and links for package content

Gpb-Dch: Full
---
 debian/compat                        |  1 -
 debian/control                       |  7 +--
 debian/mythes-de-ch.install          |  2 +
 debian/mythes-de-ch.links            |  2 +
 debian/mythes-de.install             |  2 +
 debian/mythes-de.links               |  2 +
 debian/openthesaurus-de-text.install |  1 +
 debian/openthesaurus-de-text.links   |  1 +
 debian/rules                         | 91 ++--------------------------
 9 files changed, 17 insertions(+), 92 deletions(-)
 delete mode 100644 debian/compat
 create mode 100644 debian/mythes-de-ch.install
 create mode 100644 debian/mythes-de-ch.links
 create mode 100644 debian/mythes-de.install
 create mode 100644 debian/mythes-de.links
 create mode 100644 debian/openthesaurus-de-text.install
 create mode 100644 debian/openthesaurus-de-text.links

diff --git a/debian/compat b/debian/compat
deleted file mode 100644
index ec63514..0000000
--- a/debian/compat
+++ /dev/null
@@ -1 +0,0 @@
-9
diff --git a/debian/control b/debian/control
index 2b40b28..e351595 100644
--- a/debian/control
+++ b/debian/control
@@ -2,13 +2,12 @@ Source: openthesaurus
 Section: text
 Priority: optional
 Maintainer: Rene Engelhard <[email protected]>
-Build-Depends-Indep: dpkg-dev (>= 1.10.11), unzip, libmythes-dev
-Build-Depends: debhelper (>= 9.0.0)
+Build-Depends-Indep: unzip, libmythes-dev
+Build-Depends: debhelper-compat (= 14)
 Standards-Version: 3.7.2
 
 Package: openthesaurus-de-text
 Architecture: all
-Depends: ${misc:Depends}
 Recommends: ding
 Description: German Text Thesaurus for e.g. ding
  This package contains the German OpenThesaurus (www.openthesaurus.de) thesaurus
@@ -16,7 +15,6 @@ Description: German Text Thesaurus for e.g. ding
 
 Package: mythes-de
 Architecture: all
-Depends: ${misc:Depends}
 Suggests: libreoffice-core
 Provides: mythes-thesaurus, mythes-thesaurus-de, openoffice.org-thesaurus-de
 Replaces: openoffice.org-thesaurus-de
@@ -27,7 +25,6 @@ Description: German Thesaurus for OpenOffice.org/LibreOffice
 
 Package: mythes-de-ch
 Architecture: all
-Depends: ${misc:Depends}
 Suggests: libreoffice-core
 Provides: mythes-thesaurus, mythes-thesaurus-de, openoffice.org-thesaurus-de-ch
 Replaces: openoffice.org-thesaurus-de-ch
diff --git a/debian/mythes-de-ch.install b/debian/mythes-de-ch.install
new file mode 100644
index 0000000..1af6ece
--- /dev/null
+++ b/debian/mythes-de-ch.install
@@ -0,0 +1,2 @@
+th_de_CH_v2.idx usr/share/myspell/dicts
+th_de_CH_v2.dat usr/share/myspell/dicts
diff --git a/debian/mythes-de-ch.links b/debian/mythes-de-ch.links
new file mode 100644
index 0000000..86ffdf8
--- /dev/null
+++ b/debian/mythes-de-ch.links
@@ -0,0 +1,2 @@
+/usr/share/mythes/th_de_CH_v2.dat  /usr/share/myspell/dicts/th_de_CH_v2.dat
+/usr/share/mythes/th_de_CH_v2.idx  /usr/share/myspell/dicts/th_de_CH_v2.idx
diff --git a/debian/mythes-de.install b/debian/mythes-de.install
new file mode 100644
index 0000000..1304d2f
--- /dev/null
+++ b/debian/mythes-de.install
@@ -0,0 +1,2 @@
+th_de_DE_v2.dat usr/share/mythes
+th_de_DE_v2.idx usr/share/mythes
diff --git a/debian/mythes-de.links b/debian/mythes-de.links
new file mode 100644
index 0000000..5d06603
--- /dev/null
+++ b/debian/mythes-de.links
@@ -0,0 +1,2 @@
+/usr/share/mythes/th_de_DE_v2.dat  /usr/share/myspell/dicts/th_de_DE_v2.dat
+/usr/share/mythes/th_de_DE_v2.idx  /usr/share/myspell/dicts/th_de_DE_v2.idx
diff --git a/debian/openthesaurus-de-text.install b/debian/openthesaurus-de-text.install
new file mode 100644
index 0000000..dd1aa2d
--- /dev/null
+++ b/debian/openthesaurus-de-text.install
@@ -0,0 +1 @@
+openthesaurus.txt usr/share/openthesaurus-de
diff --git a/debian/openthesaurus-de-text.links b/debian/openthesaurus-de-text.links
new file mode 100644
index 0000000..6e7c642
--- /dev/null
+++ b/debian/openthesaurus-de-text.links
@@ -0,0 +1 @@
+/usr/share/openthesaurus-de/openthesaurus.txt /usr/share/openthesaurus-de/thesaurus.txt
diff --git a/debian/rules b/debian/rules
index 529ef35..d687dcc 100755
--- a/debian/rules
+++ b/debian/rules
@@ -1,101 +1,20 @@
 #!/usr/bin/make -f
 
-#export DH_VERBOSE=1
+%:
+	dh $@
 
-# This has to be exported to make some magic below work.
-export DH_OPTIONS
 
-configure: configure-stamp
-configure-stamp:
-	dh_testdir
-	touch configure-stamp
-
-build: build-arch build-indep
-
-build-arch: build-arch-stamp
-build-arch-stamp: configure-stamp 
-
-	touch build-arch-stamp
-
-build-indep: build-indep-stamp
-build-indep-stamp: configure-stamp 
+override_dh_auto_build:
 	TZ=UTC unzip -o Deutscher-Thesaurus.oxt && \
 		/usr/share/mythes/th_gen_idx.pl -o th_de_DE_v2.idx \
 			< th_de_DE_v2.dat && \
 		LANG=C cat th_de_DE_v2.dat | sed -e 's/ß/ss/g' > th_de_CH_v2.dat; \
 		/usr/share/mythes/th_gen_idx.pl -o th_de_CH_v2.idx \
 			< th_de_CH_v2.dat
+	TZ=UTC unzip $(CURDIR)/OpenThesaurus-Textversion.zip openthesaurus.txt
 
-	touch build-indep-stamp
-
-clean:
-	dh_testdir
-	dh_testroot
-	rm -f build-arch-stamp build-indep-stamp configure-stamp
+override_dh_clean:
 	rm -f *.dat *.idx
 	rm -f README.txt description.xml Dictionaries.xcu
 	rm -rf META-INF
-
 	dh_clean 
-
-install: install-indep install-arch
-install-indep:
-	dh_testdir
-	dh_testroot
-	dh_prep -i 
-	dh_installdirs -i
-
-	# for the symlinks
-	mkdir -p $(CURDIR)/debian/mythes-de/usr/share/myspell/dicts/
-	mkdir -p $(CURDIR)/debian/mythes-de-ch/usr/share/myspell/dicts/
-
-	mkdir -p $(CURDIR)/debian/openthesaurus-de-text/usr/share/openthesaurus-de/
-	cd $(CURDIR)/debian/openthesaurus-de-text/usr/share/openthesaurus-de && \
-	TZ=UTC unzip $(CURDIR)/OpenThesaurus-Textversion.zip openthesaurus.txt && \
-		ln -sf openthesaurus.txt thesaurus.txt
-
-	install -D -m644 th_de_DE_v2.dat \
-		$(CURDIR)/debian/mythes-de/usr/share/mythes/th_de_DE_v2.dat
-	install -D -m644 th_de_DE_v2.idx \
-		$(CURDIR)/debian/mythes-de/usr/share/mythes/th_de_DE_v2.idx
-	ln -s /usr/share/mythes/th_de_DE_v2.dat \
-		$(CURDIR)/debian/mythes-de/usr/share/myspell/dicts/th_de_DE_v2.dat
-	ln -s /usr/share/mythes/th_de_DE_v2.idx \
-		$(CURDIR)/debian/mythes-de/usr/share/myspell/dicts/th_de_DE_v2.idx
-	install -D -m644 th_de_CH_v2.dat \
-		$(CURDIR)/debian/mythes-de-ch/usr/share/mythes/th_de_CH_v2.dat
-	install -D -m644 th_de_CH_v2.idx \
-		$(CURDIR)/debian/mythes-de-ch/usr/share/mythes/th_de_CH_v2.idx
-	ln -s /usr/share/mythes/th_de_CH_v2.dat \
-		$(CURDIR)/debian/mythes-de-ch/usr/share/myspell/dicts/th_de_CH_v2.dat
-	ln -s /usr/share/mythes/th_de_CH_v2.idx \
-		$(CURDIR)/debian/mythes-de-ch/usr/share/myspell/dicts/th_de_CH_v2.idx
-
-install-arch:
-
-# Must not depend on anything. This is to be called by
-# binary-arch/binary-indep
-# in another 'make' thread.
-binary-common:
-	dh_testdir
-	dh_testroot
-	dh_installchangelogs
-	dh_installdocs
-	dh_installexamples
-	dh_installdebconf	
-	dh_link
-	dh_compress 
-	dh_fixperms
-	dh_installdeb
-	unset DH_OPTIONS; dh_gencontrol
-	dh_md5sums
-	dh_builddeb
-
-binary-indep: build-indep install-indep
-	$(MAKE) -f debian/rules DH_OPTIONS=-i binary-common
-
-binary-arch: build-arch install-arch
-	#$(MAKE) -f debian/rules DH_OPTIONS=-a binary-common
-
-binary: binary-arch binary-indep
-.PHONY: build clean binary-indep binary-arch binary install install-indep install-arch configure
-- 
2.55.0

Reply via email to