Openkore on Android

Forum closed. Read only permissions.

Moderator: Moderators

Message
Author
taskeox
Human
Human
Posts: 20
Joined: 09 Jun 2012, 04:45
Noob?: No

Openkore on Android

#1 Post by taskeox »

Is this much of a guide? I'm not sure... but here are the things I did, so hopefully you'll be able to do with with less speedbumps.

Requirements:
A relatively new phone with decent power! I tested with a Samsung Galaxy Nexus.
A rooted phone and busy box installed!
https://play.google.com/store/apps/deta ... on.busybox

Please first visit the following pages for light reading:
http://forum.xda-developers.com/showthr ... ?t=1585009
http://wiki.openkore.com/index.php/How_to_run_OpenKore

You'll also need a terminal emulator for your phone.
Personally, I'm using Android Terminal Emulator by Jack Palevich (Google play store). It's free and functional. You're free to use any one you like of course, but I have not tested those.
https://play.google.com/store/apps/deta ... ndroidterm

From the XDA link, you'll need the following files:
(Optional) Ubuntu Installer Free (Android APK)
•Boot Script
•Ubuntu 12.04 v2 Core/Small/Full
The Ubuntu Installer free is more or less a mini-guide that breaks everything down step-by-step for getting Ubuntu on Linux.
The boot script is mandatory
The Ubuntu image... You've got a choice really, depends if you'll be using linux for anything else. I went for core, since openkore is all text and I really don't need a GUI for it.

At this point, if you have installed the Ubuntu Installer Free, feel free to use it as a guide for installing Ubuntu, or continue reading.

Extract the Ubuntu image and bootscript into the same folder named Ubuntu in your root.

Now, open the terminal emulator and enter the following

Code: Select all

su
cd sdcard/ubuntu
sh ubuntu.sh
When prompted for a screen size, leave it blank and just hit enter.
Once the wall of text finishes, you should be left with:

Code: Select all

root@localhost:/#
Congratulations, you now have Ubuntu running on your Android.

Installing openkore:
Now, I only tested with Ubuntu core image, and it didn't have many of the libraries that openkore needs. But I'll go ahead and list them all out. Alternatively, they are available at the How to run Openkore link from above.

1. C++ compiler
- Check by entering

Code: Select all

g++ -v
- If no error, proceed to step 2. Otherwise, enter

Code: Select all

sudo apt-get install build-essential g++
- Once it finishes, please check again to ensure it was installed correctly.

2. Perl
- Check by entering

Code: Select all

perl -v
- If you see the perl version number, proceed to step 3. Otherwise, enter

Code: Select all

sudo apt-get install perl
- Once it finishes, please check again to ensure it was installed correctly.

3. Perl module: Time::HiRes
- Check by entering

Code: Select all

perl -e 'use Time::HiRes;'
- If nothing happens, proceed to step 4. Otherwise, enter

Code: Select all

sudo apt-get install libtime-hires-perl
4. Perl module: Compress::Zlib
- Check by entering

Code: Select all

perl -e 'use Compress::Zlib;'
- If nothing happens, proceed to step 5. Otherwise, enter

Code: Select all

sudo apt-get install libcompress-zlib-perl
5. GNU readline
- I was too lazy to follow the guide on checking if it exists. So I went ahead and just tried installing it anyways
Enter
sudo apt-get install libreadline5-dev
6. Python
- Enter

Code: Select all

sudo apt-get install python
7. Curl
- Enter

Code: Select all

curl-config --version
- If you get "Command not found", enter

Code: Select all

sudo apt-get install libcurl3-dev
If it all installed correctly, you're now ready to get openkore up and running.
Download the openkore source code, as well as the config, table, and field files.
Extract all of them to a folder named openkore and place it into the root of your phone.

In ubuntu, enter
perl ./openkore.pl
If everything goes well, you should see the familiar wall of text openkore has. Otherwise, you screwed up somewhere with the libraries.

If you closed the terminal, you'll have to get back into Ubuntu before running openkore! That means you'll need to do this

Code: Select all

su
cd sdcard/ubuntu
sh ubuntu.sh
Then,

Code: Select all

cd sdcard/openkore
perl ./openkore.pl
One thing, if you find yourself unable to connect to the map server on your phone, goto control/timeouts.txt and change
maplogin 12 to maplogin 30.
Give it some time, you know.
Good luck!

Edit:
Also, it is HIGHLY recommended you turn "Take WifiLock" on inside the terminal emulator.

Tested working in Samsung Galaxy Nexus, AOKP B38, Lean Kernel 3.8.0
Tested working in HTC Thunderbolt, iKReaM.605.19 no sense, Lean Kernel 6.2.1.
Last edited by taskeox on 09 Jun 2012, 07:51, edited 1 time in total.

EternalHarvest
Developers
Developers
Posts: 1800
Joined: 05 Dec 2008, 05:42
Noob?: Yes

Re: Openkore on Android

#2 Post by EternalHarvest »

Probably it's best to put that on wiki, meanwhile linked this topic from main page.

altandf4
Noob
Noob
Posts: 4
Joined: 28 Oct 2010, 16:32
Noob?: Yes

Re: Openkore on Android

#3 Post by altandf4 »

I have some problem running on my Optimus3D
I had ubuntu small installed(lxde one)

when running perl openkore.pl i got:

Code: Select all

checking perl configuration ..(cache)yes
checking for C library ncurses... (cached) no
checking for GNU readline 4.3 or higher...(cached) yes
checking for libcurl...(cached) yes
so far openkore unable to compile XSTools.so

Code: Select all

failed to create symbolic link 'XSTools.so':operation nor permited
os.chdir('/sdcard/openkore')
scons: *** [src/auto/XSTools/XSTools.so] Error 1
scons: building terminated because of errors.
-e \e[1;31mCompilation failed.]
I have tried apt-get remove g++ and re install g++

and also tried apt-get libcunit1-ncurses-dev

I am still unable to run this properly.

Using openkore src from SVN revision 8041

I noticed that in auto/XSTools libXSTools.so did compile, but missing XSTool.so

Sorry that I cannot log the whole thing, I had no log in the terminal.
I did check g++ -v and its very long also :roll:

EternalHarvest
Developers
Developers
Posts: 1800
Joined: 05 Dec 2008, 05:42
Noob?: Yes

Re: Openkore on Android

#4 Post by EternalHarvest »

altandf4 wrote: failed to create symbolic link 'XSTools.so':operation nor permited

I noticed that in auto/XSTools libXSTools.so did compile, but missing XSTool.so
Maybe it's on file system which doesn't support symbolic links? Try to copy libXSTools.so to XSTools.so.

taskeox
Human
Human
Posts: 20
Joined: 09 Jun 2012, 04:45
Noob?: No

Re: Openkore on Android

#5 Post by taskeox »

As the error suggests, "operation not permitted" means exactly that.

However, I don't know enough about other phones to help you on this. I really only have a galaxy nexus and the HTC thunderbolt was from a friend. So whether it's a filesystem or just a permissions problem I can't say for sure.

I suggest messing around with busybox and make sure everything is straightened up on that end to see if it helps. Or try doing Fix Permissions in clockwork mod?

subumubutuku
Noob
Noob
Posts: 1
Joined: 24 Apr 2012, 13:20
Noob?: No

Re: Openkore on Android

#6 Post by subumubutuku »

i cant find bootscript on the xda link

taskeox
Human
Human
Posts: 20
Joined: 09 Jun 2012, 04:45
Noob?: No

Re: Openkore on Android

#7 Post by taskeox »

They changed the name to this:
Complete Linux Installer (NEW)

Just download that app, makes things easier.

jea921
Human
Human
Posts: 26
Joined: 08 Nov 2010, 02:49
Noob?: No

Re: Openkore on Android

#8 Post by jea921 »

paconfirm po

xperia arc ICS 4.0.4
build number 4.1.b.0.431

bilou
Noob
Noob
Posts: 6
Joined: 10 Nov 2012, 15:31
Noob?: No

Re: Openkore on Android

#9 Post by bilou »

Hello,

FYI I encountered the error "failed to create symbolic link 'XSTools.so':operation nor permited" on my Galaxy S2.

And it was indeed due to FAT32 SD_external and internal memory filesystem (that doesn't allow symbolic link...)

As a work around, I had to copy the openkore sources from my sd card to ... the unbuntu image filesystem. It works but it's quite difficult to maintain the bot config as the config files are not directly editable ( you have to modify it on your sd and overwrite them on the image unbuntu).

To ease your work, use --control and other command line argument and specify that your config files are on the SD (not symlink for config... oufff) http://openkore.com/index.php/Command_Line_Arguments

If you need it, I can review the first post procedure (thank to taskoew for it !).

Cya,
Bilou

EternalHarvest
Developers
Developers
Posts: 1800
Joined: 05 Dec 2008, 05:42
Noob?: Yes

Re: Openkore on Android

#10 Post by EternalHarvest »

bilou wrote: FYI I encountered the error "failed to create symbolic link 'XSTools.so':operation nor permited" on my Galaxy S2.

And it was indeed due to FAT32 SD_external and internal memory filesystem (that doesn't allow symbolic link...)
Probably you can just copy whatever was symlinked there and it should work.

Locked