This forum is no longer active. Please post your questions to our new community site

Forums Redmine

OS X : Error when creating Plugin

Subscribe to OS X : Error when creating Plugin 4 post(s), 2 voice(s)

 
Avatar moccand 8 post(s)

Hi,

trying to create a new plugin a get the error message :

ibm_serbie:redmine guillaume$ script/generate redmine_plugin Polls
!!! The bundled mysql.rb driver has been removed from Rails 2.2. Please install the mysql gem and try again: gem install mysql.
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require’: no such file to load — mysql (MissingSourceFile)

1) i understand than i have one Gem missing
2) but it points on the default OSX ruby … why this link while i’m using a bundle product such as Bitnami ?

if i do use “sudo gem install mysql” i get the following error :

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

/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby extconf.rb install mysql
checking for mysql_query() in -lmysqlclient… no
checking for main() in -lm… yes
checking for mysql_query() in -lmysqlclient… no
checking for main() in -lz… yes
checking for mysql_query() in -lmysqlclient… no
checking for main() in -lsocket… no
checking for mysql_query() in -lmysqlclient… no
checking for main() in -lnsl… no
checking for mysql_query() in -lmysqlclient… no
checking for main() in -lmygcc… no
checking for mysql_query() in -lmysqlclient… no

  • 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.

before trying to do this plugin i did update my default OSX pre installed Ruby/Rails …

does anyone can help ?

Thanks in advance

Guillaume

 
Avatar Beltrán Rueda Administrator 3,714 post(s)

Hi,

Try to run the “use_redmine.sh” script before running any Stack command. This script loads the correct environment.

 
Avatar moccand 8 post(s)

I was able to install the gem using :
export ARCHFLAGS=“-arch i386 -arch x86_64” ;sudo gem install -no-rdoc —no-ri -v=2.7 mysql - —with-mysql-dir=/usr/local/mysql —with-mysql-config=/usr/local/mysql/bin/mysql_config

but it seems that the install is not well done since when i tried to create the plugin i get :

ibm_serbie:redmine guillaume$ script/generate redmine_plugin Polls
dyld: lazy symbol binding failed: Symbol not found: _mysql_init
Referenced from: /Library/Ruby/Gems/1.8/gems/mysql-2.7/lib/mysql.bundle
Expected in: flat namespace

dyld: Symbol not found: _mysql_init
Referenced from: /Library/Ruby/Gems/1.8/gems/mysql-2.7/lib/mysql.bundle
Expected in: flat namespace

Trace/BPT trap

… so my config is still not square enough for plugin creation.

Guillaume

 
Avatar moccand 8 post(s)

with the “use_redmine.sh” it works !
Thanks ;-)

Forums Redmine