Ruby_init_loadpath() vs Win32

If I set RUBYLIB to “C:\phlip\tools\ruby-1.9.1-p0” before running an
embedded project - linked via Visual Studio to freshly-built LIBs in
that build tree - I get $: load paths with site_ruby off in evil-land:

[“C:\phlip\tools\ruby-1.9.1-p0\”,
“C:/WINDOWS/system32/lib/ruby/site_ruby/1.9.1”,
“C:/WINDOWS/system32/lib/ruby/site_ruby/1.9.1/i386-msvcr80”,
“C:/WINDOWS/system32/lib/ruby/site_ruby”… ]

site_ruby is neither there nor in the build tree. Then, naturally,
require ‘rubygems’ fails, and so on.

Please go easy on me, because I only have 10 years experience with
Ruby and 20 with C++…

On Sep 15, 9:28 am, Phlip [email protected] wrote:

require ‘rubygems’ fails, and so on.

Please go easy on me, because I only have 10 years experience with
Ruby and 20 with C++…

Are you linking to a shared library of ruby or statically linked?

Is VARIABLE_LIBPATH defined?

If not, then it grabs the path of where the shared library is located.

Perhaps that could lead to something?

(guessing after quick looking at the C code)