Skip to content
Advertisement

Adacore GNATCOLL Postgres library not installing on CentOS 8

I posted a question a couple of days ago regarding installing the GNATCOLL library on CentOS 8, which was kindly answered.

I have now attempted to install the gnatcoll postgres library, which I was hoping would be the same process. However, when I attempt this, I receive the following error:

[lloyd@localhost gnatcoll-db-20.0]$ cd postgres
[lloyd@localhost postgres]$ ls
gnatcoll_postgres.gpr              gnatcoll-sql-ranges.ads
gnatcoll-sql-postgres.adb          lib
gnatcoll-sql-postgres.ads          Makefile
gnatcoll-sql-postgres-builder.adb  makefile.setup
gnatcoll-sql-postgres-builder.ads  obj
gnatcoll-sql-postgres-gnade.adb    postgres_support.c
gnatcoll-sql-postgres-gnade.ads    README.md
gnatcoll-sql-ranges.adb
[lloyd@localhost postgres]$ make setup
[lloyd@localhost postgres]$ make
gprbuild -p -m --target=x86_64-linux  -j0 -XGNATCOLL_HASPQPREPARE=yes -XGNATCOLL_VERSION=0.0 -XBUILD=PROD  -XLIBRARY_TYPE=static -XXMLADA_BUILD=static -XGPR_BUILD=static 
    gnatcoll_postgres.gpr
Compile
   [C]            postgres_support.c
   [Ada]          gnatcoll-sql-ranges.adb
   [Ada]          gnatcoll-sql-postgres.adb
   [Ada]          gnatcoll-sql-postgres-gnade.adb
   [Ada]          gnatcoll-sql-postgres-builder.adb
gnatcoll-sql-postgres-gnade.ads:43:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
gnatcoll-sql-postgres-builder.adb:37:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
gnatcoll-sql-postgres-builder.adb:38:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-postgres-builder.adb:39:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql-postgres.adb:30:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql-postgres.ads:29:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
Build Libraries
   [gprlib]       gnatcoll_postgres.lexch
   [archive]      libgnatcoll_postgres.a
   [index]        libgnatcoll_postgres.a
gprbuild -p -m --target=x86_64-linux  -j0 -XGNATCOLL_HASPQPREPARE=yes -XGNATCOLL_VERSION=0.0 -XBUILD=PROD  -XLIBRARY_TYPE=relocatable -XXMLADA_BUILD=relocatable -XGPR_BUILD=relocatable 
    gnatcoll_postgres.gpr
Setup
   [mkdir]        object directory for project GnatColl_Postgres
   [mkdir]        library directory for project GnatColl_Postgres
Compile
   [C]            postgres_support.c
   [Ada]          gnatcoll-sql-ranges.adb
   [Ada]          gnatcoll-sql-postgres.adb
gnatcoll-sql-postgres.adb:30:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql-postgres.ads:29:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
   [Ada]          gnatcoll-sql-postgres-builder.adb
   [Ada]          gnatcoll-sql-postgres-gnade.adb
gnatcoll-sql-postgres-gnade.ads:43:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
gnatcoll-sql-postgres-builder.adb:37:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
gnatcoll-sql-postgres-builder.adb:38:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-postgres-builder.adb:39:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
Build Libraries
   [gprlib]       gnatcoll_postgres.lexch
   [bind SAL]     gnatcoll_postgres
   [Ada]          b__gnatcoll_postgres.adb
   [link library] libgnatcoll_postgres.so
/home/lloyd/opt/GNAT/2019/bin/../libexec/gcc/x86_64-pc-linux-gnu/8.3.1/ld: cannot find -lpq
collect2: error: ld returned 1 exit status
gprlib: /home/lloyd/opt/GNAT/2019/bin/gcc execution error
gprbuild: could not build library for project gnatcoll_postgres
make: *** [Makefile:123: build-relocatable] Error 4

Any help as to why this is happening would be greatly appreciated.

Thanks, Lloyd

Advertisement

Answer

If you’re on Centos 8 a simple

sudo yum -y install libpq-devel

will set you up.

User contributions licensed under: CC BY-SA
10 People found this is helpful
Advertisement