# Problems installing RRDtool gem under Windows

**URL:** <https://www.ruby-forum.com/t/problems-installing-rrdtool-gem-under-windows/133426>\
**Category:** Ruby\
**Created:** [March 31, 2008, 2:58pm UTC](https://www.ruby-forum.com/t/problems-installing-rrdtool-gem-under-windows/133426 "2008-03-31T14:58:59Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![ribes](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/f4b2a3/32.png) [@ribes](https://www.ruby-forum.com/u/ribes)\
**Post date:** [March 31, 2008, 2:58pm UTC](https://www.ruby-forum.com/t/problems-installing-rrdtool-gem-under-windows/133426/1 "2008-03-31T14:58:59Z")

</div>

Team,

I am trying to install RRDtool under MS Windows/XP.  
I tried to install the gem and got the following errors:

C:$user\downloads\Ruby and Friends\>ruby -v  
ruby 1.8.6 (2007-09-24 patchlevel 111) [i386-mswin32]

C:$user\downloads\Ruby and Friends\>gem install RubyRRDtool-0.6.0.gem  
Building native extensions. This could take a while…  
ERROR: While executing gem … (RuntimeError)  
Error instaling RubyRRDtool-0.6.0.gem:  
ERROR: Failed to build gem native extension.

ruby extconf.rb install RubyRRDtool-0.6.0.gem  
checking for main() in z.lib… no  
checking for main() in png.lib… no  
checking for main() in freetype.lib… no  
checking for main() in art\_lgpl\_2.lib… no  
checking for rrd\_first() in rrd.lib… no  
creating Makefile

nmake  
‘nmake’ is not recognized as an internal or external command,  
operable program or batch file.

Gem files will remain installed in  
c:/ruby/lib/ruby/gems/1.8/gems/RubyRRDtool-0.6.0 for inspection.  
Results logged to c:/ruby/lib/ruby/gems/1.8/gems/RubyRRDtool-0.6.0  
/gem\_make.out

I then tried the binary distribution (

rrdtool-1.2.27-w32.zip  
[http://www.gknw.net/mirror/rrdtool/rrdtool-1.2.27-w32.zip](http://www.gknw.net/mirror/rrdtool/rrdtool-1.2.27-w32.zip)  
06-Mar-2008 02:24 1.0M ZIP compressed archive) for Windows.

But when I try the sample pgm I get the error listed below.

C:$user\downloads\Ruby and  
Friends\rrdtool-1.2.27-w32\rrdtool-1.2.27-w32\>ls  
-al  
total 4146  
drwx------ 2 ReyesV Domain+Users 512 Mar 31 08:49 .  
drwx------ 3 ReyesV Domain+Users 512 Mar 28 15:39 …  
-rwx------ 1 ReyesV Domain+Users 113828 Feb 17 10:26 CHANGES  
-rwx------ 1 ReyesV Domain+Users 15405 Feb 17 10:26 COPYING  
-rwx------ 1 ReyesV Domain+Users 3693 Feb 17 10:26 COPYRIGHT  
-rwx------ 1 ReyesV Domain+Users 60444 Feb 17 10:26  
DejaVuSansMono-Roman.ttf  
-rwx------ 1 ReyesV Domain+Users 2031 Feb 17 10:26 NEWS  
-rwx------ 1 ReyesV Domain+Users 2545 Feb 17 10:26 README  
-rwx------ 1 ReyesV Domain+Users 183 Mar 6 01:23 readme.txt  
-rwx------ 1 ReyesV Domain+Users 960512 Mar 6 01:23 rrdcgi.exe  
-rwx------ 1 ReyesV Domain+Users 959488 Mar 6 01:23 rrdtool.exe  
-rwx------ 1 ReyesV Domain+Users 1090 Mar 28 15:59  
rrdtoolTest00.rb

C:$user\downloads\Ruby and  
Friends\rrdtool-1.2.27-w32\rrdtool-1.2.27-w32\>ruby  
rrdtoolTest00.rb  
c:/ruby/lib/ruby/site\_ruby/1.8/rubygems/custom\_require.rb:27:in  
`gem_original_require': no such file to load -- RRD (LoadError) from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `require’  
from rrdtoolTest00.rb:1

Suggestions will be greatly appreciated.

Thank you

Victor

---

<div class="post-metadata">

**Author:** ![ribes](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/f4b2a3/32.png) [@ribes](https://www.ruby-forum.com/u/ribes)\
**Post date:** [March 31, 2008, 3:15pm UTC](https://www.ruby-forum.com/t/problems-installing-rrdtool-gem-under-windows/133426/2 "2008-03-31T15:15:38Z")

</div>

On Mon, Mar 31, 2008 at 2:58 PM, Victor R. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
wrote:

> ERROR: While executing gem … (RuntimeError)
> 
> I then tried the binary distribution (  
> drwx------ 2 ReyesV Domain+Users 512 Mar 31 08:49 .  
> -rwx------ 1 ReyesV Domain+Users 959488 Mar 6 01:23 rrdtool.exe  
> -rwx------ 1 ReyesV Domain+Users 1090 Mar 28 15:59 rrdtoolTest00.rb
> 
> C:$user\downloads\Ruby and Friends\rrdtool-1.2.27-w32\rrdtool-1.2.27-w32\>ruby  
> rrdtoolTest00.rb  
> c:/ruby/lib/ruby/site\_ruby/1.8/rubygems/custom\_require.rb:27:in  
> `gem_original_require': no such file to load -- RRD (LoadError) from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `require’  
> from rrdtoolTest00.rb:1

You need to have VC6 installed and its environment setup before  
running gem install (call vsvars32.bat).  
After you do that, make sure nmake.exe in in your %PATH%.

The binary distribution doesn’t contain the ruby extension, you are  
looking for binary GEM, but rubyforge has only source one.

Jano

---

<div class="post-metadata">

**Author:** ![ribes](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/f4b2a3/32.png) [@ribes](https://www.ruby-forum.com/u/ribes)\
**Post date:** [March 31, 2008, 3:29pm UTC](https://www.ruby-forum.com/t/problems-installing-rrdtool-gem-under-windows/133426/3 "2008-03-31T15:29:48Z")

</div>

I assumed VC6 = Visual C Version 6. If this is correct, then that does  
it  
for me, as I can’t get a copy of that software.  
Is this the case even if a run the binary?

Thanks

Victor

---

<div class="post-metadata">

**Author:** ![ribes](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/f4b2a3/32.png) [@ribes](https://www.ruby-forum.com/u/ribes)\
**Post date:** [March 31, 2008, 4:19pm UTC](https://www.ruby-forum.com/t/problems-installing-rrdtool-gem-under-windows/133426/4 "2008-03-31T16:19:57Z")

</div>

Answer: Because it makes it difficult to follow a conversation.  
Question: Why is Top-posting bad?

Victor R. wrote:

> Is this the case even if a run the binary?

If the binary gem contains the pr-compiled extension, you won’t need a  
compiler to compile it. If there is no pre-compiled extension available,  
then you won’t be able to use the gem.

Ask the maintainers of the package, if they can supply a pre-compiled  
binary.

Another solution: [http://www.linux.org/](http://www.linux.org/)

–Phillip G.

---

<div class="post-metadata">

**Author:** ![ribes](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/f4b2a3/32.png) [@ribes](https://www.ruby-forum.com/u/ribes)\
**Post date:** [March 31, 2008, 6:28pm UTC](https://www.ruby-forum.com/t/problems-installing-rrdtool-gem-under-windows/133426/5 "2008-03-31T18:28:43Z")

</div>

On Mon, Mar 31, 2008 at 3:29 PM, Victor R. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
wrote:

> I assumed VC6 = Visual C Version 6. If this is correct, then that does it  
> for me, as I can’t get a copy of that software.  
> Is this the case even if a run the binary?

What you are looking for is rrd extension, that is a .dll linked  
against ruby and librrd.  
It makes a bridge between librrd and ruby - it allows you to call  
librrd from ruby.

In order to obtain the dll you have to compile it. Your assumption was  
right - VC6 is Visual C++ 6.  
It might be possible to use mingw gcc to compile it though.

I have VC6 installed, but unfortunately, the code #includes unistd.h,  
that is not included with VC6.  
So I can’t help here. Try the mingw32 way. You’ll need the development  
package of rrdtool - at least .h and .lib files.

Note: ruby extensions (=dlls) have .so extension (=file suffix)  
instead of usual .dll.

Another way to use rrdtool could be calling the exe file with proper  
parameters and parsing the result.  
For this you don’t need the extension.

J.
