Ruby gem installation error after OSX Yosemite and Xcode 6 installation

前端 未结 2 988
暖寄归人
暖寄归人 2021-02-08 05:30

I tried installing a gem like I did before installing Yosemite, but now I\'m getting an error:

/Library/Ruby/Site/2.0.0/rubygems/ext/builder.rb:159:in `synchronize\': E

2条回答
  •  盖世英雄少女心
    2021-02-08 06:24

    I had a same problem when I installed mysql via bitnami, Looks like you do not have all required mysql libraries .

    I used brewsh and reinstalled mysql by

    brew install mysql
    
    sudo gem install mysql2
    

    Also you need to load the dynamic library in your .profile file in the home directory, you can achieve this by adding these lines in .profile file .

    export PATH=$PATH:$MYSQL
    export DYLD_LIBRARY_PATH=/Applications/mysql/lib:$DYLD_LIBRARY_PATH
    

    In the above two lines of code

    /Applications/mysql/lib , is the path where your mysql libraries are installed , in yours it might be different please check and use as per your environment

提交回复
热议问题