Skip to content
This repository was archived by the owner on Jul 14, 2022. It is now read-only.

build problems when multiple postgresql versions are installed #58

@anneb

Description

@anneb

When multiple postgresql versions are installed, it seems you can only build for the newest version.
Did I overlook something obvious?

I found the following last/newest(?) installed postgresql version dependent settings:

files:
debian/rules:

  PGVERSION=`pg_buildext supported-versions $(CURDIR) | tail -l` || exit $$?;

Makefile:

  EXTDIR=$(shell pg_config --sharedir)

icutranslit/Makefile
pg_config is used twice (always linked to newest or last installed version?)

kanjitranscript/Makefile
pg_config is used twice

I was able to build for other versions as follows:
file debian/pgversions
replace 9.6+ by version number you wish to build for, example: 12

file Makefile:

PGVERSION=12
PG_CONFIG=/usr/lib/postgresql/$(PGVERSION)/bin/pg_config
EXTDIR=$(shell $(PG_CONFIG) --sharedir)

file icutranslit/Makefile

PGVERSION=12
PG_CONFIG=/usr/lib/postgresql/$(PGVERSION)/bin/pg_config
PGPATH=$(shell $(PG_CONFIG) --includedir-server)
...
install -D -m 644 osml10n_translit.so $(DESTDIR)$(shell $(PG_CONFIG) --pkglibdir)/osml10n_translit.so

file kanjitranscript/Makefile

PGVERSION=12
PG_CONFIG=/usr/lib/postgresql/$(PGVERSION)/bin/pg_config
PGPATH=$(shell $(PG_CONFIG) --includedir-server)
..
install -D -m 644 osml10n_kanjitranscript.so $(DESTDIR)$(shell $(PG_CONFIG) --pkglibdir)/osml10n_kanjitranscript.so

now I was able to override the postgres version number as follows:

  1. update the version number in debian/pgversions to XX
  2. make PGVERSION=XX deb
    where XX is the version number you want to build for.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions