Skip to content

Instantly share code, notes, and snippets.

@nickbauman
Created June 25, 2012 19:38
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nickbauman/2990761 to your computer and use it in GitHub Desktop.
Save nickbauman/2990761 to your computer and use it in GitHub Desktop.
Problems with homebrew installing postgress
brew --config
HOMEBREW_VERSION: 0.9
HEAD: fc0b4b636a366db1d66db216db380d9c2a4c7a82
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CELLAR: /usr/local/Cellar
CPU: dual-core 64-bit penryn
OS X: 10.7.4
Kernel Architecture: x86_64
Xcode: 4.3.3, CLT 4.3.0.0.1.1249367152
GCC-4.0: N/A
GCC-4.2: N/A
LLVM: build 2336
Clang: 3.1 build 318
MacPorts or Fink? false
X11: /usr/X11
System Ruby: 1.8.7-357
Which Perl: /usr/bin/perl
Which Python: /usr/bin/python
Which Ruby: /usr/bin/ruby => /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
$: brew update
Already up-to-date.
$: brew doctor
Your system is raring to brew.
Relevant failure happens in linking pg_ctl where _PQping is an undefined symbol:
...
/bin/sh ../../../config/install-sh -c -d '/usr/local/Cellar/postgresql/9.1.4/bin'
/usr/bin/clang -Os -w -pipe -march=native -Qunused-arguments -mmacosx-version-min=10.7 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk -isystem /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/usr/include -L/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/usr/lib -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/usr/include -I/usr/local/Cellar/ossp-uuid/1.6.2/include -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Wendif-labels -Wformat-security -fno-strict-aliasing -fwrapv -fexcess-precision=standard pg_ctl.o -L../../../src/port -lpgport -L../../../src/interfaces/libpq -lpq -L../../../src/port -L/usr/local/Cellar/readline/6.2.2/lib -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/usr/include -L/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/usr/lib -L/usr/local/lib -L/usr/local/Cellar/ossp-uuid/1.6.2/lib -Wl,-dead_strip_dylibs -lpgport -lxslt -lxml2 -lssl -lcrypto -lgssapi_krb5 -lz -lreadline -lm -luuid -o pg_ctl
Undefined symbols for architecture x86_64:
"_PQping", referenced from:
_do_start in pg_ctl.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
...
==> Build Environment
CPU: dual-core 64-bit penryn
MacOS: 10.7.4-x86_64
Xcode: 4.3.3, CLT 4.3.0.0.1.1249367152
CC: /usr/bin/clang
CXX: /usr/bin/clang++ => /usr/bin/clang
LD: /usr/bin/clang
CFLAGS: -Os -w -pipe -march=native -Qunused-arguments -mmacosx-version-min=10.7 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk -isystem /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/usr/include -L/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/usr/lib -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/usr/include -I/usr/local/Cellar/ossp-uuid/1.6.2/include
CXXFLAGS: -Os -w -pipe -march=native -Qunused-arguments -mmacosx-version-min=10.7 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk -isystem /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/usr/include -L/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/usr/lib -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/usr/include
CPPFLAGS: -I/usr/local/Cellar/readline/6.2.2/include -isystem /usr/local/include -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk -isystem /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/usr/include -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/usr/include -I/usr/include/libxml2
LDFLAGS: -L/usr/local/Cellar/readline/6.2.2/lib -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/usr/include -L/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/usr/lib -L/usr/local/lib -L/usr/local/Cellar/ossp-uuid/1.6.2/lib
@tylergannon
Copy link

I'm getting this. Would be very happy to find out if you get an answer. Pretty annoyed...

@bdon
Copy link

bdon commented Jun 26, 2012

Getting this as well with at least the 9.1.4 and 9.1.3 formulae.

@nickbauman
Copy link
Author

The 9.1.4 formulae hasn't changed in a couple of weeks so that can't be it. A work around is adding 'ENV.macosxsdk 10.6' to /usr/local/Library/Formula/postgresql.rb at line 30 (right after 'def install') 'brew install --no-python postgresql' should work but no python support.

They are tracking it here.

Homebrew/legacy-homebrew#13022

@marshalc
Copy link

I too am experiencing this on a 10.7.4 machine that I've just newly built. This script and process worked just fine over a month ago though when I used homebrew to install postgres onto another 10.7.4 machine.

Of course, the error message links to Homebrew/legacy-homebrew#11759, so perhaps that part of the install script needs updating to the alternative issue number above.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment