3

I'm trying to install redmine-2.3.0 on fedora-18(64-bit). I followed instructions at redmine's official user's guide(http://www.redmine.org/projects/redmine/wiki/RedmineInstall). Everything went well until i run: rake generate_secret_token. I got the following error:

rake aborted! cannot load such file -- pg_ext

I have postgresql-9.2.4-1.

Thanks in advance for any help.

devcurious
  • 121
  • 1
  • 5
  • maybe this helps http://stackoverflow.com/questions/11716532/rails-ruby-postgres-loaderror-cannot-load-such-file-pg-ext – 23tux Apr 09 '13 at 09:51
  • thanks for the reply, i did try suggestions from other questions, but it didn't help. – devcurious Apr 09 '13 at 10:05

3 Answers3

9

I solved my problem:

Had my *pg_ext.so* file under: /usr/local/share/gems/gems/pg-0.15.1/ext/

Copied it to: /usr/local/share/gems/gems/pg-0.15.1/lib/

devcurious
  • 121
  • 1
  • 5
1

I only started seeing this on 2.0.0-p247. Check out this output:

>find ~/.rvm/gems -name "pg_ext*"
/Users/jshort/.rvm/gems/ruby-1.9.3-p194/gems/pg-0.14.1/ext/pg_ext.bundle
/Users/jshort/.rvm/gems/ruby-1.9.3-p194/gems/pg-0.14.1/lib/pg_ext.bundle
/Users/jshort/.rvm/gems/ruby-1.9.3-p194/gems/pg-0.16.0/ext/pg_ext.bundle
/Users/jshort/.rvm/gems/ruby-1.9.3-p194/gems/pg-0.16.0/lib/pg_ext.bundle
/Users/jshort/.rvm/gems/ruby-2.0.0-p247/gems/pg-0.16.0/ext/pg_ext.bundle
/Users/jshort/.rvm/gems/ruby-2.0.0-p247/gems/pg-0.16.0/lib/Users/jshort/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/site_ruby/2.0.0/x86_64-darwin11.4.2/pg_ext.bundle

I just copied the pg_ext.bundle to the 2.0.0-p247's lib directory like the 1.9.3 versions.

Also note that odd directory at the end like the gem installer put that in the wrong location.

jshort
  • 1,006
  • 8
  • 23
-1

also fedora x64 env. mine pg_ext.so was already in /usr/local/share/gems/gems/pg-0.15.1/lib/. I had to edit /usr/local/share/gems/gems/pg-0.15.1/lib/pg.rb and manually specify location of pg_ext:

 require '/usr/local/share/gems/gems/pg-0.15.1/ext/pg_ext.so'
vladm
  • 1
  • 1
    This doesn't appear to relate to the question. If it does please make your explanation clearer. – Nigel B Jul 22 '13 at 18:27