问题处理:Library not loaded: /usr/local/opt/readline/lib/libreadline.7.dylib (LoadError)
进入rails 文件夹, terminal输入rails console报告❌。
类似下面的
Running via Spring preloader in process
Traceback (most recent call last):
: from -e::in `<main>'
: from /Users/wemteq/.rbenv/versions/2.5./lib/ruby/2.5./rubygems/core_ext/kernel_require.rb::in `require'
: from /Users/wemteq/.rbenv/versions/2.5./lib/ruby/2.5./rubygems/core_ext/kernel_require.rb::in `require'
: from /Users/wemteq/.rbenv/versions/2.5./lib/ruby/gems/2.5./gems/activesupport-5.2./lib/active_support/dependencies.rb::in `load'
...
: from /Users/wemteq/.rbenv/versions/2.5./lib/ruby/gems/2.5./gems/activesupport-5.2./lib/active_support/dependencies.rb::in `require'
: from /Users/wemteq/.rbenv/versions/2.5./lib/ruby/gems/2.5./gems/activesupport-5.2./lib/active_support/dependencies.rb::in `load_dependency'
: from /Users/wemteq/.rbenv/versions/2.5./lib/ruby/gems/2.5./gems/activesupport-5.2./lib/active_support/dependencies.rb::in `block in require'
: from /Users/wemteq/.rbenv/versions/2.5./lib/ruby/gems/2.5./gems/bootsnap-1.3./lib/bootsnap/load_path_cache/core_ext/kernel_require.rb::in `require'
: from /Users/wemteq/.rbenv/versions/2.5./lib/ruby/gems/2.5./gems/bootsnap-1.3./lib/bootsnap/load_path_cache/core_ext/kernel_require.rb::in `require_with_bootsnap_lfi'
: from /Users/wemteq/.rbenv/versions/2.5./lib/ruby/gems/2.5./gems/bootsnap-1.3./lib/bootsnap/load_path_cache/loaded_features_index.rb::in `register'
: from /Users/wemteq/.rbenv/versions/2.5./lib/ruby/gems/2.5./gems/bootsnap-1.3./lib/bootsnap/load_path_cache/core_ext/kernel_require.rb::in `block in require_with_bootsnap_lfi'
/Users/wemteq/.rbenv/versions/2.5./lib/ruby/gems/2.5./gems/bootsnap-1.3./lib/bootsnap/load_path_cache/core_ext/kernel_require.rb::in `require': dlopen(/Users/wemteq/.rbenv/versions/2.5.0/lib/ruby/2.5.0/x86_64-darwin17/readline.bundle, 9):
Library not loaded: /usr/local/opt/readline/lib/libreadline.7.dylib (LoadError)
Referenced from: /Users/wemteq/.rbenv/versions/2.5./lib/ruby/2.5./x86_64-darwin17/readline.bundle
Reason: image not found - /Users/wemteq/.rbenv/versions/2.5./lib/ruby/2.5./x86_64-darwin17/readline.bundle
直接google,
Library not loaded: /usr/local/opt/readline/lib/libreadline.7.dylib (LoadError)
就能找到stackoverflow的答案。
原因是homebrew更新了libhistory的版本到8.0。
而rails的默认配置是7.0找不到对应的库。因此建立一个符号连接即可。
cd /usr/local/opt/readline/lib/
ls -l
//可以看到这个文件夹下的文件的版本是libhistory.8.0.dylib
//所以在这个文件夹下添加一个符号连接,使用命令ln -s(bash命令)
ln -s libhistory.8.0.dylib libhistory..dylib
然后rails c就可以正确打开了。
问题处理:Library not loaded: /usr/local/opt/readline/lib/libreadline.7.dylib (LoadError)的更多相关文章
- dyld: Library not loaded: /usr/local/opt/readline/lib/libreadline.7.dylib
dyld: Library not loaded: /usr/local/opt/readline/lib/libreadline.7.dylib Table of Contents 1. 启动时报错 ...
- dyld: Library not loaded: /usr/local/opt/icu4c/lib/libicui18n.63.dylib
本地环境报错有 3 处,如下: 1. 执行命令,无论执行 php 的什么命令,统一报错 dyld: Library not loaded: /usr/local/opt/icu4c/lib/libic ...
- 【Python MySQLdb】Library not loaded: /usr/local/mysql/lib/libmysqlclient.20.dylib解决办法
使用MySQLdb遇到以下错误 ImportError: dlopen(/Users/jackey/Documents/Xiaomi/Code/wda_python/lib/python2./site ...
- 解决Xcode10 Library not loaded: /usr/lib/libstdc++.6造成的crash及报错
关键字1:dyld: Library not loaded: /usr/lib/libstdc++.6.dylib Referenced from: 关键字2:Reason: no suitabl ...
- CentOS安装软件出现错误:bash: /usr/local/bin/rar: /lib/ld-linux.so.2: bad ELF interpreter: No such file or directory
CentOS安装软件出现错误: bash: /usr/local/bin/rar: /lib/ld-linux.so.2: bad ELF interpreter: No such file or d ...
- /usr/local /opt
Linux 的软件安装目录是也是有讲究的,理解这一点,在对系统管理是有益的 /usr:系统级的目录,可以理解为C:/Windows/, /usr/lib理解为C:/Windows/System32. ...
- PHP提示dyld: Library not loaded问题解决
Mac在命令行执行php命令时,如php -v 有错误提示: dyld: Library not loaded: /usr/local/opt/openssl/lib/libcrypto.1.0..d ...
- 转:linux下面/usr/local和opt目录有何区别
/usr/local下一般是你安装软件的目录,这个目录就相当于在windows下的programefiles这个目录 /opt这个目录是一些大型软件的安装目录,或者是一些服务程序的安装目录 /opt ...
- Linux下面/usr/local和opt目录
1./opt This directory is reserved for all the software and add-on packages that are not part of the ...
随机推荐
- weui开发笔记
1.标准的weui只是一个css皮肤,当然里面有h5特性所以有一些很好的组件,比如时间选择控件.数字输入框(用于手机号等),在ios——微信中可以做到完美的展示. 2.ui框架以手机移动端为优先显示( ...
- NOIP2018提高组初赛知识点
(传说,在神秘的初赛中,选手们经常互相爆零以示友好……) 历年真题:ti.luogu.com.cn 以下标题中打*的是我认为的重点内容 一.关于计算机 (一)计算机组成 硬件组成: 1. 控制器(C ...
- 【托业】【跨栏阅读】错题集-REVIEW1
05 06 REVIEW 1
- MySQL行转列与列转行
行转列 例如:把图1转换成图2结果展示 图1 图2 CREATE TABLE `TEST_TB_GRADE` ( `ID` ) NOT NULL AUTO_INCREMENT, `) DEFAULT ...
- laravel----------如何优化laravel框架
1.关闭debug (打开.env文件,把debug设置为false.) 2.缓存路由和配置(清除:php artisan config:clear php artisan route:clear ...
- caffe-ssd安装GPU版本和CPU的区别
在CPU中1.CPU_ONLY :=1的注释取消掉 2.BLAS := atlas 在GPU中 1.USE_CUDNN := 1的注释取消 2.BLAS := open
- sitecore 数字化营销-path funnel
路径分析器是一个应用程序,允许您查看联系人在浏览网站时所采用的各种路径.您可以查看联系人在转换目标并与广告系列互动时所采用的路径,让您深入了解哪些路径为每次转化提供最佳参与价值,以及哪些路径效率较低且 ...
- Future 示例
public static Object send(RequestClient request) future.channel().writeAndFlush(JSONObject.toJSONStr ...
- DataTables页面列点击排序
<!-- DataTables --> <script type="text/javascript" charset="utf8" src=& ...
- win10忘记开机密码无法进入桌面
第一种: 电脑用微软账户登录,但密码始终不正确. 登陆这个网址 https://account.live.com/password/reset 按照提示的操作利用之前注册信息一步步重设密码 最后 ...