Debian

From Openmoko

(Difference between revisions)
Jump to: navigation, search
(add image, sort and clean, add QtMoko in the derivative distributions)
Line 1: Line 1:
__NOTOC__
 
 
{{Languages|Debian}}
 
{{Languages|Debian}}
  
Line 10: Line 9:
 
''The current method of installation, install.sh, is not fail-proof. Work is progressing on a real debian-installer support.''
 
''The current method of installation, install.sh, is not fail-proof. Work is progressing on a real debian-installer support.''
  
== Showcase: Desktop Environments And Applications ==
+
== Debian Showcase: Desktop Environments And Applications ==
=== Illume ===
+
[[Image:Debian_illume_zhone.png|right|thumb|250px|Debian with illume, and Zhone running]]
+
[[Image:Debian_illume_zhone_kb.png|right|thumb|250px|Debian with illume, and Zhone running, with the on-screen keyboard visible]]
+
[[Illume]], the desktop environment used in recent openmoko distribution releases, is also available under Debian.  It's part of the Enlightenment window manager version 17 (which is currently in the alpha stage of development), which the Debian FSO package maintainers have placed in their repository.  If you have a Debian FSO system running, you can use the following commands to install illume.
+
  
apt-get install e17
+
=== fbpanel + Matchbox ===
  
Then use the following commands to ensure that it starts on boot.
+
It is not really a Desktop environment, but using fbpanel with Matchbox you can have a fast, lightweight, gtk2 desktop panel.
 
+
[[Image:Debian_fbpanel_zhone.png|right|thumb|300px|Debian with fbpanel, matchbox-window-manager and Zhone running, default settings]]
apt-get remove zhone-session
+
[[Image:Debian5.png|right|thumb|300px|Custom matchbox theme and fbpanel configuration.]]
apt-get install nodm
+
+
mv /root/.xsession /root/.xsession.backup
+
cat << END > /root/.xsession
+
#!/bin/sh
+
zhone &
+
enlightenment_start
+
END
+
 
+
<br style="clear:both" />
+
 
+
=== OpenOffice.org ===
+
[[Image:Freerunner_Debian_runs_openoffice3.jpg|right|thumb|300px|Debian running OpenOffice.org 3]]
+
  
Did we already mention you can install ''anything'' in Debian?
+
Quick howto:
 
+
<br style="clear:both" />
+
 
+
=== Matchbox With fbpanel ===
+
It is not really a Desktop environment, but using fbpanel with Matchbox you can have a fast, lightweight, gtk2 desktop panel.
+
[[Image:Debian_fbpanel_zhone.png|right|thumb|300px|Debian with fbpanel, matchbox-window-manager and Zhone running]]
+
 
<ol><li>Install fbpanel:
 
<ol><li>Install fbpanel:
<pre>sudo apt-get install fbpanel</pre></li>
+
<pre>sudo apt-get install fbpanel hicolor-icon-theme</pre></li>
 
<li>Customize the X startup process:
 
<li>Customize the X startup process:
 
<pre>~/.xsession</pre>
 
<pre>~/.xsession</pre>
Line 78: Line 54:
 
type = genmon
 
type = genmon
 
config {
 
config {
Command = echo -e $(grep "MemFree" /proc/meminfo | awk '{printf "%0.2f", $2 / 1024}') "|"\
+
Command = echo -e $(grep "MemFree" /proc/meminfo | \
$(cat /proc/loadavg | awk '{print $3}') "|" $(apm | awk '{print $5}')
+
awk '{printf "%0.2f", $2 / 1024}') "|"\
 +
$(cat /proc/loadavg | awk '{print $3}') "|" \
 +
$(apm | awk '{print $5}')
 
PollingTime = 60
 
PollingTime = 60
 
TextSize = small
 
TextSize = small
Line 91: Line 69:
 
sudo apt-get install gtk2-engines gtk-theme-switch
 
sudo apt-get install gtk2-engines gtk-theme-switch
 
DISPLAY=:0 gtk-theme-switch2</pre>
 
DISPLAY=:0 gtk-theme-switch2</pre>
Now choose your theme, font and save it. To see changes do 'killall fbpanel'.</li></ol>
+
Now choose your theme, font and save it. To see changes do 'killall fbpanel'. (killall requires psmisc package to be installed)</li></ol>
  
In order to use killall, install the psmisc package:
+
=== Illume ===
  apt-get install psmisc
+
[[Image:Debian_illume_zhone.png|right|thumb|250px|Debian with illume, and Zhone running]]
 +
[[Image:Debian_illume_zhone_kb.png|right|thumb|250px|Debian with illume, and Zhone running, with the on-screen keyboard visible]]
 +
[[Illume]], the desktop environment used in recent openmoko distribution releases, is also available under Debian. It's part of the Enlightenment window manager version 17 (which is currently in the alpha stage of development), which the Debian FSO package maintainers have placed in their repository.  If you have a Debian FSO system running, you can use the following commands to install illume.
  
Some of the icons rely on the hicolor-icon-theme:
+
apt-get install e17
  apt-get install hicolor-icon-theme
+
 
 +
Then use the following commands to ensure that it starts on boot.
 +
 
 +
apt-get remove zhone-session
 +
  apt-get install nodm
 +
 +
mv /root/.xsession /root/.xsession.backup
 +
cat << END > /root/.xsession
 +
#!/bin/sh
 +
zhone &
 +
enlightenment_start
 +
END
 +
 
 +
<br style="clear:both" />
  
 
=== LXDE ===
 
=== LXDE ===
Line 108: Line 101:
 
to launch it create a <code>/etc/init.d/lxde</code> script in the same way descripted for xfce4, replacing <code>startxfce4</code> occurrences with <code>startlxde</code>.
 
to launch it create a <code>/etc/init.d/lxde</code> script in the same way descripted for xfce4, replacing <code>startxfce4</code> occurrences with <code>startlxde</code>.
 
<div style="clear:right;">&nbsp;</div>
 
<div style="clear:right;">&nbsp;</div>
 +
 +
=== OpenOffice.org ===
 +
[[Image:Freerunner_Debian_runs_openoffice3.jpg|right|thumb|300px|Debian running OpenOffice.org 3]]
 +
 +
Did we already mention you can install ''anything'' in Debian?
 +
 +
<br style="clear:both" />
  
 
=== XFCE ===
 
=== XFCE ===
Line 147: Line 147:
 
<pre>username localhost = NOPASSWD: /usr/sbin/xfsm-shutdown-helper</pre>
 
<pre>username localhost = NOPASSWD: /usr/sbin/xfsm-shutdown-helper</pre>
  
==== Using matchbox-window-manager with XFCE ====
+
''' Using matchbox-window-manager with XFCE '''
  
 
XFCE's window manager is poorly configured for use with the FreeRunner.  Fortunately, matchbox's window manager is compatible with xfce.  To use the matchbox window manager, modify ~/.xsession as follows:
 
XFCE's window manager is poorly configured for use with the FreeRunner.  Fortunately, matchbox's window manager is compatible with xfce.  To use the matchbox window manager, modify ~/.xsession as follows:
Line 161: Line 161:
 
* [[Hackable1]] focuses on GNOME Mobile integration
 
* [[Hackable1]] focuses on GNOME Mobile integration
 
* [[Mer]] : based on [[Maemo]] ; see demo and download image at http://www.newlc.com/en/mer-best-maemo-debianubuntu-mobiles-watch-freerunner-demo
 
* [[Mer]] : based on [[Maemo]] ; see demo and download image at http://www.newlc.com/en/mer-best-maemo-debianubuntu-mobiles-watch-freerunner-demo
 +
* [[QtMoko]] - Debian with Qt Extended Improved plus configuration changes put manually on top of it
 
* [[Telefoninux]] http://telefoninux.projects.openmoko.org/index.html
 
* [[Telefoninux]] http://telefoninux.projects.openmoko.org/index.html
  
 
[[Category:Debian| ]]
 
[[Category:Debian| ]]

Revision as of 15:34, 14 March 2010


Debian is a universal operating system used on many other embedded devices, and also on home computers. Using Debian on the FreeRunner gives access to the Huge army of software packaged in the Debian repositories, already compiled for the Neo's arm(v4) processor. Moreover, one can build one's own source files for programs without having to learn the OpenEmbedded way. For example compiling natively is a snap with Debian, just apt-get gcc&libc-dev.

For an existing Debian/Ubuntu user, choosing Debian for Neo FreeRunner makes phone a very familiar, trustworthy and flexible place to hack in.

The bulk of information related to running Debian on FreeRunner is supposed to be at wiki.debian.org. For all installation, support or bug reporting needs please see DebianOnFreeRunner in the Debian wiki.

The current method of installation, install.sh, is not fail-proof. Work is progressing on a real debian-installer support.

Contents

Debian Showcase: Desktop Environments And Applications

fbpanel + Matchbox

It is not really a Desktop environment, but using fbpanel with Matchbox you can have a fast, lightweight, gtk2 desktop panel.

Debian with fbpanel, matchbox-window-manager and Zhone running, default settings
Custom matchbox theme and fbpanel configuration.

Quick howto:

  1. Install fbpanel:
    sudo apt-get install fbpanel hicolor-icon-theme
  2. Customize the X startup process:
    ~/.xsession
    #!/bin/sh
    export GTK_MODULES=libgtkstylus.so
    zhone &
    xsetroot -solid black
    matchbox-keyboard-toggle &
    matchbox-window-manager -use_titlebar yes &
    # -use_titlebar yes to minimize & toggle between apps
    # fbpanel's taskbar does not work with matchbox-window-manager
    #~/bin/auxlaunch &
    while true;
    do
    fbpanel;
    sleep 1;
    done;
    
  3. Read http://fbpanel.sourceforge.net/docs.html#config
    ~/.fbpanel/default
    mkdir ~/.fbpanel
    cp /etc/fbpanel/default ~/.fbpanel/default
    nano ~/.fbpanel/default
    

    Remove section with 'taskbar' plugin - it's useless with matchbox-window-manager. You may add plugin 'cpu'

    Plugin {
    type = cpu
    }

    Also, plugin 'genmon' is useful:

    Plugin {
    type = genmon
    config {
    Command = echo -e $(grep "MemFree" /proc/meminfo | \
     awk '{printf "%0.2f", $2 / 1024}') "|"\
    $(cat /proc/loadavg | awk '{print $3}') "|" \
     $(apm | awk '{print $5}')
    PollingTime = 60
    TextSize = small
    TextColor = darkblue
    }
    }
    After 'killall fbpanel' it will show: free mem in megabytes | loadavg | battery % left.
  4. Default theme is ugly. You can change it and / or make fonts bigger:
    ~/.gtkrc-2.0
    sudo apt-cache search gtk2-engines
    sudo apt-get install gtk2-engines gtk-theme-switch
    DISPLAY=:0 gtk-theme-switch2
    Now choose your theme, font and save it. To see changes do 'killall fbpanel'. (killall requires psmisc package to be installed)

Illume

Debian with illume, and Zhone running
Debian with illume, and Zhone running, with the on-screen keyboard visible

Illume, the desktop environment used in recent openmoko distribution releases, is also available under Debian. It's part of the Enlightenment window manager version 17 (which is currently in the alpha stage of development), which the Debian FSO package maintainers have placed in their repository. If you have a Debian FSO system running, you can use the following commands to install illume.

apt-get install e17

Then use the following commands to ensure that it starts on boot.

apt-get remove zhone-session
apt-get install nodm

mv /root/.xsession /root/.xsession.backup 
cat << END > /root/.xsession
#!/bin/sh
zhone &
enlightenment_start
END


LXDE

I you want a really nice desktop enviroment but you think XFCE is too fat, you can try to install LXDE. It give to you the GTK comfort, but use only a fraction of the ram needed by XFCE.

Debian with lxde and Zhone running

To install it:

apt-get install lxde

to launch it create a /etc/init.d/lxde script in the same way descripted for xfce4, replacing startxfce4 occurrences with startlxde.

 

OpenOffice.org

Debian running OpenOffice.org 3

Did we already mention you can install anything in Debian?


XFCE

The debian installation script installs by default the matchbox window manager. It doesn't feature a desktop environment. xfce is a small and lightweight desktop environment and so is quite fast for the FreeRunner.

apt-get install xfce4

Edit your .xsession to launch xfce4 at X startup :

#!/bin/sh
xfce4-session

Edit section [Failsafe Session] of /etc/xdg/xfce4-session/xfce4-session.rc (or ~/.config/xfce4-session/xfce4-session.rc) to handle the auto-started apps. For example:

[Failsafe Session]
Count=3
Client0_Command=xfce4-panel
Client0_PerScreen=False
Client1_Command=xfdesktop
Client1_PerScreen=False
Client2_Command=zhone
Client2_PerScreen=True

Start XFCE !

/etc/init.d/nodm restart

The desktop takes a while to start but once up was snappy as can be expected. I've not yet looked at the reason for the seemingly too slow start for the desktop.

zhone is available from the "Office" menu in xfce. The matchbox keyboard is available in "Accessories".

If you want to display the screen on the long side (ie rotated, 4:3 aspect), add the following to the /etc/X11/xorg.conf in both the Device and InputDevice sections :

Option          "Rotate"                "CCW"

and then (re)start xfce.

If you want to be able to shutdown/restart the device, add the following line to /etc/sudoers (don't forget to replace username with your actual username):

username localhost = NOPASSWD: /usr/sbin/xfsm-shutdown-helper

Using matchbox-window-manager with XFCE

XFCE's window manager is poorly configured for use with the FreeRunner. Fortunately, matchbox's window manager is compatible with xfce. To use the matchbox window manager, modify ~/.xsession as follows:

#!/bin/sh
exec matchbox-window-manager -use_titlebar no -use_cursor no &
xfce4-session

Derivative Distributions of Debian

Several distributions are sharing Debian's infrastructure - this is long known. For the Openmoko,

Personal tools


Debian is a universal operating system used on many other embedded devices, and also on home computers. Using Debian on the FreeRunner gives access to the Huge army of software packaged in the Debian repositories, already compiled for the Neo's arm(v4) processor. Moreover, one can build one's own source files for programs without having to learn the OpenEmbedded way. For example compiling natively is a snap with Debian, just apt-get gcc&libc-dev.

For an existing Debian/Ubuntu user, choosing Debian for Neo FreeRunner makes phone a very familiar, trustworthy and flexible place to hack in.

The bulk of information related to running Debian on FreeRunner is supposed to be at wiki.debian.org. For all installation, support or bug reporting needs please see DebianOnFreeRunner in the Debian wiki.

The current method of installation, install.sh, is not fail-proof. Work is progressing on a real debian-installer support.

Debian Showcase: Desktop Environments And Applications

fbpanel + Matchbox

It is not really a Desktop environment, but using fbpanel with Matchbox you can have a fast, lightweight, gtk2 desktop panel.

Debian with fbpanel, matchbox-window-manager and Zhone running, default settings
Custom matchbox theme and fbpanel configuration.

Quick howto:

  1. Install fbpanel:
    sudo apt-get install fbpanel hicolor-icon-theme
  2. Customize the X startup process:
    ~/.xsession
    #!/bin/sh
    export GTK_MODULES=libgtkstylus.so
    zhone &
    xsetroot -solid black
    matchbox-keyboard-toggle &
    matchbox-window-manager -use_titlebar yes &
    # -use_titlebar yes to minimize & toggle between apps
    # fbpanel's taskbar does not work with matchbox-window-manager
    #~/bin/auxlaunch &
    while true;
    do
    fbpanel;
    sleep 1;
    done;
    
  3. Read http://fbpanel.sourceforge.net/docs.html#config
    ~/.fbpanel/default
    mkdir ~/.fbpanel
    cp /etc/fbpanel/default ~/.fbpanel/default
    nano ~/.fbpanel/default
    

    Remove section with 'taskbar' plugin - it's useless with matchbox-window-manager. You may add plugin 'cpu'

    Plugin {
    type = cpu
    }

    Also, plugin 'genmon' is useful:

    Plugin {
    type = genmon
    config {
    Command = echo -e $(grep "MemFree" /proc/meminfo | \
     awk '{printf "%0.2f", $2 / 1024}') "|"\
    $(cat /proc/loadavg | awk '{print $3}') "|" \
     $(apm | awk '{print $5}')
    PollingTime = 60
    TextSize = small
    TextColor = darkblue
    }
    }
    After 'killall fbpanel' it will show: free mem in megabytes | loadavg | battery % left.
  4. Default theme is ugly. You can change it and / or make fonts bigger:
    ~/.gtkrc-2.0
    sudo apt-cache search gtk2-engines
    sudo apt-get install gtk2-engines gtk-theme-switch
    DISPLAY=:0 gtk-theme-switch2
    Now choose your theme, font and save it. To see changes do 'killall fbpanel'. (killall requires psmisc package to be installed)

Illume

Debian with illume, and Zhone running
Debian with illume, and Zhone running, with the on-screen keyboard visible

Illume, the desktop environment used in recent openmoko distribution releases, is also available under Debian. It's part of the Enlightenment window manager version 17 (which is currently in the alpha stage of development), which the Debian FSO package maintainers have placed in their repository. If you have a Debian FSO system running, you can use the following commands to install illume.

apt-get install e17

Then use the following commands to ensure that it starts on boot.

apt-get remove zhone-session
apt-get install nodm

mv /root/.xsession /root/.xsession.backup 
cat << END > /root/.xsession
#!/bin/sh
zhone &
enlightenment_start
END


LXDE

I you want a really nice desktop enviroment but you think XFCE is too fat, you can try to install LXDE. It give to you the GTK comfort, but use only a fraction of the ram needed by XFCE.

Debian with lxde and Zhone running

To install it:

apt-get install lxde

to launch it create a /etc/init.d/lxde script in the same way descripted for xfce4, replacing startxfce4 occurrences with startlxde.

 

OpenOffice.org

Debian running OpenOffice.org 3

Did we already mention you can install anything in Debian?


XFCE

The debian installation script installs by default the matchbox window manager. It doesn't feature a desktop environment. xfce is a small and lightweight desktop environment and so is quite fast for the FreeRunner.

apt-get install xfce4

Edit your .xsession to launch xfce4 at X startup :

#!/bin/sh
xfce4-session

Edit section [Failsafe Session] of /etc/xdg/xfce4-session/xfce4-session.rc (or ~/.config/xfce4-session/xfce4-session.rc) to handle the auto-started apps. For example:

[Failsafe Session]
Count=3
Client0_Command=xfce4-panel
Client0_PerScreen=False
Client1_Command=xfdesktop
Client1_PerScreen=False
Client2_Command=zhone
Client2_PerScreen=True

Start XFCE !

/etc/init.d/nodm restart

The desktop takes a while to start but once up was snappy as can be expected. I've not yet looked at the reason for the seemingly too slow start for the desktop.

zhone is available from the "Office" menu in xfce. The matchbox keyboard is available in "Accessories".

If you want to display the screen on the long side (ie rotated, 4:3 aspect), add the following to the /etc/X11/xorg.conf in both the Device and InputDevice sections :

Option          "Rotate"                "CCW"

and then (re)start xfce.

If you want to be able to shutdown/restart the device, add the following line to /etc/sudoers (don't forget to replace username with your actual username):

username localhost = NOPASSWD: /usr/sbin/xfsm-shutdown-helper

Using matchbox-window-manager with XFCE

XFCE's window manager is poorly configured for use with the FreeRunner. Fortunately, matchbox's window manager is compatible with xfce. To use the matchbox window manager, modify ~/.xsession as follows:

#!/bin/sh
exec matchbox-window-manager -use_titlebar no -use_cursor no &
xfce4-session

Derivative Distributions of Debian

Several distributions are sharing Debian's infrastructure - this is long known. For the Openmoko,