View Single Post
Posts: 540 | Thanked: 387 times | Joined on May 2009
#4
Disclaimer: I don't have a N900 and do not have a Maemo5 scratchbox install. Nor have I played with any Meego dev kits.

Additionally I haven't played with GUI programs within scratchbox, QEMU is problematic. Best to majority of coding using gedit in Fedora, then move those files into scratchbox and do minor edits. Then compile in scratchbox and test using the device. (Scatchbox is NOT an identical environment as the device, nor is Scratchbox identical to Autobuilder/Cauldrin. They are simply "compatible" environments.)


HOWEVER, I DO have a Maemo4 scratchbox install up and running in Fedora 13.

The following are my notes to myself:

How-To Install Maemo4 Scratchbox in Fedora 13
WARNING: This will use over 2.5 GB of /

Code:
$ su -
# wget http://tablets-dev.nokia.com/4.1/maemo-scratchbox-install_4.1.sh
# chmod +x maemo-scratchbox-install_4.1.sh
Code:
# echo 0 > /proc/sys/vm/vdso_enabled
# echo 0 > /selinux/enforce
# ./maemo-scratchbox-install_4.1.sh -s /scratchbox
TAKES AWHILE
Code:
# /scratchbox/sbin/sbox_adduser linuxeventually
Add user linuxeventually to group 'sbox'? [yes/no] (yes): yes
Scratchbox user account for user linuxeventually added
REBOOT

Code:
$ su -
# wget http://tablets-dev.nokia.com/4.1/maemo-sdk-install_4.1.sh
# chmod +x maemo-sdk-install_4.1.sh
Code:
# /scratchbox/sbin/sbox_ctl start
# echo 0 > /proc/sys/vm/vdso_enabled
# echo 0 > /selinux/enforce
# ./maemo-sdk-install_4.1.sh
* Press space/more three times, then enter
* Choose option 4
* Yes to install Nokia binaries
* Continue (downloads a bunch of stuff)
* Press space/more 13 times, then type: I accept and enter


Code:
Installation was successful!
Happy hacking!
Code:
$ /scratchbox/login
> fakeroot apt-get install maemo-explicit
> exit
----------------

Code:
# startsb() { echo 0 > /proc/sys/vm/vdso_enabled; echo 0 > /selinux/enforce; /scratchbox/sbin/sbox_ctl start; echo 0 > /proc/sys/vm/mmap_min_addr; exit; }
Code:
# export EDITOR=nano; visudo
%wheel        ALL=(ALL)	NOPASSWD: ALL
linuxeventually ALL = (ALL) NOPASSWD: /usr/bin/maemosb
Code:
#!/bin/bash
#######################################
###Script saved to /usr/bin/maemosb ###
#######################################
echo 0 > /proc/sys/vm/vdso_enabled; 
echo 0 > /selinux/enforce; 
/scratchbox/sbin/sbox_ctl start; 
echo 0 > /proc/sys/vm/mmap_min_addr; 
exit;
Code:
# chmod +x /usr/bin/maemosb
# chmod 777 /usr/bin/maemosb
# chmod u+s /usr/bin/maemosb
Code:
$ msb() { sudo maemosb; /scratchbox/login; }
Code:
$ msb
Starting Scratchbox: binfmt_misc, mount.

Welcome to Scratchbox, the cross-compilation toolkit!

Use 'sb-menu' to change your compilation target.
See /scratchbox/doc/ for documentation.

[sbox-DIABLO_ARMEL: ~] >
--------------
NOTE: Replace all instances of linuxeventually with your Fedora username. If you have questions/problems, I'll try to help.


Don't be afraid of having a host distro other than a Debian-based distro. However do not try to mix in packages or libraries from your host OS. Keep scratchbox stuff in scratchbox.

Last edited by linuxeventually; 2010-12-20 at 19:29.
 

The Following 2 Users Say Thank You to linuxeventually For This Useful Post: