<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://maemo.octonezd.me/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=192.100.116.142</id>
	<title>Maemo Wiki Mirror - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://maemo.octonezd.me/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=192.100.116.142"/>
	<link rel="alternate" type="text/html" href="https://maemo.octonezd.me/index.php/Special:Contributions/192.100.116.142"/>
	<updated>2026-04-22T08:43:27Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.45.1</generator>
	<entry>
		<id>https://maemo.octonezd.me/index.php?title=Icecream_Scratchbox_Howto&amp;diff=13277</id>
		<title>Icecream Scratchbox Howto</title>
		<link rel="alternate" type="text/html" href="https://maemo.octonezd.me/index.php?title=Icecream_Scratchbox_Howto&amp;diff=13277"/>
		<updated>2010-02-09T09:21:57Z</updated>

		<summary type="html">&lt;p&gt;192.100.116.142: Added a prerequisites section and some notes in the actual instructions.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;Original instructions written by Anderson Lizardo. This version copied verbatim from the INdT wiki.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
= Icecream + Scratchbox HOWTO =&lt;br /&gt;
&lt;br /&gt;
From Icecream web page &amp;lt;ref&amp;gt;http://en.opensuse.org/Icecream&amp;lt;/ref&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
&amp;quot;Icecream is created by SUSE and is based on ideas and code by distcc. Like&lt;br /&gt;
distcc it takes compile jobs from your build and distributes it to remote&lt;br /&gt;
machines allowing a parallel build on several machines you&#039;ve got.&amp;quot;&lt;br /&gt;
&lt;br /&gt;
This document describes how to use icrecream for parallel compilation inside&lt;br /&gt;
Scratchbox.&lt;br /&gt;
&lt;br /&gt;
== Prerequisites ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Skip this section if you have a working Icecream setup on your network.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Before attempting to use icecc with Scratchbox, be absolutely certain it runs without any issues on the host itself (and that the processes migrate properly in the network). Basic Icecream installation includes once machine running the scheduler and every participating host running the icecc daemon.&lt;br /&gt;
&lt;br /&gt;
On Ubuntu, a basic Icecream setup can be achieved by installing the package icecc on every participating host. On the scheduler, modify /etc/default/icecc to enable the scheduler daemon. If some host can&#039;t find the scheduler, modify /etc/icecc/icecc.conf to explicitly set the scheduler hostname.&lt;br /&gt;
&lt;br /&gt;
Make sure the host sees the scheduler by running icemon (package icecc-monitor on Ubuntu). You can leave icemon running to observe the task migration during compilations.&lt;br /&gt;
&lt;br /&gt;
To enable automatic distributed compilations on the host OS in Ubuntu, add the following snippet to $HOME/.bashrc:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# set the ICECC version and enable it by default&lt;br /&gt;
. /etc/lsb-release&lt;br /&gt;
procfamily=$(uname -m)&lt;br /&gt;
icecc_tarball=&amp;quot;$(readlink -f $HOME/icecc/icecc-$procfamily-$DISTRIB_CODENAME.tar.gz)&amp;quot;&lt;br /&gt;
if [ -f &amp;quot;$icecc_tarball&amp;quot; ]; then&lt;br /&gt;
    export ICECC_VERSION=$icecc_tarball&lt;br /&gt;
    export PATH=/usr/lib/icecc/bin:$PATH&lt;br /&gt;
    export MAKEFLAGS=-j12&lt;br /&gt;
fi&lt;br /&gt;
unset icecc_tarball procfamily DISTRIB_ID DISTRIB_RELEASE DISTRIB_CODENAME DISTRIB_DESCRIPTION&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that on other distributions than Ubuntu, you might have to modify this, depending on the contents on /etc/lsb-release.&lt;br /&gt;
&lt;br /&gt;
Then, create directory $HOME/icecc and run &amp;lt;pre&amp;gt;icecc --build-native&amp;lt;/pre&amp;gt; there. Symlink the created tarball to a descriptive name, e.g. icecc-i686-karmic.tar.gz (this name has to match the $icecc_tarball variable in the .bashrc snippet above).&lt;br /&gt;
&lt;br /&gt;
Now, open a new terminal and ensure that $ICECC_VERSION variable is set. Then run a test compilation to see that the compilation tasks really migrate to other hosts.&lt;br /&gt;
&lt;br /&gt;
Do not proceed beyond this point before you have made a test compilation and seen that your Icecream setup works as intended.&lt;br /&gt;
&lt;br /&gt;
== Compiling icecc ==&lt;br /&gt;
&lt;br /&gt;
To be able to use icecc both on ARM and x86 targets, we need to compile it use&lt;br /&gt;
the &amp;quot;special&amp;quot; host-gcc and host-g++ compilers inside a scratchbox target. The&lt;br /&gt;
binaries generated by these compilers can then be run from any target, because&lt;br /&gt;
they link to scratchbox own libraries.&lt;br /&gt;
&lt;br /&gt;
We will use only the icecc client, and share the icecc daemon with the host.&lt;br /&gt;
This allows using icecc both inside and outside scratchbox.&lt;br /&gt;
&lt;br /&gt;
To compile icecc, enter a scratchbox target (the architecture set on it is not&lt;br /&gt;
important) and unpack the icecc source tarball (you can download it from &amp;lt;ref&amp;gt;ftp://ftp.suse.com/pub/projects/icecream/&amp;lt;/ref&amp;gt;).&lt;br /&gt;
Next, enter the source directory and run:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbox &amp;gt; ./configure --prefix=/scratchbox/tools CC=host-gcc CXX=host-g++&lt;br /&gt;
sbox &amp;gt; make&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Installing icecc ==&lt;br /&gt;
&lt;br /&gt;
The next commands should be done outside scratchbox, as root.&lt;br /&gt;
&lt;br /&gt;
Copy the &amp;quot;client/icecc&amp;quot; binary to /scratchbox/tools/bin and a &amp;quot;icecc++&amp;quot;&lt;br /&gt;
symlink necessary for compiling C++ programs:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
host# cp -a client/icecc /scratchbox/tools/bin/icecc&lt;br /&gt;
host# ln -sfn icecc /scratchbox/tools/bin/icecc++&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Preparing toolchain tarballs ==&lt;br /&gt;
&lt;br /&gt;
To make sure that the correct compiler is used, it is necessary to create a&lt;br /&gt;
tarball containing all files required by the toolchain. This can be done either&lt;br /&gt;
manually, or by using the &amp;quot;icecc_create_env_sbox.sh&amp;quot; script.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Download [[Media:Icecc_create_env_sbox.sh|icecc_create_env_sbox.sh]] script.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;(Optional) Edit the script and change the &amp;quot;sbox_dir&amp;quot; variable, in case your scratchbox is not installed in /scratchbox&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Run the script for each target you wish to use icecc for. E.g.:&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
host$ ./icecc_create_env_sbox.sh FREMANTLE_ARMEL&lt;br /&gt;
host$ ./icecc_create_env_sbox.sh FREMANTLE_X86&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For each run, two files will be created:&lt;br /&gt;
* a tarball named &amp;lt;md5&amp;gt;.tar.gz, where &amp;lt;md5&amp;gt; is the MD5 signature of the tarball contents.&lt;br /&gt;
* a symbolic link to this tarball, named &amp;quot;icecc_box-&amp;lt;compiler_name&amp;gt;.tar.gz&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Place the tarballs in $HOME/icecc inside Scratchbox. These tarballs will be used later when running icecc. It is important that they uniquely identify the toolchain, because all peers in the build network will use the same tarball, and will cache the toolchain locally using that name. Therefore we use the MD5 signature, plus a symlink to easily map it to the actual Scratchbox toolchain name.&lt;br /&gt;
&lt;br /&gt;
== Using icecc ==&lt;br /&gt;
&lt;br /&gt;
In order to run icecc, you need to set the ICECC_VERSION environment variable&lt;br /&gt;
to point to the tarball created in previous section. Note that this variable&lt;br /&gt;
will be set to different values, depending on which target icecc will run (ARM&lt;br /&gt;
or x86).&lt;br /&gt;
&lt;br /&gt;
The ICECC_VERSION variable has the following format:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;build_architecture&amp;gt;:&amp;lt;cross_toolchain_for_target&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Hint:&lt;br /&gt;
&lt;br /&gt;
You can add the following snippet to ~/.bashrc (inside scratchbox) and have&lt;br /&gt;
that variable set automatically to the right value (change tarball names and&lt;br /&gt;
path accordingly):&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbox_compiler=&amp;quot;$(sb-conf show --compiler)&amp;quot;&lt;br /&gt;
# use the tarball name with the MD5, avoiding conflicting names in peer caches&lt;br /&gt;
icecc_tarball=&amp;quot;$(readlink -f $HOME/icecc_sbox-$sbox_compiler.tar.gz)&amp;quot;&lt;br /&gt;
if [ -f &amp;quot;$icecc_tarball&amp;quot; ]; then&lt;br /&gt;
    export ICECC_VERSION=&amp;quot;i486:$icecc_tarball&amp;quot;&lt;br /&gt;
    # comment the following line if you don&#039;t want to build in parallel by default&lt;br /&gt;
    MAKEFLAGS=&amp;quot;-j12&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
unset icecc_tarball sbox_compiler&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Done! To effectively use icecc to compile code, set the compiler to &amp;quot;icecc&amp;quot;.&lt;br /&gt;
This is usually done by setting the CC and CXX environment variables.&lt;br /&gt;
&lt;br /&gt;
== Using icecc &amp;quot;transparently&amp;quot; under Scratchbox ==&lt;br /&gt;
&lt;br /&gt;
Modifying build systems to use &amp;quot;icecc&amp;quot; instead of the defaults g++/gcc can be error prone. Therefore, the following instructions can be used to make it transparent:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Create a &amp;quot;/host_usr/bin&amp;quot; directory if it does not exist already:&amp;lt;/li&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;sbox &amp;gt; mkdir -p /host_usr/bin&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
(This directory is automatically added by Scratchbox to beginning of the PATH, therefore it is not necessary to add it manually.)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt;Create &amp;quot;gcc&amp;quot; and &amp;quot;g++&amp;quot; symlinks into that directory, pointing to icecc:&amp;lt;/li&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbox &amp;gt; ln -sfn /scratchbox/tools/bin/icecc /host_usr/bin/gcc&lt;br /&gt;
sbox &amp;gt; ln -sfn /scratchbox/tools/bin/icecc++ /host_usr/bin/g++&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt;Disable Scratchbox redirection for the gcc and g++ binaries:&amp;lt;/li&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbox &amp;gt; export SBOX_REDIRECT_IGNORE=/usr/bin/gcc,/usr/bin/g++&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The snippet above can be placed in .bashrc as well.&lt;br /&gt;
&lt;br /&gt;
You can now build applications normally and they will automatically use icecc when calling gcc or g++.&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Development]]&lt;br /&gt;
[[Category:Scratchbox]]&lt;/div&gt;</summary>
		<author><name>192.100.116.142</name></author>
	</entry>
	<entry>
		<id>https://maemo.octonezd.me/index.php?title=PyMaemo/FAQ&amp;diff=33304</id>
		<title>PyMaemo/FAQ</title>
		<link rel="alternate" type="text/html" href="https://maemo.octonezd.me/index.php?title=PyMaemo/FAQ&amp;diff=33304"/>
		<updated>2010-01-25T14:07:57Z</updated>

		<summary type="html">&lt;p&gt;192.100.116.142: /* What is PyMaemo? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== What is Python? ==&lt;br /&gt;
&lt;br /&gt;
Python is a dynamic object-oriented programming language that can be used for many kinds of software development. It offers strong support for integration with other languages and tools, comes with extensive standard libraries, and can be learned in a few days.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== What is PyMaemo? == &lt;br /&gt;
&lt;br /&gt;
PyMaemo is the Python distribution for Nokia&#039;s Linux-based Maemo devices, providing a comprehensive set of platform bindings for rapid application development.&lt;br /&gt;
&lt;br /&gt;
== What is Nokia&#039;s role in PyMaemo? ==&lt;br /&gt;
&lt;br /&gt;
Development and maintenance of PyMaemo is partially funded by Nokia. The project is community-supported and not part of the official Maemo SDK, providing us openness and flexibility of being able to continuously improve the packages using the maemo.org infrastructure instead of relying on the periodic SDK releases.&lt;br /&gt;
&lt;br /&gt;
== Does PyMaemo come installed by default? ==&lt;br /&gt;
&lt;br /&gt;
No, but there are some requirements and we expect to fulfill all of them in a near future.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Why to use two diferent .install files? ==&lt;br /&gt;
&lt;br /&gt;
Due to a limitation in Application Manager, only one repository can be handled by a .install file. PyMaemo depends on two repositories, to avoid duplication of packages. One repository contains base packages and another contains PyMaemo itself. This behaviour will change in a next release of Application Manager.&lt;br /&gt;
Why I get &amp;quot;missing dependencies&amp;quot; message when I try to install PyMaemo?&lt;br /&gt;
&lt;br /&gt;
Because you have to use both .install files (read previous question) as described at installation page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Why do some modules (e.g.: curses) are missing? ==&lt;br /&gt;
&lt;br /&gt;
In order to keep the platform small and supportable, PyMaemo only comes with the most commonly used packages.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Why do I get the error &amp;lt;put some error message here&amp;gt;? ==&lt;br /&gt;
&lt;br /&gt;
First make sure that you are running python2.5 explicitly, as python inside scratchbox defaults to scratchbox&#039; python (2.3)&lt;/div&gt;</summary>
		<author><name>192.100.116.142</name></author>
	</entry>
</feed>