输入rake db:create i get:
LoadError: Could not open library 'sodium': dlopen(sodium, 5): image not found.
Could not open library 'libsodium.dylib': dlopen(libsodium.dylib, 5): image not found
这里有更多输出。
/Users/Mao/.rvm/gems/ruby-2.0.0-p451/gems/ffi-1.9.3/lib/ffi/library.rb:133:in `block in ffi_lib'
/Users/Mao/.rvm/gems/ruby-2.0.0-p451/gems/ffi-1.9.3/lib/ffi/library.rb:100:in `map'
/Users/Mao/.rvm/gems/ruby-2.0.0-p451/gems/ffi-1.9.3/lib/ffi/library.rb:100:in `ffi_lib'
/Users/Mao/.rvm/gems/ruby-2.0.0-p451/gems/rbnacl-3.1.1/lib/rbnacl/sodium.rb:12:in `extended'
/Users/Mao/.rvm/gems/ruby-2.0.0-p451/gems/rbnacl-3.1.1/lib/rbnacl/sodium/version.rb:8:in `extend'
/Users/Mao/.rvm/gems/ruby-2.0.0-p451/gems/rbnacl-3.1.1/lib/rbnacl/sodium/version.rb:8:in `<module:Version>'
/Users/Mao/.rvm/gems/ruby-2.0.0-p451/gems/rbnacl-3.1.1/lib/rbnacl/sodium/version.rb:5:in `<module:Sodium>'
/Users/Mao/.rvm/gems/ruby-2.0.0-p451/gems/rbnacl-3.1.1/lib/rbnacl/sodium/version.rb:4:in `<module:RbNaCl>'
/Users/Mao/.rvm/gems/ruby-2.0.0-p451/gems/rbnacl-3.1.1/lib/rbnacl/sodium/version.rb:3:in `<top (required)>'
答案 0 :(得分:15)
您可能没有安装sodium加密库。如果您使用的是MacPorts,请使用以下命令安装:
sudo port install libsodium
或使用Homebrew:
brew install libsodium