# Mkmf.rb can't find header files for ruby at /usr/lib/ruby/include/ruby.h

**URL:** <https://discuss.dradis.com/t/mkmf-rb-cant-find-header-files-for-ruby-at-usr-lib-ruby-include-ruby-h/413>\
**Category:** Community Edition\
**Created:** [February 2, 2017, 4:37pm UTC](https://discuss.dradis.com/t/mkmf-rb-cant-find-header-files-for-ruby-at-usr-lib-ruby-include-ruby-h/413 "2017-02-02T16:37:32Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![danielm](https://yyz1.discourse-cdn.com/flex035/user_avatar/discuss.dradis.com/danielm/32/88_2.png) [@danielm](https://discuss.dradis.com/u/danielm)\
**Post date:** [February 2, 2017, 4:37pm UTC](https://discuss.dradis.com/t/mkmf-rb-cant-find-header-files-for-ruby-at-usr-lib-ruby-include-ruby-h/413/1 "2017-02-02T16:37:32Z")

</div>

My dradis installation on Kali Linux Rolling release fails:

> ~/dradis-ce# bundle install  
> Don’t run Bundler as root. Bundler can ask for sudo if it is needed, and installing your bundle as root will break this application for all non-root users on this  
> machine.  
> Fetching gem metadata from [https://rubygems.org/](https://rubygems.org/)…  
> Fetching additional metadata from [https://rubygems.org/](https://rubygems.org/)…  
> Resolving dependencies…  
> Using rake 12.0.0

> Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

> ```
> /usr/bin/ruby2.1 extconf.rb
> 
> ```
> 
> mkmf.rb can’t find header files for ruby at /usr/lib/ruby/include/ruby.h

> extconf failed, exit code 1

> Gem files will remain installed in /var/lib/gems/2.1.0/gems/RedCloth-4.3.1 for inspection.  
> Results logged to /var/lib/gems/2.1.0/extensions/x86-linux/2.1.0/RedCloth-4.3.1/gem\_make.out  
> An error occurred while installing RedCloth (4.3.1), and Bundler cannot continue.  
> Make sure that `gem install RedCloth -v '4.3.1'` succeeds before bundling.

dpkg -l | grep ruby | grep dev shows me:

> ii ruby-dev:i386 1:2.3.3 i386 Header files for compiling extension modules for Ruby (default version)  
> ii ruby1.8-dev 1.8.7.358-7 i386 Header files for compiling extension modules for the Ruby 1.8  
> ii ruby2.3-dev:i386 2.3.3-1 i386 Header files for compiling extension modules for the Ruby 2.3

Obviously. current versions of ruby do not install a ruby.h file in /usr/lib/ruby/include/. Has anyone got Dradis running on Kali Linux? If so, how?

---

<div class="post-metadata">

**Author:** ![rachkor](https://yyz1.discourse-cdn.com/flex035/user_avatar/discuss.dradis.com/rachkor/32/51_2.png) [@rachkor](https://discuss.dradis.com/u/rachkor)\
**Post date:** [February 7, 2017, 4:02pm UTC](https://discuss.dradis.com/t/mkmf-rb-cant-find-header-files-for-ruby-at-usr-lib-ruby-include-ruby-h/413/2 "2017-02-07T16:02:55Z")

</div>

Hi @danielm, I’m Rachael with the Dradis support team. Yes, we’ve got many users running Dradis on Kali Linux (myself included!). Let’s get this sorted out. First, I want to confirm a few details. Did you install using the instructions in our guide here?

> **[Installing Dradis on Kali Linux | Dradis Framework](https://dradis.com/ce/documentation/install_kali.html)**
>
> Dradis Framework documentation to install Dradis Community Edition on Kali Linux.

If you were using other instructions, let’s start with the guide above before moving on.

> [@danielm](#):
>
> dpkg -l | grep ruby | grep dev shows me:
> 
> ii ruby-dev:i386 1:2.3.3 i386 Header files for compiling extension modules for Ruby (default version)ii ruby1.8-dev 1.8.7.358-7 i386 Header files for compiling extension modules for the Ruby 1.8ii ruby2.3-dev:i386 2.3.3-1 i386 Header files for compiling extension modules for the Ruby 2.3

Otherwise, the latest version of `dradis-ce` is actually running Ruby v2.2 which isn’t listed in your output. Does `apt-get install ruby2.2-dev` resolve the error?

---

<div class="post-metadata">

**Author:** ![danielm](https://yyz1.discourse-cdn.com/flex035/user_avatar/discuss.dradis.com/danielm/32/88_2.png) [@danielm](https://discuss.dradis.com/u/danielm)\
**Post date:** [February 7, 2017, 4:42pm UTC](https://discuss.dradis.com/t/mkmf-rb-cant-find-header-files-for-ruby-at-usr-lib-ruby-include-ruby-h/413/3 "2017-02-07T16:42:45Z")

</div>

Hi @rachkor  
I followed the guide you mentioned.

Furthermore, apt-get update + apt-get install ruby2.2-dev says:  
E: Unable to locate package ruby2.2-dev  
E: Couldn’t find any package by glob ‘ruby2.2-dev’  
E: Couldn’t find any package by regex ‘ruby2.2-dev’

It is strange. apt-cache search libruby tells me that only version 2.1 and 2.3 are available.

---

<div class="post-metadata">

**Author:** ![danielm](https://yyz1.discourse-cdn.com/flex035/user_avatar/discuss.dradis.com/danielm/32/88_2.png) [@danielm](https://discuss.dradis.com/u/danielm)\
**Post date:** [February 14, 2017, 1:26pm UTC](https://discuss.dradis.com/t/mkmf-rb-cant-find-header-files-for-ruby-at-usr-lib-ruby-include-ruby-h/413/4 "2017-02-14T13:26:40Z")

</div>

Solution:  
apt-get remove ruby2.1  
apt-get update  
apt-get --reinstall install ruby2.1 (fails → to old)

gem install bundler  
 → reinstalled the bundler. Afterwards, it found ruby2.3.
