安装时报错如下
[root@host ruby-2.6.3]# ./configure --prefix=/usr/local/share/ruby2.6.3
checking for ruby... false
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking target system type... x86_64-pc-linux-gnu
checking for gcc... gcc
checking whether the C compiler works... no # error point
configure: error: in `/root/soft/ruby-2.6.3':
configure: error: C compiler cannot create executables
See `config.log' for more details
查看详细的日志文件config.log
......
configure:3967: gcc conftest.c >&5
as: error while loading shared libraries: libopcodes-2.20.51.0.2-5.36.el6.so: cannot open shared object file: No such file or directory
configure:3971: $? = 1
configure:4009: result: no
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME ""
| #define PACKAGE_TARNAME ""
| #define PACKAGE_VERSION ""
| #define PACKAGE_STRING ""
| #define PACKAGE_BUGREPORT ""
| #define PACKAGE_URL ""
| /* end confdefs.h. */
|
| int
| main ()
| {
|
| ;
| return 0;
| }
configure:4014: error: in `/root/soft/ruby-2.6.3':
configure:4016: error: C compiler cannot create executables
See `config.log' for more details
......
错误点如下
error while loading shared libraries: libopcodes-2.20.51.0.2-5.36.el6.so
缺少这个库文件,网上不好找,所以记录下来(注意:需要根据报错时提示的版本下载,因为网上不好找,所以当时下载了48.el6.so安装完还是不行)
下载地址
https://download.csdn.net/download/foryouslgme/11238677
如果自己报错提示的不是我给出的这个版本,那么可以从这个网站下载对应的版本
吐槽一下
正如百度自己宣传的那样,最大的中文搜索引擎,是只能搜中国的中文。最终还是谷歌利害,至少搜索文件名时能给出几个结果,即使没有这个文件的下载,那也可以知道它是什么库,做什么的,最终也有方法去官网,或开源地方去找,哪tm像百度,这个文件名输入进去一个结果都没有。