jgallagher / go-libpq

cgo-based driver for Postgres
16 stars 9 forks source link

libpq-fe.h: No such file or directory #4

Open goris opened 9 years ago

goris commented 9 years ago

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

                  ^

compilation terminated.

rabbitear commented 8 years ago

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.

iodaniel commented 5 years ago

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.