Page 1 of 2

Compiling with OCRA

PostPosted: Wed May 19, 2010 4:35 pm
by cavygalaxy
hey I have a problem...
whenever i compile a game with OCRA, there is no sound.
can someone help me?
thanks. :)

Re: Compiling with OCRA

PostPosted: Wed May 19, 2010 7:31 pm
by Groogy
A) You don't compile in ruby
B) What's OCRA?

Re: Compiling with OCRA

PostPosted: Wed May 19, 2010 8:44 pm
by cavygalaxy
Groogy wrote:A) You don't compile in ruby
B) What's OCRA?

A) Yes i can compile in ruby
B) OCRA is a compiler. look here.

Re: Compiling with OCRA

PostPosted: Wed May 19, 2010 9:15 pm
by shawn42
I'd suggest checking the dlls that you're specifying to ocra. I'm not sure if they all _all_ needed, but I've used SDL_mixer.dll, libogg-0.dll, libvorbis-0.dll, mikmod.dll.

You can see an example of an ocra'd app shell here:
http://github.com/downloads/shawn42/gamebox/gamebox_app.zip

Re: Compiling with OCRA

PostPosted: Thu May 20, 2010 1:42 am
by cavygalaxy
Thank You SO Much! :D

Re: Compiling with OCRA

PostPosted: Thu May 20, 2010 4:11 am
by Groogy
cool, never heard of OCRA before, looks nice except that it don't seem to support linux :(

And ocra isn't a compiler, far from it. It only makes an self-extracting exe file with the interpreter in it. The ruby code is still normal source code. To count as a compiler it has to convert the source to machine code like C

Re: Compiling with OCRA

PostPosted: Thu May 20, 2010 1:17 pm
by shawn42
Ocra uses the loose definition of compiler. That which compiles things together... =P

You are correct in that it doesn't compile your rubies into machine language.

Re: Compiling with OCRA

PostPosted: Fri May 21, 2010 6:42 am
by Groogy
I know this is kind of off-topic, but does anybody know if OCRA will support linux(Not counting the possibility of Wine)?

Re: Compiling with OCRA

PostPosted: Fri May 21, 2010 11:13 am
by shawn42
Doesn't seem off topic to me. ;)

OCRA doesn't support linux, you may want to look at rubyscript2exe.

Re: Compiling with OCRA

PostPosted: Fri May 21, 2010 2:23 pm
by Groogy
shawn42 wrote:OCRA doesn't support linux, you may want to look at rubyscript2exe.


But I think I read somewhere that rubyscript2exe was dropped? Does it support 1.9.x?