I''ve developed a WxRuby app that only runs under Windows. I''ve been using RubyScript2exe to build an executable for distribution, but it stopped working one day and I haven''t been able to figure out why. I''m also not very confident that it will work when I go to Ruby 1.9. What other options do I have? I could use InstallShield, or something like it to install ruby.exe along with my .rb files and any DLLs, etc. that I may need. Someone suggested that I switch to IronRuby and run my app with .NET''s DLR. Does WxRuby work with IronRuby? How are other people distributing WxRuby app on Windows? Eric Rubin _______________________________________________ wxruby-users mailing list wxruby-users@rubyforge.org http://rubyforge.org/mailman/listinfo/wxruby-users
Hi Eric Eric Rubin wrote:> > I?ve developed a WxRuby app that only runs under Windows. I?ve been > using RubyScript2exe to build an executable for distribution, but it > stopped working one day and I haven?t been able to figure out why. >Try packaging it so that error messages are put to the console and run it from the terminal. It should show what''s wrong.> What other options do I have? >http://rubyforge.org/pipermail/wxruby-users/2008-October/004248.html> I could use InstallShield, or something like it to install ruby.exe > along with my .rb files and any DLLs, etc. that I may need. Someone > suggested that I switch to IronRuby and run my app with .NET?s DLR. > Does WxRuby work with IronRuby? >Not AFAIK.> How are other people distributing WxRuby app on Windows? >I described how I do it here. http://rubyforge.org/pipermail/wxruby-users/2008-October/004258.html cheers alex
How long before you figure there will be a bytecode compiler deal (a la kava for perl) for 1.9? I would imagine this is one of the big giant reasons to use 1.9. -- Eric Will
Eric Will wrote:> How long before you figure there will be a bytecode compiler deal (a > la kava for perl) for 1.9? I would imagine this is one of the big > giant reasons to use 1.9.You can already save and load compiled instructions for the Ruby 1.9 virtual machine, using the VM::InstructionSequence class in Ruby core. However in the ruby distribution the method VM::InstructionSequence.load is disabled, but if you uncomment the relevant line (in iseq.c, near the end) and compile ruby, you can run ruby from saved VM instructions. I''ve tried it (to a limited extent) and it works. The reason it''s disabled is ''there is no verifier'' - which I believe in part reflects concern about cross-version compatibility of VM instructions - but if you''re distributing your own Ruby with your GUI app, this may not matter. a
On Mon, Mar 30, 2009 at 9:06 AM, Alex Fenton <alex at pressure.to> wrote:> You can already save and load compiled instructions for the Ruby 1.9 virtual > machine, using the VM::InstructionSequence class in Ruby core. However in > the ruby distribution the method VM::InstructionSequence.load is disabled, > but if you uncomment the relevant line (in iseq.c, near the end) and compile > ruby, you can run ruby from saved VM instructions. I''ve tried it (to a > limited extent) and it works.That''s very interesting, but not totally what I''m looking for. Kava for Perl is a total packager into an exe. Perhaps it compiles the bytecode and compresses the interpreter into an exe, I''m not sure. RubyScript2Exe is unacceptably slow, so if "extract exe and all libraries every time" is still the way to go, I can''t use that. The users of my GUI apps have no admin rights on their computers so I can''t install Ruby (or anything else). They only thing they can write to is a home directory on a network share. Right now I just have a version of Ruby shared on the network and we use that to run things, but it sucks. -- Eric Will
Eric Will wrote:> That''s very interesting, but not totally what I''m looking for. Kava > for Perl is a total packager into an exe. Perhaps it compiles the > bytecode and compresses the interpreter into an exe, I''m not sure. > RubyScript2Exe is unacceptably slow, so if "extract exe and all > libraries every time" is still the way to go, I can''t use that. The > users of my GUI apps have no admin rights on their computers so I > can''t install Ruby (or anything else). They only thing they can write > to is a home directory on a network share.To get round this - esp the time taken to unzip the ruby interpreter plus the (not small) wxruby libs plus everything else, I create a Windows installer using NSIS which installs a custom ruby, the ruby .dll and all the ruby library files needed. There''s some more details and links to the implementation code here: http://rubyforge.org/pipermail/wxruby-users/2008-October/004258.html a
I saw, but I can''t install anything on these machines. -- Eric Will / rakaur @ malkier On Mar 30, 2009, at 2:49 PM, Alex Fenton <alex at pressure.to> wrote:> Eric Will wrote: >> That''s very interesting, but not totally what I''m looking for. Kava >> for Perl is a total packager into an exe. Perhaps it compiles the >> bytecode and compresses the interpreter into an exe, I''m not sure. >> RubyScript2Exe is unacceptably slow, so if "extract exe and all >> libraries every time" is still the way to go, I can''t use that. The >> users of my GUI apps have no admin rights on their computers so I >> can''t install Ruby (or anything else). They only thing they can write >> to is a home directory on a network share. > > To get round this - esp the time taken to unzip the ruby interpreter > plus the (not small) wxruby libs plus everything else, I create a > Windows installer using NSIS which installs a custom ruby, the > ruby .dll and all the ruby library files needed. There''s some more > details and links to the implementation code here: > > http://rubyforge.org/pipermail/wxruby-users/2008-October/004258.html > > a > _______________________________________________ > wxruby-users mailing list > wxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/wxruby-users
I wish to point out another option, that I''ve come across dealing with something of other sorts. PortableApps. http://www.portableapps.com, They use a NSIS Script, that doesn''t actually install anything, but creates an Environment to execute a program, to keep it portable. If you look at the contents of one of their programs, you''ll see that the actual application is stored into a folder named apps, while the actual executable used to launch the application, is just an NullSoft Installer executable. Specifically look at this page, at Step 4: http://portableapps.com/development On Mon, Mar 30, 2009 at 5:02 PM, Eric Will <rakaur at malkier.net> wrote:> I saw, but I can''t install anything on these machines. > > -- > Eric Will / rakaur @ malkier > > > On Mar 30, 2009, at 2:49 PM, Alex Fenton <alex at pressure.to> wrote: > > Eric Will wrote: >> >>> That''s very interesting, but not totally what I''m looking for. Kava >>> for Perl is a total packager into an exe. Perhaps it compiles the >>> bytecode and compresses the interpreter into an exe, I''m not sure. >>> RubyScript2Exe is unacceptably slow, so if "extract exe and all >>> libraries every time" is still the way to go, I can''t use that. The >>> users of my GUI apps have no admin rights on their computers so I >>> can''t install Ruby (or anything else). They only thing they can write >>> to is a home directory on a network share. >>> >> >> To get round this - esp the time taken to unzip the ruby interpreter plus >> the (not small) wxruby libs plus everything else, I create a Windows >> installer using NSIS which installs a custom ruby, the ruby .dll and all the >> ruby library files needed. There''s some more details and links to the >> implementation code here: >> >> http://rubyforge.org/pipermail/wxruby-users/2008-October/004258.html >> >> a >> _______________________________________________ >> wxruby-users mailing list >> wxruby-users at rubyforge.org >> http://rubyforge.org/mailman/listinfo/wxruby-users >> > _______________________________________________ > wxruby-users mailing list > wxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/wxruby-users >-- Mario Steele http://www.trilake.net http://www.ruby-im.net http://rubyforge.org/projects/wxruby/ http://rubyforge.org/projects/wxride/ -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/wxruby-users/attachments/20090330/cab00b6d/attachment.html>
Eric Will wrote:> I saw, but I can''t install anything on these machines. > >> Eric Will wrote: >>> They only thing they can write >>> to is a home directory on a network share.Write permission to somewhere is enough to install with this approach. It uses a self-contained Ruby, so nothing needs to go in any system directory, and no changes to PATH are needed. I don''t have admin rights on my work machine but this don''t prevent me installing this way. Try using the Weft QDA 1.9 installer and setting the target directory to X:/MyStuff/Weft (or whatever your networked home dir is called): http://rubyforge.org/frs/download.php/35715/weft-qda-install-1.9.0.exe it''s only an alpha release but it should allow you to assess the viability of this approach. a