Hello guys,

I didn't touch ror for a while. Today i tried to upload an easy static
page to heroku.
I got the error: we're sorry but something went wrong.
So i researched a bit and found out that i need to install the gem pg
for heroku now.

But when i write it in the gemfile and run sudo bundle install i get:

Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native
extension.

/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/
ruby extconf.rb
checking for pg_config... no
No pg_config... trying anyway. If building fails, please try again
with
--with-pg-config=/path/to/pg_config
checking for libpq-fe.h... no
Can't find the 'libpq-fe.h header
*** 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.

Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/
ruby
--with-pg
--without-pg
--with-pg-dir
--without-pg-dir
--with-pg-include
--without-pg-include=${pg-dir}/include
--with-pg-lib
--without-pg-lib=${pg-dir}/lib
--with-pg-config
--without-pg-config
--with-pg_config
--without-pg_config


Gem files will remain installed in /Library/Ruby/Gems/1.8/gems/
pg-0.13.1 for inspection.
Results logged to /Library/Ruby/Gems/1.8/gems/pg-0.13.1/ext/
gem_make.out
An error occured while installing pg (0.13.1), and Bundler cannot
continue.
Make sure that `gem install pg -v '0.13.1'` succeeds before bundling.

btw: a mkmf.log file does not exists

so i tried sudo gem install pg -v '0.13.1'

and got:

Building native extensions. This could take a while...
ERROR: Error installing pg:
ERROR: Failed to build gem native extension.

/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/
ruby extconf.rb
checking for pg_config... no
No pg_config... trying anyway. If building fails, please try again
with
--with-pg-config=/path/to/pg_config
checking for libpq-fe.h... no
Can't find the 'libpq-fe.h header
*** 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.

Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/
ruby
--with-pg
--without-pg
--with-pg-dir
--without-pg-dir
--with-pg-include
--without-pg-include=${pg-dir}/include
--with-pg-lib
--without-pg-lib=${pg-dir}/lib
--with-pg-config
--without-pg-config
--with-pg_config
--without-pg_config


Gem files will remain installed in /Library/Ruby/Gems/1.8/gems/
pg-0.13.1 for inspection.
Results logged to /Library/Ruby/Gems/1.8/gems/pg-0.13.1/ext/
gem_make.out


I also did some research to fix this problem and only found this:

PATH=$PATH:/Library/PostgreSQL/8.3/bin sudo gem install pg

and this didn't worked - no wonder i didn't install PostgreSQL.

any ideas?

best regards

Sascha

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

Search Discussions

  • Javier Quarite at Feb 14, 2012 at 11:55 pm
    Have you installed Postgre on your computer?
    If you just want to use Postgre on heroku and... lets say mysql/sqlite on
    your computer
    then in your gemfile do this

    group :development do
    gem 'sqlite3'
    end

    group :production do
    gem 'pg'
    end

    run bundle
    and then start again your push to heroku (do another commit... push etc etc
    etc)

    Javier Q

    --
    You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
    To post to this group, send email to rubyonrails-talk@googlegroups.com.
    To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
  • Genji at Feb 15, 2012 at 12:50 am
    For a short while i got postgres-pr ?
    But its uninstalled atm. Could that be a problem for the PATH?

    I tried like you said. But the problem remains, if i try bundle
    install i get this error message about pg.
    And when i try heroku push, it says:

    Heroku push rejected, failed to install gems via Bundler

    Well, how i said it's just a static page. Just to show some
    Informations. I don't need databases or anything.

    Is pg really essential for heroku now?
    On 15 Feb., 00:55, Javier Quarite wrote:
    Have you installed Postgre on your computer?
    If you just want to use Postgre on heroku and... lets say mysql/sqlite on
    your computer
    then in your gemfile do this

    group :development do
    gem 'sqlite3'
    end

    group :production do
    gem 'pg'
    end

    run bundle
    and then start again your push to heroku (do another commit... push etc etc
    etc)

    Javier Q
    --
    You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
    To post to this group, send email to rubyonrails-talk@googlegroups.com.
    To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
  • Javier Quarite at Feb 15, 2012 at 12:49 am

    On Tue, Feb 14, 2012 at 7:41 PM, Genji wrote:

    For a short while i got postgres-pr ?
    But its uninstalled atm. Could that be a problem for the PATH?

    I tried like you said. But the problem remains, if i try bundle
    install i get this error message about pg.
    And when i try heroku push, it says:

    Heroku push rejected, failed to install gems via Bundler

    Well, how i said it's just a static page. Just to show some
    Informations. I don't need databases or anything.

    Is pg really essential for heroku now?
    I forgot something

    bundle --without production

    after that just do

    git commit ......

    and then push

    git push heroku .....

    and it has to work


    Javier Q.

    --
    You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
    To post to this group, send email to rubyonrails-talk@googlegroups.com.
    To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
  • Genji at Feb 15, 2012 at 1:26 am
    Thanks now it works!

    Sad that this wasn't the reason ;(
    still getting:
    We're sorry, but something went wrong.(500)

    I should have done my research better ;(

    This is the wrong line:

    <%= stylesheet_link_tag "application", :media => :all %>

    I'm searching now for a solution ;) before the rails update i just
    used <%= stylesheet_link_tag :all %> :D

    Thank you for your help!
    On 15 Feb., 01:49, Javier Quarite wrote:
    On Tue, Feb 14, 2012 at 7:41 PM, Genji wrote:
    For a short while i got postgres-pr ?
    But its uninstalled atm. Could that be a problem for the PATH?
    I tried like you said. But the problem remains, if i try bundle
    install i get this error message about pg.
    And when i try heroku push, it says:
    Heroku push rejected, failed to install gems via Bundler
    Well, how i said it's just a static page. Just to show some
    Informations. I don't need databases or anything.
    Is pg really essential for heroku now?
    I forgot something

    bundle --without production

    after that just do

    git commit ......

    and then push

    git push heroku .....

    and it has to work

    Javier Q.
    --
    You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
    To post to this group, send email to rubyonrails-talk@googlegroups.com.
    To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
  • Javier Quarite at Feb 15, 2012 at 1:24 am

    On Tue, Feb 14, 2012 at 8:18 PM, Genji wrote:

    Thanks now it works!

    Sad that this wasn't the reason ;(
    still getting:
    We're sorry, but something went wrong.(500)

    I should have done my research better ;(

    This is the wrong line:

    <%= stylesheet_link_tag "application", :media => :all %>

    I'm searching now for a solution ;) before the rails update i just
    used <%= stylesheet_link_tag :all %> :D

    Thank you for your help!
    maybe you just use

    <%= stylesheet_link_tag "application" %>

    It will grab the application.css and if you look inside the file you'll see
    a line like this

    //= require_tree .

    and it will use the other css files so you don't need to keep on adding
    each file (or maybe add what you need)

    If it shows errors... you can type "heroku logs" and see what happened


    Javier Q

    --
    You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
    To post to this group, send email to rubyonrails-talk@googlegroups.com.
    To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
  • Genji at Feb 15, 2012 at 1:52 am
    My problem was that heroku logs showed me no errors first- but now.
    I am working to solve the problems now, its bit more than the
    stylsheet.
    (Maybe I shouldn't do this at 2:43 am :D)

    have a nice day! (or night)
    On 15 Feb., 02:24, Javier Quarite wrote:
    On Tue, Feb 14, 2012 at 8:18 PM, Genji wrote:
    Thanks now it works!
    Sad that this wasn't the reason ;(
    still getting:
    We're sorry, but something went wrong.(500)
    I should have done my research better ;(
    This is the wrong line:
    <%= stylesheet_link_tag    "application", :media => :all %>
    I'm searching now for a solution ;) before the rails update i just
    used <%= stylesheet_link_tag :all %> :D
    Thank you for your help!
    maybe you just use

    <%= stylesheet_link_tag "application" %>

    It will grab the application.css and if you look inside the file you'll see
    a line like this

    //= require_tree .

    and it will use the other css files so you don't need to keep on adding
    each file (or maybe add what you need)

    If it shows errors... you can type "heroku logs" and see what happened

    Javier Q
    --
    You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
    To post to this group, send email to rubyonrails-talk@googlegroups.com.
    To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
  • Javier Quarite at Feb 15, 2012 at 1:48 am

    On Tue, Feb 14, 2012 at 8:44 PM, Genji wrote:

    My problem was that heroku logs showed me no errors first- but now.
    I am working to solve the problems now, its bit more than the
    stylsheet.
    (Maybe I shouldn't do this at 2:43 am :D)

    have a nice day! (or night)

    Well here is 20:52. :)
    Javier Q.

    --
    You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
    To post to this group, send email to rubyonrails-talk@googlegroups.com.
    To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
  • Genji at Feb 15, 2012 at 2:19 am
    I got to fix all problems now :)

    i had to to set config.assets.compile = true ( config/environments/
    production.rb)

    Thanks, you helped me a lot!
    On 15 Feb., 02:48, Javier Quarite wrote:
    On Tue, Feb 14, 2012 at 8:44 PM, Genji wrote:
    My problem was that heroku logs showed me no errors first- but now.
    I am working to solve the problems now, its bit more than the
    stylsheet.
    (Maybe I shouldn't do this at 2:43 am :D)
    have a nice day! (or night)
    Well here is 20:52.  :)
    Javier Q.
    --
    You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
    To post to this group, send email to rubyonrails-talk@googlegroups.com.
    To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
  • Javier Quarite at Feb 15, 2012 at 2:26 am

    On Tue, Feb 14, 2012 at 9:10 PM, Genji wrote:

    I got to fix all problems now :)

    i had to to set config.assets.compile = true ( config/environments/
    production.rb)

    Thanks, you helped me a lot!
    Well ... its rare because as far as I know that comes already in
    production.rb

    Anyway, I'm glad you've solved it :)

    Javier Q.

    --
    You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
    To post to this group, send email to rubyonrails-talk@googlegroups.com.
    To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
  • Genji at Feb 15, 2012 at 1:33 am
    Sorry little mistake the wrong line is:

    <%= stylesheet_link_tag "application", :media => "all" %>
    On 15 Feb., 02:18, Genji wrote:
    Thanks now it works!

    Sad that this wasn't the reason ;(
    still getting:
    We're sorry, but something went wrong.(500)

    I should have done my research better ;(

    This is the wrong line:

    <%= stylesheet_link_tag    "application", :media => :all %>

    I'm searching now for a solution ;) before the rails update i just
    used <%= stylesheet_link_tag :all %> :D

    Thank you for your help!

    On 15 Feb., 01:49, Javier Quarite wrote:






    On Tue, Feb 14, 2012 at 7:41 PM, Genji wrote:
    For a short while i got postgres-pr ?
    But its uninstalled atm. Could that be a problem for the PATH?
    I tried like you said. But the problem remains, if i try bundle
    install i get this error message about pg.
    And when i try heroku push, it says:
    Heroku push rejected, failed to install gems via Bundler
    Well, how i said it's just a static page. Just to show some
    Informations. I don't need databases or anything.
    Is pg really essential for heroku now?
    I forgot something
    bundle --without production
    after that just do
    git commit ......
    and then push
    git push heroku .....
    and it has to work
    Javier Q.
    --
    You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
    To post to this group, send email to rubyonrails-talk@googlegroups.com.
    To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouprubyonrails-talk @
categoriesrubyonrails
postedFeb 14, '12 at 9:58p
activeFeb 15, '12 at 2:26a
posts11
users2
websiterubyonrails.org
irc#RubyOnRails

2 users in discussion

Genji: 6 posts Javier Quarite: 5 posts

People

Translate

site design / logo © 2021 Grokbase