will create a file called HelloWorld_linux which runs on linux.
The problem is that I'm trying to make a single .exe for windows
users.
I rm -rf'd the script, and then used ruby gems to install
rubyscript2exe (although it was stored only on my /var partition and
had to be moved to my /usr/local/bin) and it produced the same result.
will create a file called HelloWorld_linux which runs on linux.
The problem is that I'm trying to make a single .exe for windows
users.
I rm -rf'd the script, and then used ruby gems to install
rubyscript2exe (although it was stored only on my /var partition and
had to be moved to my /usr/local/bin) and it produced the same result.
Compile Ruby with the MinGW32 cross compiler tools. AS to how to obtain
it, check your distro (`yum install mingw32-tools`, or some such thing).
The wxWidgets (*not* the wxRuby folks!) have an entry on how to use
MinGW32 to compile a windows binary:
~ The purpose of writing is to inflate weak ideas, obscure pure
reasoning, and
inhibit clarity. With a little practice, writing can be an intimidating and
impenetrable fog! -- Calvin
If you alternately pack the executable using 7za.exe (from the extras distribution) and p7zip, you can easily achieve this by compressing and then:
cp 7za.exe myapp.exe
cat archive.7z >> myapp.exe
or on windows, use copy /b.
···
On 13 Apr 2008, at 04:25, K. wrote:
I've downloaded rubyscript2exe, and:
$ ruby rubyscript2exe.rb HelloWorld.rb
will create a file called HelloWorld_linux which runs on linux.
The problem is that I'm trying to make a single .exe for windows
users.
I rm -rf'd the script, and then used ruby gems to install
rubyscript2exe (although it was stored only on my /var partition and
had to be moved to my /usr/local/bin) and it produced the same result.
It's possible to run Ruby for Windows on top of Wine on top of
Linux. And it's possible to run Ruby for Windows on Windows in
a virtual machine (e.g. VirtualBox) on top of Linux. In both
cases (depending on which virtual machine you're using), you
can access your native file system with your Ruby scripts.
RubyScript2Exe works in both cases.
I used to use the Wine option, but nowadays, I use the
VirtualBox option.
I don't think you can do that. Try running it under Wine.
I actually *think* it is possible but I never tried it on my own.
After all, one can cross-compile on Linux, for a windows system.
So I am pretty confident that all this *should* work, but I never tried,
and would probably not manage anyway - but someone out there would
definitely manage
I think it is possible to generate rubyscript2exe files on unix, BUT:
you'll need to rewrite dependency collecting.
It works by running the program and collecting all required files
(including the dll files). Since most probably you cannot
run the script under windows, you have to collect the files manually.
[1] show the generated file structure.
If you solve this problem, please let Erik know about it. He might be
interested.