Include Ruboto-Core with Android app on install
Asked Answered
B

1

11

I am trying to utilize Ruboto to code Android apps in JRuby with ease. However, when I install the app to the emulator using rake install, it works with side-effects.

When I launch the app on the emulator, I see a screen with the Ruboto image and it tells me that in order to continue, I need to install the Ruboto Core platform package. How can I do this with my main package so the user will not need to ever install the Ruboto Core on their own?

Bemire answered 20/10, 2012 at 20:30 Comment(0)
M
16

There's a couple ways to go about this. Generally, the idea is you include the jruby jars within the apk, which will increase the size, but will not require the user to download the core separately.

When creating the app, you could use the --with-jruby flag and it will include it for you. Since you've already created it, open the command prompt in the app directory and use

ruboto update jruby --force

This will add the jruby jars into the project for you as well.

Please note that in order to do this, you must have the jruby-jars installed, which can easily be done through gem install jruby-jars

EDIT: I was informed by Uwe Kubosch that you can also use ruboto gen jruby inside the application directory to accomplish the same thing.

Muley answered 21/10, 2012 at 15:44 Comment(1)
I did exactly that, the jruby jars are checked and copied into the project's /lib subfolder. Afterwards I compile and install the app again. The app on the device has now a different icon (not the typical ruboto one, but the more generic android app one) but when I click on it it still asks me to download Ruboto Core. Got any clue on what is possibly going not as planned?Battat

© 2022 - 2024 — McMap. All rights reserved.