redmine问题集锦02
admin
2023-02-15 22:00:05
0

1.ERROR:  While executing gem ... (Gem::Exception)    Unable to require openssl, install OpenSSL and rebuild ruby (preferred) or use non-HTTPS sources

方法:

进入ruby源码解压包,进入ruby 源码包下的  ext/openssl ,用ruby自带的openssl编译,而不是yum 的openssl

cd /root/ruby-2.1.5/ext/openssl
ruby extconf.rb
成功...
make
报错....
make: *** No rule to make target `/thread_native.h', needed by `ossl.o'.  Stop.


解决方法:
打开Makefile
vim Makefile
加入第三行路径,也就是【top_srcdir = /root/ruby-2.1.5】
srcdir = .
topdir = /usr/local/ruby/include/ruby-2.1.0
top_srcdir = /root/ruby-2.1.5
hdrdir = $(topdir)

保存退出,make clean,
重新make,成功,

make install 成功

[root@mysql openssl]# make 
linking shared-object openssl.so
[root@mysql openssl]# make install
/usr/bin/install -c -m 0755 openssl.so /usr/local/ruby/lib/ruby/site_ruby/2.1.0/x86_64-linux
installing default openssl libraries



2.

 gem install mysql2

Fetching: mysql2-0.4.3.gem (100%)
Building native extensions.  This could take a while...
ERROR:  Error installing mysql2:
	ERROR: Failed to build gem native extension.

    /usr/local/ruby/bin/ruby -r ./siteconf20160321-3049-192s9jh.rb extconf.rb
checking for ruby/thread.h... yes
checking for rb_thread_call_without_gvl() in ruby/thread.h... yes
checking for rb_thread_blocking_region()... yes
checking for rb_wait_for_single_fd()... yes
checking for rb_hash_dup()... yes
checking for rb_intern3()... yes
checking for mysql_query() in -lmysqlclient... no
-----
mysql client is missing. You may need to 'apt-get install libmysqlclient-dev' or 'yum install mysql-devel', and try again.
-----
*** 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.

Provided configuration options:
	--with-opt-dir
	--without-opt-dir
	--with-opt-include
	--without-opt-include=${opt-dir}/include
	--with-opt-lib
	--without-opt-lib=${opt-dir}/lib
	--with-make-prog
	--without-make-prog
	--srcdir=.
	--curdir
	--ruby=/usr/local/ruby/bin/ruby
	--with-mysql-dir
	--without-mysql-dir
	--with-mysql-include
	--without-mysql-include=${mysql-dir}/include
	--with-mysql-lib
	--without-mysql-lib=${mysql-dir}/lib
	--with-mysql-config
	--without-mysql-config
	--with-mysql-dir
	--without-mysql-dir
	--with-mysql-include
	--without-mysql-include=${mysql-dir}/include
	--with-mysql-lib
	--without-mysql-lib=${mysql-dir}/lib
	--with-mysqlclientlib
	--without-mysqlclientlib


已经讲的很清楚了,安装mysql-devel

yum install mysql-devel

相关内容

热门资讯

凤凰晚报|银行女经理和丈夫先后... 今日人物【银行女经理和丈夫先后自杀,储户取款被告知78万存款只剩4000多元】今年4月12日,36岁...
【第一消息】“同城游跑胡子可以... 您好:同城游跑胡子这款游戏可以开挂,确实是有挂的,需要了解加客服微信【9784099】很多玩家在这款...
今日重大发现“胡一把麻将到底有... 有 亲,根据资深记者爆料胡一把麻将是可以开挂的,确实有挂(咨询软件无需打...
腾冲深部构造活动云南省野外科学... 2025年12月24日,腾冲深部构造活动云南省野外科学观测研究站获得云南省科技厅批准。 依托云南省地...
最新引进“乐山游戏中心怎么开挂... 最新引进“乐山游戏中心怎么开挂?”(果然有透视挂)您好,乐山游戏中心这个游戏其实有挂的,确实是有挂的...
微短剧精品创作分享会暨微短剧《... 来源:滚动播报 (来源:文旅中国) 12月27日,微短剧精品创作分享会暨微短剧《“发”家致富》启动仪...
今日重磅消息“微信链接牛牛真的... 网上科普关于“微信链接牛牛有没有挂”话题很是火热,小编也是针对微信链接牛牛作*弊开挂的方法以及开挂对...
【今日要闻】“决战血流麻将究竟... 网上科普关于“决战血流麻将有没有挂”话题很是火热,小编也是针对决战血流麻将作*弊开挂的方法以及开挂对...
【第一资讯】“腾威互娱究竟有挂... 【第一资讯】“腾威互娱究竟有挂吗?”(太坑了果然有挂)您好,腾威互娱这个游戏其实有挂的,确实是有挂的...
我来教教您“微竞斗地主怎么开挂... 家人们!今天小编来为大家解答微竞斗地主透视挂怎么安装这个问题咨询软件客服徽9784099的挂在哪里买...