vovacherry.blogg.se

Brew install postgresql 9.3
Brew install postgresql 9.3











  1. BREW INSTALL POSTGRESQL 9.3 HOW TO
  2. BREW INSTALL POSTGRESQL 9.3 MAC OS X

INCLUDEDIR-SERVER = /opt/local/include/postgresql91/server PKGINCLUDEDIR = /opt/local/include/postgresql91 INCLUDEDIR = /opt/local/include/postgresql91 HTMLDIR = /opt/local/share/doc/postgresql If you were installing from MacPorts, you should be able to walk through the following procedure: % /opt/local/lib/postgresql91/bin/pg_config => Done installing documentation for pg after 1 secondsįake out gem by prefixing the appropriate environment variables. => Installing ri documentation for pg-1.2.3 It allowed the pg gem to be able to find binaries in the right architecture: export PATH=/usr/local/Cellar/postgresql/13.2_1/bin:$PATH To solve this, in my case, I just had to add to the PATH another version of postgres compiled in x86_64.

brew install postgresql 9.3

=> Non-fat file: /opt/homebrew/bin/pg_config is architecture: arm64 => /Users/leo/.rbenv/versions/2.6.6/bin/ruby is architecture: x86_64 Lipo -info /Users/leo/.rbenv/versions/2.6.6/bin/ruby # You might need to use a different command if you use a ruby version manager You can check the architecture with the lipo -info command: which ruby I have installed ruby in "rosetta 2" mode ( x86_64) and postgres in "native" mode ( arm64). reinstall postgres to match the architecture in which the pg gem is built (by default it's the same as ruby's)įor instance, in my case, I have a m1 macbook.try to compile the pg gem in the same architecture as postgres.If you end up in this situation, you have several options: you are on a 64-bit computer but have installed postgres in 32-bit mode.you are on a m1 macbook (apple silicon) but have installed postgres in rosetta 2 mode.So, during its build, the pg gem needs to be able to find the library libqp compiled for the same architecture (for example x86_64 or arm64). It relies on the libpq library which is the PostgreSQL library for C applications. The pg gem is a native extension written in C. If you have trouble figuring out which command you should run, you better understand what is happening. However they only work for some particular scenarii. Most of those answers focus on giving you one command that just works. Results logged to /Library/Ruby/Gems/1.8/gems/pg-0.11.0/ext/gem_make.out Gem files will remain installed in /Library/Ruby/Gems/1.8/gems/pg-0.11.0 for inspection. ruby=/System/Library/Frameworks/amework/Versions/1.8/usr/bin/ruby noĬan't find the PostgreSQL client library (libpq)Ĭould not create Makefile due to some reason, probably lack of noĬhecking for PQconnectdb() in -lms/libpq. Using config values from /Library/PostgreSQL/8.3/bin/pg_configĬhecking for PQconnectdb() in -llibpq. System/Library/Frameworks/amework/Versions/1.8/usr/bin/ruby extconf.rb This could take a while.ĮRROR: Failed to build gem native extension. Here's what I get when I try to do sudo gem install pg: $ sudo gem install pgīuilding native extensions.

BREW INSTALL POSTGRESQL 9.3 HOW TO

I suspect I need to install the PostgreSQL development packages but I have no idea how to do that on OS X. First I tried the MacPorts install but that didn't go well so I did the one-click DMG install.

BREW INSTALL POSTGRESQL 9.3 MAC OS X

yesĬhecking for C99 variable length arrays.I'm trying to install PostgreSQL for Rails on Mac OS X 10.6. Have_const: checking for PG_DIAG_TABLE_NAME in libpq-fe.h. Have_func: checking for PQencryptPasswordConn().

brew install postgresql 9.3

Have_func: checking for PQsslAttribute(). Have_func: checking for PQsetSingleRowMode(). Have_library: checking for PQconnectdb() in -lpq. yesįind_header: checking for pg_config_manual.h. yesįind_header: checking for libpq/libpq-fs.h. yesįind_header: checking for libpq-fe.h. noĪfter running "brew install postgresql", I can see all required libraries being there: za:myapp za$ cat /Users/za/.rbenv/versions/2.3.0/lib/ruby/gems/2.3.0/extensions/x86_64-darwin-15/2.3.0-static/pg-1.0.0/mkmf.log | grep yesįind_executable: checking for pg_config. Inside the mkmf.log, you will see that it could not find required libraries, to finish the build. The logs indicated that the make file could not be created because of the following: Could not create Makefile due to some reason, probably lack of necessary Regardless of what OS you are running, look at the logs file of the "Makefile" to see what is going on, instead of blindly installing stuff. Results logged to C:/Ruby/lib/ruby/gems/1.8/gems/pg-0.10.1/ext/gem_make.out Gem files will remain installed in C:/Ruby/lib/ruby/gems/1.8/gems/pg-0.10.1 for If building fails, please try again withĬould not create Makefile due to some reason, probably lack of Gem install pg gives this error Temporarily enhancing PATH to include DevKit.īuilding native extensions. I tried using gem install pg but it doesn't seem to work.













Brew install postgresql 9.3