Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

postgresql 9 doesn't build #2510

Closed
mikestok opened this Issue · 13 comments

9 participants

@mikestok

From the build output:

ar crs libecpg_compat.a informix.o
ranlib libecpg_compat.a
/bin/sh ../../../../config/install-sh -c -m 644 libecpg_compat.a '/Users/mike/Developer/Cellar/postgresql/9.0.0/lib/libecpg_compat.a'
Undefined symbols:
"_ECPGset_var", referenced from:
_ECPG_informix_set_var in informix.o
"_ECPGget_var", referenced from:
_ECPG_informix_get_var in informix.o
ld: symbol(s) not found
collect2: ld returned 1 exit status
make[4]: *** [libecpg_compat.3.2.dylib] Error 1
make[4]: *** Waiting for unfinished jobs....
cd '/Users/mike/Developer/Cellar/postgresql/9.0.0/lib' && \
ranlib libecpg_compat.a
make[3]: *** [install] Error 2
make[2]: *** [install] Error 2
make[1]: *** [install] Error 2
make: *** [install] Error 2
Exit status: 2

http://github.com/mxcl/homebrew/blob/master/Library/Formula/postgresql.rb#L51

==> Environment
HOMEBREW_VERSION: 0.7
HEAD: 1d1b637
HOMEBREW_PREFIX: /Users/mike/Developer
HOMEBREW_CELLAR: /Users/mike/Developer/Cellar
HOMEBREW_REPOSITORY: /Users/mike/Developer
HOMEBREW_LIBRARY_PATH: /Users/mike/Developer/Library/Homebrew
Hardware: dual-core 64-bit penryn
OS X: 10.6.4
Kernel Architecture: i386
Ruby: 1.8.7-174
/usr/bin/ruby => /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
GCC-4.0: build 5494
GCC-4.2: build 5664
LLVM: build 2326
MacPorts or Fink? false
X11 installed? true

==> Build Flags
CC: /usr/bin/cc => /usr/bin/gcc-4.2
CXX: /usr/bin/c++ => /usr/bin/c++-4.2
LD: /usr/bin/cc => /usr/bin/gcc-4.2
CFLAGS: -O3 -march=core2 -msse4.1 -w -pipe -I/usr/include/libxml2 -I/Users/mike/Developer/Cellar/ossp-uuid/1.6.2/include
CXXFLAGS: -O3 -march=core2 -msse4.1 -w -pipe -I/usr/include/libxml2
CPPFLAGS: -I/Users/mike/Developer/Cellar/readline/6.1/include -isystem /Users/mike/Developer/include
LDFLAGS: -L/Users/mike/Developer/Cellar/readline/6.1/lib -L/Users/mike/Developer/lib -L/Users/mike/Developer/Cellar/ossp-uuid/1.6.2/lib
MAKEFLAGS: -j2
PKG_CONFIG_PATH: /Users/mike/Developer/Cellar/readline/6.1/lib/pkgconfig
Error: Failure while executing: make install
Please report this bug at http://github.com/mxcl/homebrew/issues

Also try:
brew doctor to check your setup for common problems.
brew missing to check installed packages for missing deps.

@adamv
Owner

"Works for me."
I wonder if this is an issue compiling into a non-standard prefix? (ie, not /usr/local?)

@mikestok

It looks like the presence of the "old" homebrew postgresql 8.4.4 during the build was the issue. I was doing a "brew upgrade" after a "brew update" had updated the postgresql recipe and the build failed.

When I did:

brew remove postgresql (removed the 8.4.4)

brew install postgresql

to remove the 8.4.4 and then build the 9.0.0 it all went smoothly.

@adamv
Owner

Sounds like something that should be reported upstream to Postgresql, possibly. Not sure.

@nirvdrum

I ran into the same issue as mikestok. Also the same solution, so thanks for helping me figure out how to fix it since it was driving me nuts.

@bkonkle

My experience on a 10.6 Macbook Pro Core 2 Duo was that postgres 9 installed overtop of 8.4.4 with no issues. 8.4.4 still worked just fine alongside 9 until I uninstalled it.

@KieranP

I just hit the same issue. http://pastie.org/1251850

Removing postgres 8.4.4 as mikestok pointed out worked as a fix.

@adamv
Owner

Closing; shame that having the older version even installed breaks builds, but I think that's an upstream issue w/ their make files?

@KieranP

Even if it is an upstream issue, you could point users to this ticket in the caveats (or any def failure_message implementation if one, of the formula, and add a suggestion in there to remove old versions first, rather than expect users to dig through the tickets or make new ones.

@adamv
Owner

Done.

@jobwat

don't know exactly which part helped me but following that one sorted my case: http://stackoverflow.com/questions/12472988/postgres-could-not-connect-to-server-no-such-file-or-directory/16693654#16693654

maybe the removal of the app + the gem

@anthonybrown

I'm getting this error when I do: postgres -D /Users/anthonybrown/pg-data

postgres -D /Users/anthonybrown/pg-data/
LOG:  could not bind IPv6 socket: Address already in use
HINT:  Is another postmaster already running on port 5432? If not, wait a few seconds and retry.
LOG:  could not bind IPv4 socket: Address already in use
HINT:  Is another postmaster already running on port 5432? If not, wait a few seconds and retry.
LOG:  could not bind IPv6 socket: Address already in use
HINT:  Is another postmaster already running on port 5432? If not, wait a few seconds and retry.
WARNING:  could not create listen socket for "localhost"
FATAL:  could not create any TCP/IP sockets

I have no idea what that all means, can someone point me in the right direction. I followed all the uninstall of older postgres installs from Apple, but nothing working.
Any ideas?

@atuljain

I am also getting same problem , any body who can tell me how can i remove postgresql 8.X

@mistydemeo
Owner

The steps suggested earlier are:

brew remove postgresql (removed the 8.4.4)
brew install postgresql

If you're still having an issue, please follow the troubleshooting guide and open a new issue with all diagnostics. Thanks!

@mistydemeo mistydemeo locked and limited conversation to collaborators
This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Something went wrong with that request. Please try again.