安装 GNATCOLL SQL & POSTGRES - Centos 7 Linux,不使用 configure/make

INTSTALLING GNATCOLL SQL & POSTGRES - Centos7 Linux, without using configure/make

到目前为止,我已经下载了 GNAT GPS Community 并将其安装在我的 Linux Centos 7 机器上。

我的objective就是能完成这两个在线例子:

1: http://bisaga.com/blog/programming/ada-database-first-steps/ 2: https://docs.adacore.com/gnatcoll-docs/sql.html

为此,我需要从这里安装 sql 和 postgres 库: https://github.com/AdaCore/gnatcoll-db

我知道 postgres 库依赖于 sql 库,所以我尝试先安装 sql 库!我尝试过以各种方式安装这些库,如果您查看我之前的问题,您就会看到...

我目前正在尝试从 GNAT GPS 构建这些库,请查看下面我的项目的屏幕截图,我在更改的字段旁边包含了白点!

我手动输入了我正在使用的 GNAT GPS 版本,库目录,并为版本添加了 common.

当我尝试构建它时出现以下错误...

我不确定是否可以通过这种方式安装库,如有任何建议,我们将不胜感激。

我想我安装这个库太复杂了。如果有人知道在线提供的分步安装过程,请告诉我。

我也曾尝试使用 gprbuild 构建它,但收到以下错误。

[parallels@localhost sql]$ gprbuild -P gnatcoll_sql.gpr --target=/home/parallels/opt/GNAT/2019/bin
gnatcoll_sql.gpr:44:52: unknown variable "So_Ext"
gnatcoll.gpr:8:06: unknown project file: "directories"
gnatcoll.gpr:8:06: imported by "/usr/share/gpr/gnatcoll.gpr"
gnatcoll.gpr:8:06: imported by "/home/parallels/Desktop/gnatcoll-db-master/sql/gnatcoll_sql.gpr"
gnatcoll.gpr:31:25: unknown package or project "Directories"
gprbuild: "gnatcoll_sql.gpr" processing failed
[parallels@localhost sql]$ 

我用的是LinuxCentos 7,这里安装了GNAT GPS: /home/parallels/opt/GNAT/2019/bin/gps


20 年 4 月 16 日添加

目前,当我 运行 make,然后 make install 我收到错误(这就是我寻找解决方法的原因):

[parallels@localhost sql]$ make
which: no gnatls in (/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin:/var/lib/snapd/snap/bin:/home/parallels/.local/bin:/home/parallels/bin)
gprbuild -p -m --target=executable:gcc  -j0 -XGNATCOLL_VERSION=0.0 -XBUILD=PROD  -XLIBRARY_TYPE=static -XXMLADA_BUILD=static -XGPR_BUILD=static \
    gnatcoll_sql.gpr
gnatcoll_sql.gpr:44:52: unknown variable "So_Ext"
gnatcoll.gpr:8:06: unknown project file: "directories"
gnatcoll.gpr:8:06: imported by "/usr/share/gpr/gnatcoll.gpr"
gnatcoll.gpr:8:06: imported by "/home/parallels/Desktop/gnatcoll-db-master/sql/gnatcoll_sql.gpr"
gnatcoll.gpr:31:25: unknown package or project "Directories"
gprbuild: "gnatcoll_sql.gpr" processing failed
make: *** [build-static] Error 4
[parallels@localhost sql]$ make install
which: no gnatls in (/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin:/var/lib/snapd/snap/bin:/home/parallels/.local/bin:/home/parallels/bin)
gprinstall -p -f --target=x86_64-redhat-linux -XGNATCOLL_VERSION=0.0 -XBUILD=PROD  --sources-subdir=include/gnatcoll_sql --prefix=.. -XLIBRARY_TYPE=static -XXMLADA_BUILD=static -XGPR_BUILD=static \
    --build-name=static --build-var=LIBRARY_TYPE gnatcoll_sql.gpr
make: gprinstall: Command not found
make: *** [install-static] Error 127
[parallels@localhost sql]$ 

添加于 17/04/20 09:00

[parallels@localhost gnatcoll-db]$ echo $PATH
/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin:/var/lib/snapd/snap/bin:/home/parallels/.local/bin:/home/parallels/bin/home/parallels/opt/GNAT/2019/bin
[parallels@localhost gnatcoll-db]$ export PATH=$PATH/home/parallels/opt/GNAT/2019/bin
[parallels@localhost gnatcoll-db]$ echo $PATH
/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin:/var/lib/snapd/snap/bin:/home/parallels/.local/bin:/home/parallels/bin/home/parallels/opt/GNAT/2019/bin/home/parallels/opt/GNAT/2019/bin
[parallels@localhost gnatcoll-db]$ ls
CONTRIBUTING.md  COPYING.RUNTIME  gen_gps_help.py  gnat_debug.adc  postgres   sql     testsuite            xref
COPYING3         docs             gnatcoll_db2ada  gnatinspect     README.md  sqlite  version_information
[parallels@localhost gnatcoll-db]$ make -w -C sql setup
make: Entering directory `/home/parallels/Desktop/gnatcoll-db/sql'
make: Leaving directory `/home/parallels/Desktop/gnatcoll-db/sql'
[parallels@localhost gnatcoll-db]$ make -w -C sql clean build
make: Entering directory `/home/parallels/Desktop/gnatcoll-db/sql'
gprclean -q  -XGNATCOLL_VERSION=0.0 -XBUILD=PROD -XLIBRARY_TYPE=static -XXMLADA_BUILD=static -XGPR_BUILD=static \
    gnatcoll_sql.gpr
gprclean: project file "gnatcoll_sql.gpr" not found in .::/usr/share/gpr:/usr/lib/gnat
make: [clean-static] Error 4 (ignored)
gprclean -q  -XGNATCOLL_VERSION=0.0 -XBUILD=PROD -XLIBRARY_TYPE=relocatable -XXMLADA_BUILD=relocatable -XGPR_BUILD=relocatable \
    gnatcoll_sql.gpr
gprclean: project file "gnatcoll_sql.gpr" not found in .::/usr/share/gpr:/usr/lib/gnat
make: [clean-relocatable] Error 4 (ignored)
gprclean -q  -XGNATCOLL_VERSION=0.0 -XBUILD=PROD -XLIBRARY_TYPE=static-pic -XXMLADA_BUILD=static-pic -XGPR_BUILD=static-pic \
    gnatcoll_sql.gpr
gprclean: project file "gnatcoll_sql.gpr" not found in .::/usr/share/gpr:/usr/lib/gnat
make: [clean-static-pic] Error 4 (ignored)
gprbuild -p -m --target=x86_64-linux  -j0 -XGNATCOLL_VERSION=0.0 -XBUILD=PROD  -XLIBRARY_TYPE=static -XXMLADA_BUILD=static -XGPR_BUILD=static \
    gnatcoll_sql.gpr
gprbuild: project file "gnatcoll_sql.gpr" not found in .::/usr/x86_64-linux/lib/gnat:/usr/share/gpr:/usr/lib/gnat
make: *** [build-static] Error 4
make: Leaving directory `/home/parallels/Desktop/gnatcoll-db/sql'
[parallels@localhost gnatcoll-db]$ 

20 年 4 月 17 日添加10:30


1  [parallels@localhost ~]$ git clone https://github.com/AdaCore/gnatcoll-db
2  Cloning into 'gnatcoll-db'...
3  remote: Enumerating objects: 61, done.
4  remote: Counting objects: 100% (61/61), done.
5  remote: Compressing objects: 100% (61/61), done.
6  remote: Total 17399 (delta 27), reused 34 (delta 0), pack-reused 17338
7  Receiving objects: 100% (17399/17399), 12.63 MiB | 2.21 MiB/s, done.
8  Resolving deltas: 100% (13119/13119), done.
9  [parallels@localhost ~]$ PATH=/opt/GNAT/2019/bin/:$PATH
10 [parallels@localhost ~]$ echo $PATH
11 /opt/GNAT/2019/bin/:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin:/var/lib/snapd/snap/bin:/home/parallels/.local/bin:/home/parallels/bin
12 [parallels@localhost ~]$ cd ~/gnatcoll-db/sql
13 [parallels@localhost sql]$ ls
14 gnatcoll-sql.adb       gnatcoll-sql-exec_private.adb  gnatcoll-sql_fields.adb  gnatcoll-sql_impl.ads     gnatcoll-sql-orm.ads       gnatcoll-sql-sessions.ads
15 gnatcoll-sql.ads       gnatcoll-sql-exec_private.ads  gnatcoll-sql_fields.ads  gnatcoll-sql-inspect.adb  gnatcoll-sql-orm-impl.adb  Makefile
16 gnatcoll-sql-exec.adb  gnatcoll-sql-exec-tasking.adb  gnatcoll_sql.gpr         gnatcoll-sql-inspect.ads  gnatcoll-sql-orm-impl.ads
17 gnatcoll-sql-exec.ads  gnatcoll-sql-exec-tasking.ads  gnatcoll-sql_impl.adb    gnatcoll-sql-orm.adb      gnatcoll-sql-sessions.adb
18 [parallels@localhost sql]$ make
19 gprbuild -p -m --target=x86_64-linux  -j0 -XGNATCOLL_VERSION=0.0 -XBUILD=PROD  -XLIBRARY_TYPE=static -XXMLADA_BUILD=static -XGPR_BUILD=static \
20  gnatcoll_sql.gpr
21 gnatcoll_sql.gpr:44:52: unknown variable "So_Ext"
22 gnatcoll.gpr:8:06: unknown project file: "directories"
23 gnatcoll.gpr:8:06: imported by "/usr/share/gpr/gnatcoll.gpr"
24 gnatcoll.gpr:8:06: imported by "/home/parallels/gnatcoll-db/sql/gnatcoll_sql.gpr"
25 gnatcoll.gpr:31:25: unknown package or project "Directories"
26 gprbuild: "gnatcoll_sql.gpr" processing failed
27 make: *** [build-static] Error 4
28 [parallels@localhost sql]$ gprbuild -p -m --target=x86_64-linux  -j0 -XGNATCOLL_VERSION=0.0 -XBUILD=PROD  -XLIBRARY_TYPE=static -XXMLADA_BUILD=static -XGPR_BUILD=static \
29 >     gnatcoll_sql.gpr
30 gnatcoll_sql.gpr:44:52: unknown variable "So_Ext"
31 gnatcoll.gpr:8:06: unknown project file: "directories"
32 gnatcoll.gpr:8:06: imported by "/usr/share/gpr/gnatcoll.gpr"
33 gnatcoll.gpr:8:06: imported by "/home/parallels/gnatcoll-db/sql/gnatcoll_sql.gpr"
34 gnatcoll.gpr:31:25: unknown package or project "Directories"
35 gprbuild: "gnatcoll_sql.gpr" processing failed
36 [parallels@localhost sql]$ 

添加于 17/04/20 11:15


[parallels@localhost ~]$ git clone https://github.com/AdaCore/gnatcoll-db
Cloning into 'gnatcoll-db'...
remote: Enumerating objects: 61, done.
remote: Counting objects: 100% (61/61), done.
remote: Compressing objects: 100% (61/61), done.
remote: Total 17399 (delta 27), reused 34 (delta 0), pack-reused 17338
Receiving objects: 100% (17399/17399), 12.63 MiB | 3.04 MiB/s, done.
Resolving deltas: 100% (13119/13119), done.
[parallels@localhost ~]$ PATH=/home/parallels/opt/GNAT/2019/bin:$PATH
[parallels@localhost ~]$ echo $path

[parallels@localhost ~]$ echo $PATH
/home/parallels/opt/GNAT/2019/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin:/var/lib/snapd/snap/bin:/home/parallels/.local/bin:/home/parallels/bin
[parallels@localhost ~]$ PATH=/home/parallels/opt/GNAT/2019/bin:$PATH
[parallels@localhost ~]$ 
[parallels@localhost ~]$ cd ~/gnatcoll-db/sql
[parallels@localhost sql]$ ls
gnatcoll-sql.adb               gnatcoll-sql-exec_private.ads  gnatcoll_sql.gpr          gnatcoll-sql-orm.adb       gnatcoll-sql-sessions.ads
gnatcoll-sql.ads               gnatcoll-sql-exec-tasking.adb  gnatcoll-sql_impl.adb     gnatcoll-sql-orm.ads       Makefile
gnatcoll-sql-exec.adb          gnatcoll-sql-exec-tasking.ads  gnatcoll-sql_impl.ads     gnatcoll-sql-orm-impl.adb
gnatcoll-sql-exec.ads          gnatcoll-sql_fields.adb        gnatcoll-sql-inspect.adb  gnatcoll-sql-orm-impl.ads
gnatcoll-sql-exec_private.adb  gnatcoll-sql_fields.ads        gnatcoll-sql-inspect.ads  gnatcoll-sql-sessions.adb
[parallels@localhost sql]$ make
gprbuild -p -m --target=x86_64-linux  -j0 -XGNATCOLL_VERSION=0.0 -XBUILD=PROD  -XLIBRARY_TYPE=static -XXMLADA_BUILD=static -XGPR_BUILD=static \
    gnatcoll_sql.gpr
Setup
   [mkdir]        object directory for project GnatColl_SQL
   [mkdir]        library directory for project GnatColl_SQL
Compile
   [Ada]          gnatcoll-sql_impl.adb
   [Ada]          gnatcoll-sql_fields.adb
   [Ada]          gnatcoll-sql.adb
gnatcoll-sql_impl.adb:30:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql_impl.ads:30:14: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
   [Ada]          gnatcoll-sql-sessions.adb
gnatcoll-sql-sessions.adb:36:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-sessions.adb:37:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql-sessions.ads:34:14: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
gnatcoll-sql-sessions.ads:36:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-sessions.ads:37:14: warning: license of withed unit "GNATCOLL.Pools" may be inconsistent
   [Ada]          gnatcoll-sql-orm.adb
   [Ada]          gnatcoll-sql-orm-impl.adb
   [Ada]          gnatcoll-sql-inspect.adb
gnatcoll-sql.ads:104:14: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
   [Ada]          gnatcoll-sql-exec_private.adb
gnatcoll-sql-exec_private.adb:32:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql-exec_private.ads:32:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
   [Ada]          gnatcoll-sql-exec.adb
gnatcoll-sql-exec.adb:34:17: warning: license of withed unit "GNATCOLL.OS.Constants" may be inconsistent
gnatcoll-sql-exec.adb:35:14: warning: license of withed unit "GNATCOLL.Plugins" may be inconsistent
gnatcoll-sql-exec.adb:36:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-exec.adb:37:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql-exec.ads:110:22: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
gnatcoll-sql-exec.ads:112:14: warning: license of withed unit "GNATCOLL.Plugins" may be inconsistent
gnatcoll-sql-exec.ads:114:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
   [Ada]          gnatcoll-sql-exec-tasking.adb
gnatcoll-sql-exec-tasking.adb:31:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
gnatcoll-sql-exec-tasking.adb:32:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-exec-tasking.adb:33:14: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
gnatcoll-sql-inspect.adb:34:14: warning: license of withed unit "GNATCOLL.Mmap" may be inconsistent
gnatcoll-sql-inspect.adb:35:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-inspect.adb:36:14: warning: license of withed unit "GNATCOLL.VFS" may be inconsistent
gnatcoll-sql-inspect.adb:37:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql-inspect.ads:43:14: warning: license of withed unit "GNATCOLL.VFS" may be inconsistent
gnatcoll-sql-inspect.ads:44:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
gnatcoll-sql-inspect.ads:46:22: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
Build Libraries
   [gprlib]       gnatcoll_sql.lexch
   [archive]      libgnatcoll_sql.a
   [index]        libgnatcoll_sql.a
gprbuild -p -m --target=x86_64-linux  -j0 -XGNATCOLL_VERSION=0.0 -XBUILD=PROD  -XLIBRARY_TYPE=relocatable -XXMLADA_BUILD=relocatable -XGPR_BUILD=relocatable \
    gnatcoll_sql.gpr
Setup
   [mkdir]        object directory for project GnatColl_SQL
   [mkdir]        library directory for project GnatColl_SQL
Compile
   [Ada]          gnatcoll-sql_impl.adb
   [Ada]          gnatcoll-sql_fields.adb
   [Ada]          gnatcoll-sql.adb
gnatcoll-sql_impl.adb:30:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql_impl.ads:30:14: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
   [Ada]          gnatcoll-sql-sessions.adb
gnatcoll-sql-sessions.adb:36:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-sessions.adb:37:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql-sessions.ads:34:14: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
gnatcoll-sql-sessions.ads:36:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-sessions.ads:37:14: warning: license of withed unit "GNATCOLL.Pools" may be inconsistent
   [Ada]          gnatcoll-sql-orm.adb
   [Ada]          gnatcoll-sql-orm-impl.adb
   [Ada]          gnatcoll-sql-inspect.adb
gnatcoll-sql.ads:104:14: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
   [Ada]          gnatcoll-sql-exec_private.adb
gnatcoll-sql-exec_private.adb:32:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql-exec_private.ads:32:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
   [Ada]          gnatcoll-sql-exec.adb
gnatcoll-sql-exec.adb:34:17: warning: license of withed unit "GNATCOLL.OS.Constants" may be inconsistent
gnatcoll-sql-exec.adb:35:14: warning: license of withed unit "GNATCOLL.Plugins" may be inconsistent
gnatcoll-sql-exec.adb:36:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-exec.adb:37:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql-exec.ads:110:22: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
gnatcoll-sql-exec.ads:112:14: warning: license of withed unit "GNATCOLL.Plugins" may be inconsistent
gnatcoll-sql-exec.ads:114:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
   [Ada]          gnatcoll-sql-exec-tasking.adb
gnatcoll-sql-exec-tasking.adb:31:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
gnatcoll-sql-exec-tasking.adb:32:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-exec-tasking.adb:33:14: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
gnatcoll-sql-inspect.adb:34:14: warning: license of withed unit "GNATCOLL.Mmap" may be inconsistent
gnatcoll-sql-inspect.adb:35:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-inspect.adb:36:14: warning: license of withed unit "GNATCOLL.VFS" may be inconsistent
gnatcoll-sql-inspect.adb:37:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql-inspect.ads:43:14: warning: license of withed unit "GNATCOLL.VFS" may be inconsistent
gnatcoll-sql-inspect.ads:44:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
gnatcoll-sql-inspect.ads:46:22: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
Build Libraries
   [gprlib]       gnatcoll_sql.lexch
   [link library] libgnatcoll_sql.so
gprbuild -p -m --target=x86_64-linux  -j0 -XGNATCOLL_VERSION=0.0 -XBUILD=PROD  -XLIBRARY_TYPE=static-pic -XXMLADA_BUILD=static-pic -XGPR_BUILD=static-pic \
    gnatcoll_sql.gpr
Setup
   [mkdir]        object directory for project GnatColl_SQL
   [mkdir]        library directory for project GnatColl_SQL
Compile
   [Ada]          gnatcoll-sql_impl.adb
   [Ada]          gnatcoll-sql_fields.adb
   [Ada]          gnatcoll-sql.adb
gnatcoll-sql_impl.adb:30:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql_impl.ads:30:14: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
   [Ada]          gnatcoll-sql-sessions.adb
gnatcoll-sql-sessions.adb:36:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-sessions.adb:37:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql-sessions.ads:34:14: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
gnatcoll-sql-sessions.ads:36:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-sessions.ads:37:14: warning: license of withed unit "GNATCOLL.Pools" may be inconsistent
   [Ada]          gnatcoll-sql-orm.adb
   [Ada]          gnatcoll-sql-orm-impl.adb
   [Ada]          gnatcoll-sql-inspect.adb
gnatcoll-sql.ads:104:14: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
   [Ada]          gnatcoll-sql-exec_private.adb
gnatcoll-sql-exec_private.adb:32:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql-exec_private.ads:32:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
   [Ada]          gnatcoll-sql-exec.adb
gnatcoll-sql-exec.adb:34:17: warning: license of withed unit "GNATCOLL.OS.Constants" may be inconsistent
gnatcoll-sql-exec.adb:35:14: warning: license of withed unit "GNATCOLL.Plugins" may be inconsistent
gnatcoll-sql-exec.adb:36:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-exec.adb:37:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql-exec.ads:110:22: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
gnatcoll-sql-exec.ads:112:14: warning: license of withed unit "GNATCOLL.Plugins" may be inconsistent
gnatcoll-sql-exec.ads:114:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
   [Ada]          gnatcoll-sql-exec-tasking.adb
gnatcoll-sql-exec-tasking.adb:31:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
gnatcoll-sql-exec-tasking.adb:32:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-exec-tasking.adb:33:14: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
gnatcoll-sql-inspect.adb:34:14: warning: license of withed unit "GNATCOLL.Mmap" may be inconsistent
gnatcoll-sql-inspect.adb:35:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-inspect.adb:36:14: warning: license of withed unit "GNATCOLL.VFS" may be inconsistent
gnatcoll-sql-inspect.adb:37:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql-inspect.ads:43:14: warning: license of withed unit "GNATCOLL.VFS" may be inconsistent
gnatcoll-sql-inspect.ads:44:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
gnatcoll-sql-inspect.ads:46:22: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
Build Libraries
   [gprlib]       gnatcoll_sql.lexch
   [archive]      libgnatcoll_sql.a
   [index]        libgnatcoll_sql.a

这是我的gnatcoll_postgres.gpr构建供参考

[parallels@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
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
gprbuild -p -m --target=x86_64-linux  -j0 -XGNATCOLL_HASPQPREPARE=yes -XGNATCOLL_VERSION=0.0 -XBUILD=PROD  -XLIBRARY_TYPE=static-pic -XXMLADA_BUILD=static-pic -XGPR_BUILD=static-pic \
    gnatcoll_postgres.gpr
Compile
   [Ada]          gnatcoll-sql_impl.adb
   [Ada]          gnatcoll-sql_fields.adb
   [Ada]          gnatcoll-sql.adb
gnatcoll-sql_impl.adb:30:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql_impl.ads:30:14: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
   [Ada]          gnatcoll-sql-sessions.adb
gnatcoll-sql-sessions.adb:36:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-sessions.adb:37:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql-sessions.ads:34:14: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
gnatcoll-sql-sessions.ads:36:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-sessions.ads:37:14: warning: license of withed unit "GNATCOLL.Pools" may be inconsistent
   [Ada]          gnatcoll-sql-orm.adb
   [Ada]          gnatcoll-sql-orm-impl.adb
   [Ada]          gnatcoll-sql-inspect.adb
gnatcoll-sql.ads:104:14: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
   [Ada]          gnatcoll-sql-exec_private.adb
gnatcoll-sql-exec_private.adb:32:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql-exec_private.ads:32:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
   [Ada]          gnatcoll-sql-exec.adb
gnatcoll-sql-exec.adb:34:17: warning: license of withed unit "GNATCOLL.OS.Constants" may be inconsistent
gnatcoll-sql-exec.adb:35:14: warning: license of withed unit "GNATCOLL.Plugins" may be inconsistent
gnatcoll-sql-exec.adb:36:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-exec.adb:37:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql-exec.ads:110:22: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
gnatcoll-sql-exec.ads:112:14: warning: license of withed unit "GNATCOLL.Plugins" may be inconsistent
gnatcoll-sql-exec.ads:114:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
   [Ada]          gnatcoll-sql-exec-tasking.adb
gnatcoll-sql-exec-tasking.adb:31:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
gnatcoll-sql-exec-tasking.adb:32:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-exec-tasking.adb:33:14: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
   [C]            postgres_support.c
   [Ada]          gnatcoll-sql-ranges.adb
   [Ada]          gnatcoll-sql-postgres.adb
gnatcoll-sql-inspect.adb:34:14: warning: license of withed unit "GNATCOLL.Mmap" may be inconsistent
gnatcoll-sql-inspect.adb:35:14: warning: license of withed unit "GNATCOLL.Traces" may be inconsistent
gnatcoll-sql-inspect.adb:36:14: warning: license of withed unit "GNATCOLL.VFS" may be inconsistent
gnatcoll-sql-inspect.adb:37:14: warning: license of withed unit "GNATCOLL.Utils" may be inconsistent
gnatcoll-sql-inspect.ads:43:14: warning: license of withed unit "GNATCOLL.VFS" may be inconsistent
gnatcoll-sql-inspect.ads:44:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
gnatcoll-sql-inspect.ads:46:22: warning: license of withed unit "GNATCOLL.Refcount" may be inconsistent
   [Ada]          gnatcoll-sql-postgres-gnade.adb
gnatcoll-sql-postgres-gnade.ads:43:14: warning: license of withed unit "GNATCOLL.Strings" may be inconsistent
   [Ada]          gnatcoll-sql-postgres-builder.adb
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_sql.lexch
   [archive]      libgnatcoll_sql.a
   [index]        libgnatcoll_sql.a
   [gprlib]       gnatcoll_postgres.lexch
   [archive]      libgnatcoll_postgres.a
   [index]        libgnatcoll_postgres.a
[parallels@localhost postgres]$ 

您仍然有 PATH 问题。

[parallels@localhost sql]$ make
which: no gnatls in (/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin:/var/lib/snapd/snap/bin:/home/parallels/.local/bin:/home/parallels/bin)
...
which: no gnatls in (/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin:/var/lib/snapd/snap/bin:/home/parallels/.local/bin:/home/parallels/bin)
...
make: gprinstall: Command not found

This 是我用于构建 macOS 的脚本。更改为更通用,并且已设置您的 PATH 以使其包含 GNAT(即命令 gnatls -v 有效),运行 来自 gnatcoll-db/ :

make -w -C sql setup
make -w -C sql clean build
make -w -C sql install

make -w -C postgres setup
make -w -C postgres clean build
make -w -C postgres install

听起来好像您对命令行的经验不多。 this tutorial 之类的内容可能会有所帮助。

以下允许 gnatcoll-db 在 GNAT Community 2019 下构建。

克隆存储库:

$ git clone https://github.com/AdaCore/gnatcoll-db

将路径添加到 GNAT Community 2019(这是一个快速的技巧,只是添加到路径的开头,因为安装了多个编译器):

$ PATH=/opt/GNAT/2019/bin/:$PATH

使用默认设置构建:

$ cd ~/gnatcoll-db/sql
$ make
gprbuild -p -m --target=x86_64-linux  -j0 -XGNATCOLL_VERSION=0.0 -XBUILD=PROD  -XLIBRARY_TYPE=static -XXMLADA_BUILD=static -XGPR_BUILD=static \
    gnatcoll_sql.gpr
Setup
   [mkdir]        object directory for project GnatColl_SQL
   [mkdir]        library directory for project GnatColl_SQL
Compile
<snip>
Build Libraries
   [gprlib]       gnatcoll_sql.lexch
   [archive]      libgnatcoll_sql.a
   [index]        libgnatcoll_sql.a