全部博文(166)
分类: LINUX
2008-09-03 19:30:20
The first tool you have to install is Scratchbox. I suggest you to use the script provided but you could choose also to install it manually (in this case please refer to [this site] for detailed instructions).
Before beginning the installation of Scratchbox, you have to become root.
First of all set the permission of the script file:
chmod a+x ./maemo-scratchbox-install_4.0.1.sh
Then run it with these parameters:
./maemo-scratchbox-install_4.0.1.sh
Scratchbox environment will be installed in /scratchbox/
Once Scratchbox is installed, you have to add a user to the environment, in this way:
/scratchbox/sbin/sbox_adduser USER yes
where USER is your Linux username.
Please note that you'll have to logout and login again to be able to log into you new Scratchbox environment. To test it you simply have to start Scratchbox from your local user:
andy80@noteboontu:~/download/maemo_4.0.1$ /scratchbox/login
NOTE: on Ubuntu installation, you have to disable VDSO to make Scratchbox work fine, or you'll get errors like this:
Inconsistency detected by ld.so: rtld.c: 1192: dl_main: Assertion `(void *) ph->p_vaddr == _rtld_local._dl_sysinfo_dso' failed!
you can fix that executing this command from root user:
echo 0 | sudo tee /proc/sys/vm/vdso_enabled
Another problem you could have is related to mmap under Ubuntu Hardy, you can fix with this command:
echo 4096 | sudo tee /proc/sys/vm/mmap_min_addr
To make all these changes permanent after each reboot, you can edit /etc/sysctl.conf and add these lines:
vm.vdso_enabled = 0
vm.mmap_min_addr = 4096
then apply it in this way:
sysctl -p