![]() |
Running x86 programs on the n900.
Hi, i have managed to run maple on the n900 using qemu-i386 and native OpenJDK.
https://www.youtube.com/watch?v=MbtAgc1RU-4 Why? Because it was fun to try and i wanted to test the power of the n900. I actually did this a few years ago while studying maths but just recently got another n900 so i thought i would try it again and share it with you. It is very easy to do :). Which x86 apps would you like to see on the n900? // HOWTO (in maemo SDK): // in this howto i assume that MyDocs is ext3. if it is not either convert it or use different paths! // this is independant of the app you want to run // i had issues with qemu-kvm, therefore i built qemu myself // install python2.7 and set up update-alternatives $ git clone https://github.com/GNOME/glib $ cd glib $ git checkout glib-2-46 $ ./configure --enable-static $ make -j4 $ make install $ cd .. $ git clone https://github.com/krnlyng/qemu $ cd qemu $ git checkout n900hacks // system currently fails, i will look into it later // static is because i am working with i386 chroots too $ ./configure --static --prefix=/usr --disable-system // if you only need i386 add --target-list=i386-linux-user to speed up the build $ make -j4 $ make DESTDIR=~/qemuinstall install $ cd .. $ cd qemuinstall $ tar czvf ../qemu_git.tar.gz usr/ // upload the resulting tar gz file to your phone $ scp ../qemu_git.tar.gz user@phone:~/MyDocs // on phone $ sudo gainroot # tar xzvf /home/user/MyDocs/qemu_git.tar.gz -C / # using your favourite editor edit /usr/bin/binfmt_i386_init // copy and paste: Code:
#!/bin/sh # binfmt_i386_init # exit // now you can run i386 applications // IF YOU REBOOT you have to execute binfmt_i386_init as root before you can start i386 applications // OPTIONAL (but you most probably want to do this because without it there is not much use of qemu-i386) // download an x86 chroot (choose your favourite distribution) // or you can create one: https://wiki.debian.org/de/Debootstrap // or for arch linux users like me: https://wiki.archlinux.org/index.php...existing_Linux // (effectively: curl -O http://mirrors.kernel.org/archlinux/...-x86_64.tar.gz) // tar it up (if not already), copy it to your n900 and untar (i used ~/MyDocs/root.i686) // MAPLE // this is maple specific // for this the optional part from before is not optional ;) // on your phone // follow the instructions here: https://wiki.maemo.org/OpenJDK_6.0_0..._Labs)_on_N900 // note: the first two links are dead, use the third. // on your desktop // install maple 13 on an x86 machine, activate it. // tar it up, copy it to your n900 and untar (i used ~/MyDocs/maple13_i386) $ cd ~/MyDocs/maple13_i386/bin // edit activation, maple, mint, xmaple // in everyone of those files look for MAPLE=foo, replace it with MAPLE=/home/user/MyDocs/maple13_i386 // or use some fancy sed command ;) // edit maple look for "bin.IBM_INTEL_LINUX") // change MAPLE_JRE_BIN=foo to MAPLE_JRE_BIN="/opt/OpenJDK-camswl/jre/bin/" // change JRE_ROOT=foo to JRE_ROOT="/opt/OpenJDK-camswl/jre/lib" // change JRE_LIB3=foo to JRE_LIB3="$JRE_ROOT/arm/native_threads" // edit maple13.desktop and replace Exec=foo with this: Exec=/home/user/MyDocs/maple13_i386/bin/start_maple.sh // create a new file in the current directory: start_maple.sh // copy and paste this into the file (you have to replace root.i686 with your chroots name!): Code:
#!/bin/sh # cp maple13.desktop /usr/share/applications/hildon # exit // goto the app launcher and try it out :) // IF YOU REBOOT you have to execute binfmt_i386_init as root before you can start maple |
Re: Running x86 programs on the n900.
do you have any apps which you want to see on your N900? :)
|
Re: Running x86 programs on the n900.
Quote:
Quote:
|
Re: Running x86 programs on the n900.
Quote:
|
Re: Running x86 programs on the n900.
Quote:
|
Re: Running x86 programs on the n900.
Quote:
i will probably make deb packages or at least provide downloads... soon Quote:
Quote:
|
Re: Running x86 programs on the n900.
Thank you so much for posting this!
My favourite programming language only compiles on x86 and x64 and I so wanted to program on the way using my N900. Also I can adapt it for my raspberry. Speed isn't of concern for the finished software, I am just curious how much it will influence the IDE experience. I will try your guide next weekend. |
Re: Running x86 programs on the n900.
Quote:
|
Re: Running x86 programs on the n900.
Quote:
|
All times are GMT. The time now is 14:01. |
vBulletin® Version 3.8.8