Hi,
I'm trying to get the postgresql recipe to work. Specifically, using
postgis. For various reasons related to postgis and the gdal lib, I
pretty much have to use unbuntu 12.04, and Postgresql 9.3 and Postgis 2.1.
I keep running into COOK-1406, which is a mismatch between the openssl
lib linked to by postgresql and chef pg gem.
The issue is marked as closed, but I seem to be running into exactly
that issue. Here's the abbreviated output.
---- Begin output of /opt/chef/embedded/bin/gem install pg -q
--no-rdoc --no-ri -v "0.17.1" ----
STDOUT: Building native extensions. This could take a while...
STDERR: ERROR: Error installing pg:
ERROR: Failed to build gem native extension./opt/chef/embedded/bin/ruby extconf.rb
checking for pg_config... yes
Using config values from /usr/bin/pg_config
checking for libpq-fe.h... yes
checking for libpq/libpq-fs.h... yes
checking for pg_config_manual.h... yes
checking for PQconnectdb() in -lpq... no
checking for PQconnectdb() in -llibpq... no
checking for PQconnectdb() in -lms/libpq... no
Can't find the PostgreSQL client library (libpq)
*** 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.
A comment on the issue by Jessica Bourne states
You actually shouldn't need to customize the bootstrap file to work
around this, you can just specify any bootstrap file with -d aside
from chef-full when first bootstrapping and it won't use omnibus.
However, when I try that like thisknife solo prepare 192.168.1.X -d ubuntu12.04-gems -x vagrant vagrant
The result is the same.
Joshua Timberman offered a workaround
I was able to get the pg gem to install in the Chef omnibus location
with the "install.sh" here:
However, that seems pretty clumsy. (Also, I think there's a way to
include that install.h without running it by hand... what is it?) I
haven't tried it.
Anyway, that was back in Oct 2012.
Is the postgresql recipe /still/ broken?
Or, have I made some mistake in implementing the workaround listed by
Jessica?
What should I do?
Thanks for your help!
Liam
--
Liam Kirsher
PGP: http://liam.numenet.com/pgp/