diff --git a/debian/changelog b/debian/changelog index 5dde7d1..cb98107 100644 --- a/debian/changelog +++ b/debian/changelog @@ -3,6 +3,8 @@ lubuntu-default-settings (0.9) UNRELEASED; urgency=low * usr/bin - Add export XLIB_SKIP_ARGB_VISUALS=1 to disable rgba support, since lxpanel doesn't support it. (See #589763) + - Add a new binary lubuntu-common, which is used by all startlubuntu* + binary. (LP: #579524). -- Julien Lavergne Sat, 12 Jun 2010 14:25:48 +0200 diff --git a/usr/bin/lubuntu-common b/usr/bin/lubuntu-common new file mode 100644 index 0000000..ece9802 --- /dev/null +++ b/usr/bin/lubuntu-common @@ -0,0 +1,59 @@ +#!/bin/sh + +#Workaround to disable rgba, because lxpanel doesn't support it (see bug #589763) +export XLIB_SKIP_ARGB_VISUALS=1 + +if [ -z "$XDG_CONFIG_HOME" ]; then + export XDG_CONFIG_HOME="$HOME/.config" +fi + +#Allow custom configuration files in /etc/xdg/lubuntu +#Patch stolen from Xubuntu +if test "x$XDG_CONFIG_DIRS" = "x" +then + XDG_CONFIG_DIRS="/etc/xdg/lubuntu:/etc/xdg" +else + XDG_CONFIG_DIRS="/etc/xdg/lubuntu/:$XDG_CONFIG_DIRS:/etc/xdg" +fi +export XDG_CONFIG_DIRS + +if test "x$XDG_DATA_DIRS" = "x" +then + XDG_DATA_DIRS="/etc/xdg/lubuntu:/usr/local/share:/usr/share:/usr/share" + else + XDG_DATA_DIRS="/etc/xdg/lubuntu:$XDG_DATA_DIRS:/usr/share" +fi +export XDG_DATA_DIRS + +# Ensure the existance of pcmanfm config file +PCMANFM_CONF_DIR="$XDG_CONFIG_HOME/pcmanfm" +if [ ! -f "$PCMANFM_CONF_DIR/main.lubuntu" ]; then + mkdir -p "$PCMANFM_CONF_DIR" + cp /usr/share/lubuntu/pcmanfm/main.lubuntu "$PCMANFM_CONF_DIR/main.lubuntu" +fi + +# Ensure the existance of openbox config file +OPENBOX_CONF_DIR="$XDG_CONFIG_HOME/openbox" +if [ ! -f "$OPENBOX_CONF_DIR/lubuntu-rc.xml" ]; then + mkdir -p "$OPENBOX_CONF_DIR" + cp /usr/share/lubuntu/openbox/rc.xml "$OPENBOX_CONF_DIR/lubuntu-rc.xml" +fi + +# Install custom QT configuration if no one is already installed +if [ ! -f "$XDG_CONFIG_HOME/Trolltech.conf" ]; then + cp /usr/share/lubuntu/qt/Trolltech.conf "$XDG_CONFIG_HOME/Trolltech.conf" +fi + +# Clean up after GDM (GDM sets the number of desktops to one) +xprop -root -remove _NET_NUMBER_OF_DESKTOPS -remove _NET_DESKTOP_NAMES -remove _NET_CURRENT_DESKTOP 2> /dev/null + +#Ensure the menu prefix +export XDG_MENU_PREFIX="lxde-" + +# Enable GTK+2 integration for OpenOffice.org, if available. +export SAL_USE_VCLPLUGIN=gtk + +# Launch DBus if needed +if which dbus-launch >/dev/null && test -z "$DBUS_SESSION_BUS_ADDRESS"; then + eval "$(dbus-launch --sh-syntax --exit-with-session)" +fi diff --git a/usr/bin/startlubuntu b/usr/bin/startlubuntu index 8f0bc73..97df9a3 100644 --- a/usr/bin/startlubuntu +++ b/usr/bin/startlubuntu @@ -1,62 +1,7 @@ #!/bin/sh -#Workaround to disable rgba, because lxpanel doesn't support it (see bug #589763) -export XLIB_SKIP_ARGB_VISUALS=1 - -if [ -z "$XDG_CONFIG_HOME" ]; then - export XDG_CONFIG_HOME="$HOME/.config" -fi - -#Allow custom configuration files in /etc/xdg/lubuntu -#Patch stolen from Xubuntu -if test "x$XDG_CONFIG_DIRS" = "x" -then - XDG_CONFIG_DIRS="/etc/xdg/lubuntu:/etc/xdg" -else - XDG_CONFIG_DIRS="/etc/xdg/lubuntu/:$XDG_CONFIG_DIRS:/etc/xdg" -fi -export XDG_CONFIG_DIRS - -if test "x$XDG_DATA_DIRS" = "x" -then - XDG_DATA_DIRS="/etc/xdg/lubuntu:/usr/local/share:/usr/share:/usr/share" - else - XDG_DATA_DIRS="/etc/xdg/lubuntu:$XDG_DATA_DIRS:/usr/share" -fi -export XDG_DATA_DIRS - -# Ensure the existance of pcmanfm config file -PCMANFM_CONF_DIR="$XDG_CONFIG_HOME/pcmanfm" -if [ ! -f "$PCMANFM_CONF_DIR/main.lubuntu" ]; then - mkdir -p "$PCMANFM_CONF_DIR" - cp /usr/share/lubuntu/pcmanfm/main.lubuntu "$PCMANFM_CONF_DIR/main.lubuntu" -fi - -# Ensure the existance of openbox config file -OPENBOX_CONF_DIR="$XDG_CONFIG_HOME/openbox" -if [ ! -f "$OPENBOX_CONF_DIR/lubuntu-rc.xml" ]; then - mkdir -p "$OPENBOX_CONF_DIR" - cp /usr/share/lubuntu/openbox/rc.xml "$OPENBOX_CONF_DIR/lubuntu-rc.xml" -fi - -# Install custom QT configuration if no one is already installed -if [ ! -f "$XDG_CONFIG_HOME/Trolltech.conf" ]; then - cp /usr/share/lubuntu/qt/Trolltech.conf "$XDG_CONFIG_HOME/Trolltech.conf" -fi - -# Clean up after GDM (GDM sets the number of desktops to one) -xprop -root -remove _NET_NUMBER_OF_DESKTOPS -remove _NET_DESKTOP_NAMES -remove _NET_CURRENT_DESKTOP 2> /dev/null - -#Ensure the menu prefix -export XDG_MENU_PREFIX="lxde-" - -# Enable GTK+2 integration for OpenOffice.org, if available. -export SAL_USE_VCLPLUGIN=gtk - -# Launch DBus if needed -if which dbus-launch >/dev/null && test -z "$DBUS_SESSION_BUS_ADDRESS"; then - eval "$(dbus-launch --sh-syntax --exit-with-session)" -fi +# Launch common scripts and env for Lubuntu. +exec /usr/bin/lubuntu-common # Start the LXDE session exec /usr/bin/lxsession -s Lubuntu -e LXDE diff --git a/usr/bin/startlubuntu-netbook b/usr/bin/startlubuntu-netbook index 5486bce..5a66d3e 100644 --- a/usr/bin/startlubuntu-netbook +++ b/usr/bin/startlubuntu-netbook @@ -1,62 +1,7 @@ #!/bin/sh -#Workaround to disable rgba, because lxpanel doesn't support it (see bug #589763) -export XLIB_SKIP_ARGB_VISUALS=1 - -if [ -z "$XDG_CONFIG_HOME" ]; then - export XDG_CONFIG_HOME="$HOME/.config" -fi - -#Allow custom configuration files in /etc/xdg/lubuntu -#Patch stolen from Xubuntu -if test "x$XDG_CONFIG_DIRS" = "x" -then - XDG_CONFIG_DIRS="/etc/xdg/lubuntu:/etc/xdg" -else - XDG_CONFIG_DIRS="/etc/xdg/lubuntu/:$XDG_CONFIG_DIRS:/etc/xdg" -fi -export XDG_CONFIG_DIRS - -if test "x$XDG_DATA_DIRS" = "x" -then - XDG_DATA_DIRS="/etc/xdg/lubuntu:/usr/local/share:/usr/share:/usr/share" - else - XDG_DATA_DIRS="/etc/xdg/lubuntu:$XDG_DATA_DIRS:/usr/share" -fi -export XDG_DATA_DIRS - -# Ensure the existance of pcmanfm config file -PCMANFM_CONF_DIR="$XDG_CONFIG_HOME/pcmanfm" -if [ ! -f "$PCMANFM_CONF_DIR/main.lubuntu" ]; then - mkdir -p "$PCMANFM_CONF_DIR" - cp /usr/share/lubuntu/pcmanfm/main.lubuntu "$PCMANFM_CONF_DIR/main.lubuntu" -fi - -# Ensure the existance of openbox config file -OPENBOX_CONF_DIR="$XDG_CONFIG_HOME/openbox" -if [ ! -f "$OPENBOX_CONF_DIR/lubuntu-rc.xml" ]; then - mkdir -p "$OPENBOX_CONF_DIR" - cp /usr/share/lubuntu/openbox/rc.xml "$OPENBOX_CONF_DIR/lubuntu-rc.xml" -fi - -# Install custom QT configuration if no one is already installed -if [ ! -f "$XDG_CONFIG_HOME/Trolltech.conf" ]; then - cp /usr/share/lubuntu/qt/Trolltech.conf "$XDG_CONFIG_HOME/Trolltech.conf" -fi - -# Clean up after GDM (GDM sets the number of desktops to one) -xprop -root -remove _NET_NUMBER_OF_DESKTOPS -remove _NET_DESKTOP_NAMES -remove _NET_CURRENT_DESKTOP 2> /dev/null - -#Ensure the menu prefix -export XDG_MENU_PREFIX="lxde-" - -# Enable GTK+2 integration for OpenOffice.org, if available. -export SAL_USE_VCLPLUGIN=gtk - -# Launch DBus if needed -if which dbus-launch >/dev/null && test -z "$DBUS_SESSION_BUS_ADDRESS"; then - eval "$(dbus-launch --sh-syntax --exit-with-session)" -fi +# Launch common scripts and env for Lubuntu. +exec /usr/bin/lubuntu-common # Start the LXDE session exec /usr/bin/lxsession -s Lubuntu-Netbook -e LXDE