M
Mike Wilson
I'm trying to put an app together that I would need to run on quite a few
like systems, and I'd like to not have to install ruby on each one.
Currently, I'm trying to use miniruby to accomplish this. Is this an ok way
to go?
So, far I have a directory structure that looks like this:
/usr/local/myapp
/usr/local/myapp/runmyapp <- #!bin/miniruby ...
$LOAD_PATH << "lib"
/usr/local/myapp/bin/miniruby
/usr/local/myapp/lib/*.rb
/usr/local/myapp/lib/digest.so
/usr/local/myapp/lib/digest/md5.so
Which mostly works, except I need access to the md5 stuff and I seem to have
problems using it after copying the digest.so and md5.so into my lib
directory. Rather than printing an md5 hash when I do something like
digest.to_s, it prints the Object reference (#<MD5:0xe77b8>). Also, I have
to explicitly require "digest". I assume that I have some issue with
autoloading, but I'm not sure. Can anyone tell me how to fix this?
What's the best way to do this, or does everyone just install all of ruby?
_________________________________________________________________
Check your PC for viruses with the FREE McAfee online computer scan.
http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963
like systems, and I'd like to not have to install ruby on each one.
Currently, I'm trying to use miniruby to accomplish this. Is this an ok way
to go?
So, far I have a directory structure that looks like this:
/usr/local/myapp
/usr/local/myapp/runmyapp <- #!bin/miniruby ...
$LOAD_PATH << "lib"
/usr/local/myapp/bin/miniruby
/usr/local/myapp/lib/*.rb
/usr/local/myapp/lib/digest.so
/usr/local/myapp/lib/digest/md5.so
Which mostly works, except I need access to the md5 stuff and I seem to have
problems using it after copying the digest.so and md5.so into my lib
directory. Rather than printing an md5 hash when I do something like
digest.to_s, it prints the Object reference (#<MD5:0xe77b8>). Also, I have
to explicitly require "digest". I assume that I have some issue with
autoloading, but I'm not sure. Can anyone tell me how to fix this?
What's the best way to do this, or does everyone just install all of ruby?
_________________________________________________________________
Check your PC for viruses with the FREE McAfee online computer scan.
http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963