From: "Christoph Müller" Date: 2011-01-13T18:56:54+09:00 Subject: Embedding Ruby Interpreter + RUBYGEMS Hello everybody, I'm currently writing a c++ library, in which i need to embedded a ruby interpreter for calling the Ruby API. I've read already some interesting topics about this issue and already got a working setup for my interpreter. Unfortanetely i need also access to all gems provided by rubygems and that is currently failing everytime. e.g. # is always working rb_require("rubygems") # will results always result in the LoadError: "no such file to load - facets" rb_require("facets") it seems rubygems can't expand completely the loadpath with all necessary gems and the embedded ruby interpreter can't find the locations for all this libraries. In the net i already found a promising solution for that problem: http://subforge.org/blogs/show/1 But this is currently not working on my machine and results in: "undefined reference to `Init_prelude' " (libruby1.8 is linked to my application) I guess, i should also mention, that i need to store all gems into another location and set up the environment variables GEM_HOME and GEM_PATH. require "facets" via irb is working. Does anyone know a fix workaround about this problem? I'm using Ruby 1.8.7 on Ubuntu 10.04 - 64Bit. Chris -- Posted via http://www.ruby-forum.com/.