Problem z instalacja gem'a

Mój problem jest następujący przeglądając joggera trafilem tu:
http://radarek.jogger.pl/2007/07/20/ruby-i-python-programowanie-gier/
problem zaczyna się już przy samej instalacji rubygame w ubuntu

terminal wypluwa mi:

badzok@badzok:~$ sudo gem install rubygame-2.0.1-i586-linux.gem
[sudo] password for badzok:
Building native extensions. This could take a while…
Successfully installed rubygame, version 2.0.1
Installing ri documentation for rubygame-2.0.1-i586-linux…

No definition for rbgm_surface_initialize

No definition for rbgm_ttf_initialize
Installing RDoc documentation for rubygame-2.0.1-i586-linux…

No definition for rbgm_surface_initialize

No definition for rbgm_ttf_initialize

Spróbuj zainstalować najnowszą wersję bezpośrednio z repozytorium rubygems (ta którą próbujesz instalować najwidoczniej nie jest już zgodna z libsdl który masz w ubuntu):

sudo gem install rubygame

Ja instalowałem to z paczki .gem bo robiłem to pod windowsem i musiałem manualnie ściągnąć i zainstalować (inaczej były problemy).

niestety i tym razem ten sam błąd :frowning:

edit:
hmmmmm instalacja powiodła sie . rozwiązaniem okazało się pobranie rubygame-2.1.0 z tad

http://rubyforge.org/frs/?group_id=5089

natomaist teraz interpreter coś szwankuje

irb(main):002:0> require 'rubygems' => true irb(main):003:0> require 'rubygame' Gem::Exception: can't activate rubygame (= 2.0.1), already activated rubygame-2.1.0] from /usr/lib/ruby/1.8/rubygems.rb:254:in `activate' from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `require' from /var/lib/gems/1.8/gems/rubygame-2.1.0/lib/rubygame.rb:25 from /usr/lib/ruby/1.8/rubygems/custom_require.rb:32:in `gem_original_require' from /usr/lib/ruby/1.8/rubygems/custom_require.rb:32:in `require' from (irb):3

badzok@badzok:~$ sudo gem install -l rubygame-2.1.0.gem Building native extensions. This could take a while... Successfully installed rubygame, version 2.1.0 Installing ri documentation for rubygame-2.1.0... Installing RDoc documentation for rubygame-2.1.0...

hmmm po instalacji gemow wszysko niby ładni bo:

[code]badzok:/home/badzok# gem1.8 install -l rubygame-2.1.0.gem
Building native extensions. This could take a while…
Successfully installed rubygame-2.1.0
1 gem installed
Installing ri documentation for rubygame-2.1.0…
Installing RDoc documentation for rubygame-2.1.0…
badzok:/home/badzok# gem1.8 list

*** LOCAL GEMS ***

actionmailer (2.2.2, 2.0.2)
actionpack (2.2.2, 2.0.2)
activerecord (2.2.2, 2.0.2)
activeresource (2.2.2, 2.0.2)
activesupport (2.2.2, 2.0.2)
daemons (1.0.10)
gem_plugin (0.2.3)
gettext (1.93.0)
memoize (1.2.3)
rails (2.2.2, 2.0.2)
rake (0.8.3)
rubygame (2.1.0)
rubygems-update (1.3.1)[/code]
i chyba powinienem sie cieszyc gdyby nie to ze:

irb(main):002:0> require 'rubygame' LoadError: no such file to load -- rubygame_core from /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require' from /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:31:in `require' from /usr/lib/ruby/gems/1.8/gems/rubygame-2.1.0/lib/rubygame.rb:25 from /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:36:in `gem_original_require' from /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:36:in `require' from (irb):2
a jak chce zrobic update

[code]badzok:/home/badzok# gem1.8 update
Updating installed gems
Updating rubygame
Building native extensions. This could take a while…
ERROR: While executing gem … (Gem::Installer::ExtensionBuildError)
ERROR: Failed to build gem native extension.

rake RUBYARCHDIR=/usr/lib/ruby/gems/1.8/gems/rubygame-2.4.0/lib RUBYLIBDIR=/usr/lib/ruby/gems/1.8/gems/rubygame-2.4.0/lib
/usr/lib/ruby/gems/1.8/gems/rubygame-2.4.0/Rakefile:40:Warning: Gem::manage_gems is deprecated and will be removed on or after March 2009.
/usr/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake/gempackagetask.rb:13:Warning: Gem::manage_gems is deprecated and will be removed on or after March 2009.
In file included from ext/rubygame/rubygame_main.c:22:
ext/rubygame/rubygame_shared.h:25:18: error: ruby.h: Nie ma takiego pliku ani katalogu
In file included from ext/rubygame/rubygame_main.c:22:
ext/rubygame/rubygame_shared.h:29: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘mRubygame’
ext/rubygame/rubygame_shared.h:30: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘eSDLError’
ext/rubygame/rubygame_shared.h:31: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘cSurface’
ext/rubygame/rubygame_shared.h:32: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘cRect’
ext/rubygame/rubygame_shared.h:33: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘mNamedResource’
ext/rubygame/rubygame_shared.h:36: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘make_symbol’

‘rbgm_surface_displayformat’
ext/rubygame/rubygame_surface.h:56: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘rbgm_surface_displayformatalpha’
ext/rubygame/rubygame_surface.h:58: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘rbgm_image_savebmp’
ext/rubygame/rubygame_surface.h:60: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘rbgm_transform_flip’
In file included from ext/rubygame/rubygame_main.c:30:
ext/rubygame/rubygame_time.h:26: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘cClock’ext/rubygame/rubygame_time.h:28: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘rbgm_time_wait’
ext/rubygame/rubygame_time.h:29: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘rbgm_time_delay’
ext/rubygame/rubygame_time.h:30: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘rbgm_time_getticks’
ext/rubygame/rubygame_main.c:32: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘rbgm_init’
ext/rubygame/rubygame_main.c:33: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘rbgm_quit’
ext/rubygame/rubygame_main.c:52: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘rbgm_keyname’
ext/rubygame/rubygame_main.c:76: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘rbgm_init’
ext/rubygame/rubygame_main.c:99: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘rbgm_quit’
ext/rubygame/rubygame_main.c: In function ‘Init_rubygame_core’:
ext/rubygame/rubygame_main.c:110: error: ‘mRubygame’ undeclared (first use in this function)
ext/rubygame/rubygame_main.c:110: error: (Each undeclared identifier is reported only once
ext/rubygame/rubygame_main.c:110: error: for each function it appears in.)
ext/rubygame/rubygame_main.c:110: warning: implicit declaration of function ‘rb_define_module’
ext/rubygame/rubygame_main.c:112: warning: implicit declaration of function ‘rb_define_module_function’
ext/rubygame/rubygame_main.c:112: error: ‘rbgm_init’ undeclared (first use in this function)
ext/rubygame/rubygame_main.c:113: error: ‘rbgm_quit’ undeclared (first use in this function)
ext/rubygame/rubygame_main.c:114: warning: implicit declaration of function ‘rb_define_singleton_method’ext/rubygame/rubygame_main.c:114: error: ‘rbgm_keyname’ undeclared (first use in this function)
ext/rubygame/rubygame_main.c:115: error: ‘cRect’ undeclared (first use in this function)
ext/rubygame/rubygame_main.c:115: warning: implicit declaration of function ‘rb_define_class_under’
ext/rubygame/rubygame_main.c:115: error: ‘rb_cArray’ undeclared (first use in this function)
ext/rubygame/rubygame_main.c:117: warning: implicit declaration of function ‘rb_hash_aset’
ext/rubygame/rubygame_main.c:117: warning: implicit declaration of function ‘rb_ivar_get’
ext/rubygame/rubygame_main.c:117: warning: implicit declaration of function ‘rb_intern’
ext/rubygame/rubygame_main.c:118: warning: implicit declaration of function ‘ID2SYM’
ext/rubygame/rubygame_main.c:119: warning: implicit declaration of function ‘rb_ary_new3’
ext/rubygame/rubygame_main.c:120: warning: implicit declaration of function ‘INT2NUM’
ext/rubygame/rubygame_main.c:139: warning: implicit declaration of function ‘rb_define_const’
ext/rubygame/rubygame_main.c:145: warning: implicit declaration of function ‘UINT2NUM’
rake aborted!
Command failed. Aborting.
/usr/lib/ruby/gems/1.8/gems/rubygame-2.4.0/Rakefile:60:in `try_shell’
(See full trace by running task with --trace)
(in /usr/lib/ruby/gems/1.8/gems/rubygame-2.4.0)
Compiling rubygame/rubygame_main.c

Gem files will remain installed in /usr/lib/ruby/gems/1.8/gems/rubygame-2.4.0 for inspection.
Results logged to /usr/lib/ruby/gems/1.8/gems/rubygame-2.4.0/gem_make.out[/code]

ext/rubygame/rubygame_shared.h:25:18: error: ruby.h: Nie ma takiego pliku ani katalogu

Jak na moje oko to skopane jest config ktory zostal wygenerowany, nie widzi naglowkow ruby. Wogole jesli to jest z paczek… moze trzeba dodac jakies ruby-devel ? albo cos :wink: Nie wiem, nie znam sie :stuck_out_tongue: nielubie paczek w ruby, nigdy dobrze nie dzialaja :wink: gdy chcesz cos dorzucic nie z paczek :stuck_out_tongue:

moze instalacja SDL cos poszla nie tak chociarz chyba dobrze bylo. Moze to byc powod?