# Install from source on CentOS question

**URL:** <https://www.ruby-forum.com/t/install-from-source-on-centos-question/187945>\
**Category:** Ruby\
**Created:** [May 3, 2010, 2:13am UTC](https://www.ruby-forum.com/t/install-from-source-on-centos-question/187945 "2010-05-03T02:13:55Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![cameronsharpe](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/91b2a8/32.png) [@cameronsharpe](https://www.ruby-forum.com/u/cameronsharpe)\
**Post date:** [May 3, 2010, 2:13am UTC](https://www.ruby-forum.com/t/install-from-source-on-centos-question/187945/1 "2010-05-03T02:13:55Z")

</div>

I am attempting to install 1.9.1 from source on CentOS 5.4 and am  
running into an issue.

after unpacking the archive and cd-ing into the ruby-1.9.1-p376 I run:  
./configure --with-openssl-dir=/usr/lib/openssl

but the last line of the output shows:  
config.status: creating Makefile  
configure: WARNING: unrecognized options: --with-openssl-dir

What do I need to do to get the creation of the makefile to not throw  
that warning?

---

<div class="post-metadata">

**Author:** ![cameronsharpe](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/91b2a8/32.png) [@cameronsharpe](https://www.ruby-forum.com/u/cameronsharpe)\
**Post date:** [May 3, 2010, 5:14am UTC](https://www.ruby-forum.com/t/install-from-source-on-centos-question/187945/2 "2010-05-03T05:14:51Z")

</div>

Hi Cameron,

I am new to Ruby and I came across this same problem when I was  
installing  
ruby for the first time on my Ubuntu box. But after spending some time  
on  
it, I found the following steps works without much of a problem for  
installing ruby with openssl.

Ignore the --with-openssl-dir: I think the problem is to say with using  
[dash][dash]with-openssl-dir instead of [dash][dash]  
[dash][dash]with-openssl-dir. Google for the same and you will find the  
reason

Instead, try this approach:

1. Install ruby with ./configure --prefix = /installation\_path
2. Download openssl source and run ./config --perfix= /installation\_path  
Note: OpenSSL 1.0.X version doesn’t seems to be working with ruby.  
OpenSSL-0.9.8n worked for me. Also use the same $installation\_path for  
both  
‘prefix’ declarations. e.g., --prefix=/usr/local
3. Complete OpenSSL installation.
4. Go back to the ruby-1.8.6-pxxx/ext/openssl folder and run - ruby  
extconf.rb, make, make install respectively.

Now I am sure, all the required packages for openssl can be identified  
by  
ruby whenever required.

Hope this helps. I have also blogged about the same in the following  
location. Feel free to check this out too.

> **[Ubuntu: Rails – Fix Starting Webrick, Openssl issue](https://theflashesofinsight.wordpress.com/2010/04/29/ubuntu-rails-fix-starting-webrick-openssl-issue/)**
>
> Hey Guys, I sincerely apologize for causing this inconvenience. This article has been moved the following location: As I was nearing my 100th blog, I thought its good time for me to move all my blo…

With be glad to hear from the group if there are any better solutions.

Thanks

---

<div class="post-metadata">

**Author:** ![cameronsharpe](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/91b2a8/32.png) [@cameronsharpe](https://www.ruby-forum.com/u/cameronsharpe)\
**Post date:** [May 3, 2010, 9:49am UTC](https://www.ruby-forum.com/t/install-from-source-on-centos-question/187945/3 "2010-05-03T09:49:00Z")

</div>

v4 forums wrote:

> With be glad to hear from the group if there are any better solutions.

There’s no need to install openssl from source. Just install the  
openssl-devel package before building ruby (yum install openssl-devel)
