我正在运行具有受限sudo
访问权限的Red Hat 6.6 Linux的计算集群上生成构建脚本。目前,我已经从GitHub上的源创建本地安装的PostgreSQL 10.10。在构建之后,将它们安装在/storage/home/work/build_env/postgres
上,并且$PATH
被更新,以便pg_config
运行并pkg-config libpq --cflags
返回
-I/storage/home/work/build_env/postgres/include
libpqxx已从GitHub源中克隆,但由于以下错误而被卡在配置中:
configure: using PostgreSQL headers at /storage/home/work/build_env/postgres/include configure: using PostgreSQL libraries at /storage/home/work/build_env/postgres/lib checking /storage/home/work/build_env/postgres/include /libpq-fe.h usability... no checking /storage/home/work/build_env/postgres/include /libpq-fe.h presence... no checking for /storage/home/work/build_env/postgres/include /libpq-fe.h... no configure: error: Can't find libpq-fe.h in /storage/home/work/build_env/postgres/include . Are you sure the libpq headers are installed correctly? They should be in the directory returned by "pg_config --includedir" or "pkg-config libpq --cflags". If you do have libpq (the C-language client library for PostgreSQL) installed,make sure you have the related development materials--mainly its header files-- as well as the library binary. Some system distributions keep the two in seperate packages with names like "alibrary" and "alibrary-dev",respectively. In that case,make sure you have the latter installed as well.
但是,在pkg-config
返回的目录中,我看到以下内容:
[user@compute libpqxx]$ ls -al /storage/home/work/build_env/postgres/include | grep libpq drwxrws--- 2 user user_collab 4096 Nov 7 13:35 libpq -rw-r--r-- 1 user user_collab 2211 Nov 7 13:35 libpq-events.h -rw-r--r-- 1 user user_collab 22179 Nov 7 13:35 libpq-fe.h
是什么原因导致配置脚本找不到文件的问题?