Tuesday, October 16, 2007

在安装ruby1.8.5和mysql-ruby2.7.5过程碰到的几个问题及解决方法


$> ruby extconf.rb --with-mysql-dir=/usr/local/mysql
can't find header files for ruby.

If you receive an error which contains "can’t find header files for ruby.", then please install the ruby-devel package.
wget ftp://ftp.nluug.nl/pub/os/Linux/distr/CentOS/5.0/os/x86_64/CentOS/ruby-devel-1.8.5-5.el5.i386.rpm

If you receive the error message "cannot restore segment prot after reloc: Permission denied" when launching IDL, then your SELinux configuration is preventing IDL from launching.

To rectify this issue, you can either:
* Change the default security context for IDL by issuing the command:
$> chcon -t texrel_shlib_t /usr/local/ruby/lib/ruby/site_ruby/1.8/i686-linux/mysql.so
* Disabling SELinux altogether by setting the line
SELINUX=disabled

No comments :