diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 16:02:19 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 16:02:19 +0000 |
commit | 670c19c1ec189d5831be4a4c09099036da4635ad (patch) | |
tree | 9e929200d3abb9b52d685695db2a72e02718b243 /debian/rules | |
parent | Adding upstream version 248. (diff) | |
download | postgresql-common-670c19c1ec189d5831be4a4c09099036da4635ad.tar.xz postgresql-common-670c19c1ec189d5831be4a4c09099036da4635ad.zip |
Adding debian version 248.debian/248debian
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'debian/rules')
-rwxr-xr-x | debian/rules | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/debian/rules b/debian/rules new file mode 100755 index 0000000..0b7f015 --- /dev/null +++ b/debian/rules @@ -0,0 +1,43 @@ +#!/usr/bin/make -f + +include /usr/share/dpkg/pkg-info.mk + +ifneq ($(findstring bpo,$(DEB_VERSION)),) + FLAVOR := debian-backports +else ifneq ($(findstring pgdg,$(DEB_VERSION)),) + FLAVOR := pgdg +else + FLAVOR := default +endif +SUPPORTED_VERSIONS := $(shell PG_SUPPORTED_VERSIONS="$(FLAVOR)" debian/supported-versions) +DEFAULT_VER := $(lastword $(SUPPORTED_VERSIONS)) + +#py2#PYTHON2_PACKAGE=postgresql-plpython-$v + +%: + dh $@ + +override_dh_auto_configure: + @echo "### Building postgresql-common flavor $(FLAVOR)" + @echo "### Supported PostgreSQL versions: $(SUPPORTED_VERSIONS) (default version: $(DEFAULT_VER))" + echo "# See /usr/share/postgresql-common/supported-versions for documentation of this file" > supported_versions + echo "$(FLAVOR)" >> supported_versions + +# do not restart postgresql.service on postgresql-common upgrades +override_dh_installinit: + dh_installinit -ppostgresql-common --name=postgresql -u'defaults 19 21' --no-stop-on-upgrade +override_dh_installsystemd: + dh_installsystemd --no-stop-on-upgrade + +override_dh_gencontrol: + dh_gencontrol -ppostgresql-server-dev-all -- -Vserver-dev-all-depends="$(foreach v,$(SUPPORTED_VERSIONS),postgresql-server-dev-$v,)" + + # the versionless metapackages need to have version numbers which match + # the server version, not the p-common version + dh_gencontrol -ppostgresql -ppostgresql-client -ppostgresql-doc -ppostgresql-contrib -- \ + -Vdefault-version="$(DEFAULT_VER)" -v'$(DEFAULT_VER)+$${source:Version}' + + dh_gencontrol -ppostgresql-all -- \ + -Vpostgresql-all-depends="$(foreach v,$(SUPPORTED_VERSIONS),postgresql-contrib-$v,postgresql-plperl-$v,$(if $(filter 8.% 9.% 10 11, $v), $(PYTHON2_PACKAGE)),postgresql-plpython3-$v,postgresql-pltcl-$v,)" + + dh_gencontrol --remaining-packages |