Closed GrzegorzWalewski closed 3 years ago
Hi @GrzegorzWalewski,
It would be good if you share below additional information to troubleshoot this issue further:
1: Exact OS version 2: Exact postgres version 3: Have you added pg_config executable in your path variable? 4: How you have installed the postgres? using RPM or source code? If RPM then confirm if you have installed postgresqlXX-devel package which contains header files and libraries. 5: Output of below queries. find / -name "postgres.h" -print pg_config --includedir-server
find / -name "postgres.h" -print
/home/linuxbrew/.linuxbrew/Cellar/postgresql/12.4/include/postgresql/server/postgres.h
/usr/include/postgresql/9.6/server/postgres.h
pg_config --includedir-server
/usr/include/postgresql/12/server
Thanks for providing information.
As per your last update, you are compiling mysql_fdw sources against v10.15, but "pg_config --includedir-server" shows the directory path for v12. I think you need to add the pg_config binary of v10 in your PATH then make sure that you have installed the "postgresql10-devel" package at your end. I guess "postgresql10-devel" is not present at your end as I don't see "postgres.h" under postgres 10 installation directory.
What I did is:
dpkg -l | grep postgres
Uninstall: sudo apt --purge remove [version-name]
And install:
sudo apt-get install postgresql-10
sudo apt install postgresql-server-dev-10
And now it worked :D
Thanks for Your help <3
Hi! I was trying to run sudo make USE_PGXS=1, and run into issue:
connection.c:15:10: fatal error: postgres.h: No such file or directory 15 | #include "postgres.h" | ^~~~~~~~~~~~ compilation terminated. make: *** [<builtin>: connection.o] Error 1
This problem occurs at my both computers. I was trying to fix, but everything seems to be good. Please help