-
-
Notifications
You must be signed in to change notification settings - Fork 11.3k
Postgresql fails to install #13022
Comments
I'm getting the exact same error. Brand new 2012 Air -- I installed XCode and command line tools, and then Homebrew. |
I have the same problem. I tried everything posted on to no avail. Even downgraded my recipe to 9.1.3. No dice. Is this XCode / clang issue? /usr/bin/gcc -v gcc version 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.9.00) |
@erskingardner Do you have coreutils installed? Where is |
@adamv fwiw, I just did "brew install coreutils" and tried to install postgres again -- got the same error. |
@gbuesing I'm not suggesting that coreutils be installed. I see failures in the original poster's install log refering to /usr/local/bin/gmkdir. |
NOTE: If you have "me too"'ed this thread, but have not gisted your own install failure and brew doctor, you'll need to gist your output as well. |
@samueljohn, this might be related to your PR. After running Homebrew had a significant update yesterday. One consequence of that is the |
I have "me too"'ed this thread. My gist is here: https://gist.github.com/2990761 @2bits confirms my situation |
Probably we're trying to link against /usr/lib/libpgtypes and similar that are present in Lion, and weren't trying to do that before, per the -I and -L changes. |
Gist of install failure: https://gist.github.com/5ac02b71464619aef33c brew doctor reports "Your system is raring to brew." |
The clean solution would be to call |
Probably shouldn't have gone to sleep straight after posting this... @adamv Yes, coreutils is installed. Looks like ☺ which gmkdir 1.9.3-p125 master c2373ed
/usr/local/bin/gmkdir
Thanks for the responses everyone. @samueljohn, let me know if I can help in any way. |
I tried So we are getting somewhere. Thanks for looking into this. |
@2bits do you suggest that as a way to install it or will there be a more "normal" brew install for postgres coming? I'm not super pressed to have postgres running immediately and I don't want to do any installs that are going to be messy to keep upgraded. |
I figure the formula will get adjusted in the next day or two, once @samueljohn considers the issues. It'll be easier for you to wait if you have the time. Thankfully it's a short compile, but there are a lot of options to test. |
👍 thanks for all the help. |
I had the same error and I confirm that after adding 'ENV.macosxsdk 10.6' to /usr/local/Library/Formula/postgresql.rb at line 30 (right after 'def install') 'brew install --no-python postgresql' managed to install postgresql just fine. Thanks @2bits :) |
It's good to hear that the clean solution to use the appropriate macosxsdk works as intended. We have added this On default |
I hope to address remaining issues with #13037 but it looks like explicitly stating the |
Thanks for your help all this just solved my issue, postgresql installed! |
I can also confirm that the solution found by @2bits works -- postgresql installed successfully. Thanks everyone for your help! |
On my system, the changes @samueljohn is making in #13037 fixed Postgresql. After it gets pulled, we can likely leave the PGS formula unchanged, as long as it works for everyone else. |
The ENV.macosxsdk 10.6 solution just worked on my brand new Retina MBP. But "initdb /usr/local/var/postgres" doesn't work but I'm guessing that's a different issue |
@kibaekr could be this issue: http://tammersaleh.com/posts/installing-postgresql-for-rails-3-1-on-lion |
@gbuesing Yes that solved it! Thank you! |
New to this but could you elaborate what adding that line looks like please? Am "thinking" adding that line will look like below: def install
ENV.libxml2 if MacOS.snow_leopard?
ENV.macosxsdk 10.6
... But my mind keeps telling me I should try: def install
ENV.libxml2 if ENV.macosxsdk 10.6
... Am I missing something? |
Ok so the first one is the correct one. I was just being silly I guess the all-nighter's not doing me any good. Tried |
@safarista +1 the first one you suggested works for me! Thanks everybody! |
Please |
Anyone who
because the fix is now in homebrew's master. However, if the |
I'll get the basics out of the way first.
Link to full verbose output of failed install: https://gist.github.com/2991316
I'm on a brand new mid-2012 MacBook Air. I've installed xcode 4.3.3 (with command line tools). Other brews are going fine, it just seems to be postgres that doesn't like me.
I've looked at the issue mentioned at the end of the failure and that is something different. I've also installed gcc-4.2 from homebrew/dupes in the hopes that that might help as well - no love. Strange that
brew --config
isn't showing gcc-4.2 even though it's clearly installed:I've restarted a few times throughout this process, the most recent time just after installing gcc-4.2. Any help would be greatly appreciated.
The text was updated successfully, but these errors were encountered: