Question

How does one install ruby-opengl-0.60.1 on Ubuntu?

I keep trying

$ gem install ruby-opengl --version 0.60.1

and I am running into the following error:

Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension
ERROR: 'rake/gempackagetask' is obsolete and no longer supported. Use 
'rubygems/package_task' instead.
/home/matias/.rvm/gems/ruby-1.9.3-p362@sampleGemset/gems/ruby-opengl-0.60.1/
Rakefile:24:in `<top (required)>'

Perhaps I could manually change the "package task" parameter in the Rakefile and then attempt a local gem install?...

I have found the following urls where the package can be downloaded for manual installation:

rubyforge.org/frs/?group_id=2103

launchpad.net/ubuntu/+source/ruby-opengl/0.60.1+dfsg1-2

And the following appears to be a patch or a small modification:

gist.github.com/tociyuki/2479308

I tried downloading the gem from the launchpad url, and then I tried $ gem install ruby-opengl-0.60.1.gem from the Downloads folder, and it gave me a ton of errors.

I eventually tried: $ sudo apt-get install libopengl-ruby

which seemed to work, and now when I do: $ gem list -r ruby-opengl I get:

\*** REMOTE GEMS \***
ruby-opengl (0.61.0, 0.60.0 i386-mswin32)
ruby-opengl2 (0.60.6)

I believe that i386-mswin32 is version 0.60.1 for windows.

With this configuration, I try running Sapphire.rb and it still doesn't work.

I already have ruby-opengl versions 0.60.0 and 0.61.0 installed, but I need 0.60.1 because it creates the 'gl', 'glu', and 'glut' extensions which are required in order to run some .rb files which I have copied from other people. These .rb files are video games created with the Gosu gem.

This is for use specifically with the Gosu gem. Even more specifically, I am trying to run the Sapphire game (github.com/KoBeWi/Sapphire), which also requires the Texplay gem.

Or is there another way to activate the 'gl', 'glu', and 'glut' extensions?

Was it helpful?

Solution

Thanks to the nice people at libgosu for providing the answer:

$ gem install opengl --pre

took care of everything! Now if someone else runs into this same difficulty, the answer is here!

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top