Re: ICU is not supported in this build. install from source code. - Mailing list pgsql-general

From Daniel Verite
Subject Re: ICU is not supported in this build. install from source code.
Date
Msg-id d31acd96-fb64-48d1-90bd-89770d485ae7@manitou-mail.org
Whole thread Raw
In response to Re: ICU is not supported in this build. install from source code.  (jian he <jian.universality@gmail.com>)
List pgsql-general
    jian he wrote:

> ./configure --with-perl --with-python  --with-icu
> ICU_CFLAGS='-I/usr/include/unicode'  ICU_LIBS='-L/usr/lib/icu'
> --enable-debug --with-pgport=5440

The location with -L is not sufficient in ICU_LIBS.
The list of libraries to link with should be put as well.
For instance:
ICU_LIBS="-L/usr/lib/icu -licui18n -licuuc -licudata"

When using the version of ICU that ships with the distribution (libicu-dev
package on Ubuntu), adding only "--with-icu" should be enough.
The locations of includes and libraries will be automatically found.
I'm not sure that's your case though. On one hand, /usr/include/unicode is
where the package puts the ICU includes, but on the other hand
it doesn't create any /usr/lib/icu directory.
And Ubuntu 22.04 LTS brings ICU 70, not ICU 71.

If you need a self-built version of ICU, it might be simpler to use pkgconfig
as an alternative to ICU_CFLAGS/ICU_LIBS, for instance:

./configure --with-icu PKG_CONFIG_PATH=/path/to/icu/lib/pkgconfig

where /path/to/icu was passed as the prefix to ICU4C configure
invocation. It's recommended to install custom builds to specific
locations instead of overwriting the libraries that are part of
the distribution (otherwise it becomes unmaintainable)


Best regards,
--
Daniel Vérité
https://postgresql.verite.pro/
Twitter: @DanielVerite



pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: "Missing" column in Postgres logical replication update message
Next
From: Kevin Martin
Date:
Subject: Re: "Missing" column in Postgres logical replication update message