3

I'd like to deploy my Ruby application as an .exe file, for windows users. The application uses Tk for the GUI part.

Since I simply couldn't manage to succeed with rubyscript2exe I opted for ocra. Ocra works fine and builds a reasonable sized .exe. HOWEVER the application takes probably 10 seconds to start up. Even though it's really a quite simple tool.

Is there any way to improve startup-times? My guess is that the main issue is uncompressing the tk-libs on every startup...

ndbd
  • 2,417
  • 3
  • 23
  • 32

2 Answers2

2

I had this same issue with Tk, and it wouldn't work when using Ocra with InnoSetup.

I switched to Gtk, and now with Ocra + InnoSetup the GUI appears in 1-2 seconds rather than 10-20.

The reason is that Ocra with InnoSetup doesn't have to decompress the files into a temp directory, making it much faster to load once it's installed. Gtk seems more compatible with Ocra, and it seems to load faster than Tk anyway.

Virtuoso
  • 908
  • 1
  • 8
  • 14
2

Try building the executable with the --no-lzma option. The resulting file will start faster (but still slow).

Dariusz Woźniak
  • 9,640
  • 6
  • 60
  • 73