SliTaz Packages

Community Doc Forum Pro Shop Bugs Hg
.

Receipt for package "openbox"

# SliTaz package receipt.

PACKAGE="openbox"
VERSION="3.6.1"
CATEGORY="x-window"
SHORT_DESC="Small-footprint and standard compliant Window Manager."
MAINTAINER="pankso@slitaz.org"
LICENSE="GPL2"
TARBALL="$PACKAGE-$VERSION.tar.gz"
WEB_SITE="http://openbox.org/"
WGET_URL="http://openbox.org/dist/openbox/$TARBALL"
TAGS="window-manager"
HOST_ARCH="i486 arm"

SUGGESTED="obconf spacefm pcmanfm hsetroot wbar2 conky"
DEPENDS="pango glib xorg-libX11 fontconfig freetype xorg-libXrandr \
xorg-libXft xorg-libXinerama xorg-libXcursor libxml2 slitaz-configs"
BUILD_DEPENDS=" pango-dev glib-dev xorg-libXft-dev util-linux-uuid-dev \
libxml2-dev xcb-util-dev python-xdg"

# Handle slitaz arch: /etc/slitaz/slitaz.conf
case "$SLITAZ_ARCH" in 
    i?86) DEPENDS="$DEPENDS startup-notification" ;;
    arm*) DEPENDS="$DEPENDS hsetroot tint2" ;;
esac

# Handle cross compilation
case "$ARCH" in 
    i?86) BUILD_DEPENDS="$BUILD_DEPENDS startup-notification-dev xorg-dev" ;;
esac

# What is the latest version available today?
current_version()
{
    wget -O - http://openbox.org/wiki/Openbox:Download 2>/dev/null | \
    sed "/$PACKAGE-/!d;/tar/!d;s|.*$PACKAGE-\\(.*\\).tar.*\".*|\\1|;q"
}

# Rules to configure and make the package.
compile_rules()
{
    chmod +x install-sh
    # Disable patch to avoid artefact with round corners (Adwaita theme)
    # Seem graphical perf issue if disable (report by Ceel)
    patch -p1 < ${stuff}/openbox-rounded.patch || exit 1

    # Patch from Arch
    #patch -p1 < $stuff/openbox-3.5.0-title-matching.patch
    #patch -p1 < $stuff/openbox-3.5.0-which-2.20.patch
    #patch -p1 < $stuff/debian-887908.patch
    #patch -p1 < $stuff/9ed6fdd71890c5cc43747f105382d5677e5d37e7.patch

    ./configure \
        --prefix=/usr \
        --sysconfdir=/etc \
        --libexecdir=/usr/lib/openbox \
        $CONFIGURE_ARGS &&
    sed -i 's/^mkdir_p = .*/mkdir_p = mkdir -p/' po/Makefile &&
    make &&
    make -j1 DESTDIR=$DESTDIR install &&
    rm -rf $install/usr/share/applications
}

# Rules to gen a SliTaz package suitable for Tazpkg.
genpkg_rules()
{
    mkdir -p $fs/usr/lib/openbox $fs/usr/share/themes
    cp -a $install/usr/bin $fs/usr
    cp -a $install/usr/lib/*.so* $fs/usr/lib
    cp -a $install/usr/lib/openbox $fs/usr/lib

    # We dont have GNOME or KDE
    rm $fs/usr/bin/openbox-gnome-session
    rm $fs/usr/bin/openbox-kde-session
    rm $fs/usr/bin/gnome-panel-control
    rm $fs/usr/bin/gdm-control
    chmod 0755 $fs/usr/bin/openbox-session

    # Python XDG script --> openbox-python
    rm -f $fs/usr/lib/openbox/openbox-xdg-autostart
    patch -p1 $fs/usr/lib/openbox/openbox-autostart \
        -i $stuff/openbox-autostart.patch || exit 1

    # Just Onyx Themes --> openbox-themes
    cp -a $install/usr/share/themes/Onyx* $fs/usr/share/themes

    # Xsessions
    cp -a $stuff/xsessions $fs/usr/share

    # Pipe menu.
    cp $stuff/open-folder-menu.sh $fs/usr/lib/openbox

    # Set perms.
    chown -R root.root $fs
}
6025 packages and 203154 files in current database (Thu Apr 25 06:17:47 2024)