go-libpq icon indicating copy to clipboard operation
go-libpq copied to clipboard

libpq-fe.h: No such file or directory

Open goris opened this issue 9 years ago • 2 comments

go get github.com/jgallagher/go-libpq

github.com/jgallagher/go-libpq

../../../github.com/jgallagher/go-libpq/driver.go:5:22: fatal error: libpq-fe.h: No such file or directory #include <libpq-fe.h> ^ compilation terminated.

goris avatar Aug 02 '15 07:08 goris

There's currently three places where libpq-fe.h is needed. On debian system for one example after installing libpq-dev, the header file is in /usr/include/postgresql/libpq-fe.h. So you must change the: #include <libpq-fe.h> to: #include <postgresql/libpq-fe.h> in every of the go files.

rabbitear avatar May 06 '16 19:05 rabbitear

Hello I have a problem with this gem ::: please help

this is the terminal report:::

gem install pg -v '0.20.0' --source 'https://rubygems.org/' Building native extensions. This could take a while... ERROR: Error installing pg: ERROR: Failed to build gem native extension.

current directory: /Users/nutriente/.rvm/gems/ruby-2.6.3/gems/pg-0.20.0/ext

/Users/nutriente/.rvm/rubies/ruby-2.6.3/bin/ruby -I /Users/nutriente/.rvm/rubies/ruby-2.6.3/lib/ruby/2.6.0 -r ./siteconf20190703-2317-1oappj4.rb extconf.rb checking for pg_config... no No pg_config... trying anyway. If building fails, please try again with --with-pg-config=/path/to/pg_config checking for libpq-fe.h... no Can't find the 'libpq-fe.h header *** extconf.rb failed *** Could not create Makefile due to some reason, probably lack of necessary libraries and/or headers. Check the mkmf.log file for more details. You may need configuration options.

iodaniel avatar Jul 03 '19 21:07 iodaniel