From c31681bf73cbc02d3f6207adf6ca6e80a832cde0 Mon Sep 17 00:00:00 2001 From: Eric Hameleers Date: Fri, 9 Jan 2015 14:38:37 +0100 Subject: New dependency for kwin: libepoxy. --- deps/alldeps.SlackBuild | 1 + deps/libepoxy/libepoxy.SlackBuild | 114 +++++++++++++++++++++ deps/libepoxy/slack-desc | 19 ++++ deps/libfakekey/slack-desc | 10 +- deps/updates.SlackBuild | 1 + kde/doinst.sh/sddm-qt5 | 40 ++++++++ kde/post-install/oxygen-fonts.post-install | 2 +- kde/post-install/plasma-desktop.post-install | 2 +- kde/post-install/plasma-workspace.post-install | 27 +++-- .../plasma-workspace/xinit/xinitrc.plasma | 24 ++--- .../plasma-workspace/xsession/kde5init | 19 ++-- kde/post-install/powerdevil.post-install | 2 +- kde/post-install/sddm-qt5.post-install | 9 ++ 13 files changed, 226 insertions(+), 44 deletions(-) create mode 100755 deps/libepoxy/libepoxy.SlackBuild create mode 100644 deps/libepoxy/slack-desc diff --git a/deps/alldeps.SlackBuild b/deps/alldeps.SlackBuild index 86bce1e..e3a5a67 100755 --- a/deps/alldeps.SlackBuild +++ b/deps/alldeps.SlackBuild @@ -47,6 +47,7 @@ ALLDEPS=" \ polkit-qt-1 \ polkit-qt5-1 \ poppler \ + libepoxy \ " # Allow for specification of individual packages to be built: diff --git a/deps/libepoxy/libepoxy.SlackBuild b/deps/libepoxy/libepoxy.SlackBuild new file mode 100755 index 0000000..a4fa0b9 --- /dev/null +++ b/deps/libepoxy/libepoxy.SlackBuild @@ -0,0 +1,114 @@ +#!/bin/sh + +# Copyright 2015 Eric Hameleers, Eindhoven, NL +# Copyright 2015 Patrick J. Volkerding, Sebeka, MN, USA +# All rights reserved. +# +# Redistribution and use of this script, with or without modification, is +# permitted provided that the following conditions are met: +# +# 1. Redistributions of this script must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ''AS IS'' AND ANY EXPRESS OR IMPLIED +# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO +# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; +# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR +# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +PKGNAM=libepoxy +VERSION=${VERSION:-1.2} +BUILD=${BUILD:-1} + +# Automatically determine the architecture we're building on: +if [ -z "$ARCH" ]; then + case "$(uname -m)" in + i?86) ARCH=i486 ;; + arm*) readelf /usr/bin/file -A | egrep -q "Tag_CPU.*[4,5]" && ARCH=arm || ARCH=armv7lh ;; + # Unless $ARCH is already set, use uname -m for all other archs: + *) ARCH=$(uname -m) ;; + esac + export ARCH +fi + +CWD=$(pwd) +TMP=${TMP:-/tmp} +PKG=$TMP/package-$PKGNAM + +if [ "$ARCH" = "i486" ]; then + SLKCFLAGS="-O2 -march=i486 -mtune=i686" + SLKLDFLAGS="" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "x86_64" ]; then + SLKCFLAGS="-O2 -fPIC" + SLKLDFLAGS="-L/usr/lib64" + LIBDIRSUFFIX="64" +elif [ "$ARCH" = "armv7hl" ]; then + SLKCFLAGS="-O3 -march=armv7-a -mfpu=vfpv3-d16" + SLKLDFLAGS="" + LIBDIRSUFFIX="64" + LIBDIRSUFFIX="" +else + SLKCFLAGS="-O2" + SLKLDFLAGS="" + LIBDIRSUFFIX="" +fi + +case "$ARCH" in + arm*) TARGET=$ARCH-slackware-linux-gnueabi ;; + *) TARGET=$ARCH-slackware-linux ;; +esac + +rm -rf $PKG +mkdir -p $TMP $PKG +cd $TMP + +rm -rf $PKGNAM-$VERSION +tar xvf $CWD/$PKGNAM-$VERSION.tar.?z* || exit 1 +cd $PKGNAM-$VERSION || exit 1 + +# Make sure ownerships and permissions are sane: +chown -R root:root . +find . \ + \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \ + -exec chmod 755 {} \; -o \ + \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ + -exec chmod 644 {} \; + +# Configure: +[ ! -x configure ] && ./autogen.sh +CFLAGS="$SLKCFLAGS" \ +CXXFLAGS="$SLKCFLAGS" \ +LDFLAGS="$SLKLDFLAGS" \ +./configure \ + --prefix=/usr \ + --libdir=/usr/lib${LIBDIRSUFFIX} \ + --build=$TARGET + +# Build and install: +make || exit 1 +make install DESTDIR=$PKG || exit 1 + +# Strip binaries (if any): +find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \ + | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true + +# Add documentation: +mkdir -p $PKG/usr/doc/$PKGNAM-$VERSION +cp -a \ + COPYING README* \ + $PKG/usr/doc/$PKGNAM-$VERSION + +# Add a package description: +mkdir -p $PKG/install +cat $CWD/slack-desc > $PKG/install/slack-desc + +# Build the package: +cd $PKG +/sbin/makepkg -l y -c n $TMP/$PKGNAM-$VERSION-$ARCH-$BUILD.txz + diff --git a/deps/libepoxy/slack-desc b/deps/libepoxy/slack-desc new file mode 100644 index 0000000..983ca50 --- /dev/null +++ b/deps/libepoxy/slack-desc @@ -0,0 +1,19 @@ +# HOW TO EDIT THIS FILE: +# The "handy ruler" below makes it easier to edit a package description. +# Line up the first '|' above the ':' following the base package name, and +# the '|' on the right side marks the last column you can put a character in. +# You must make exactly 11 lines for the formatting to be correct. It's also +# customary to leave one space after the ':' except on otherwise blank lines. + + |-----handy-ruler------------------------------------------------------| +libepoxy: libepoxy (OpenGL management library) +libepoxy: +libepoxy: Epoxy is a library for handling OpenGL function pointer management. +libepoxy: It tries to solve some of GLEW's problems for which it is a +libepoxy: replacement - in particular support for GLES and EGL. +libepoxy: +libepoxy: +libepoxy: +libepoxy: See also: +libepoxy: https://github.com/anholt/libepoxy/releases +libepoxy: diff --git a/deps/libfakekey/slack-desc b/deps/libfakekey/slack-desc index 0195f18..aeb23d5 100644 --- a/deps/libfakekey/slack-desc +++ b/deps/libfakekey/slack-desc @@ -9,11 +9,11 @@ libfakekey: libfakekey (X Virtual Keyboard Library) libfakekey: libfakekey: X virtual keyboard library of the Matchbox WM project. -libfakekey: -libfakekey: -libfakekey: -libfakekey: +libfakekey: +libfakekey: +libfakekey: +libfakekey: libfakekey: libfakekey: See also: libfakekey: https://www.yoctoproject.org/tools-resources/projects/matchbox -libfakekey: +libfakekey: diff --git a/deps/updates.SlackBuild b/deps/updates.SlackBuild index 7017fc5..858abe6 100755 --- a/deps/updates.SlackBuild +++ b/deps/updates.SlackBuild @@ -41,6 +41,7 @@ ALLDEPS=" \ phonon \ phonon-gstreamer \ polkit-qt5-1 \ + libepoxy \ " # Allow for specification of individual packages to be built: diff --git a/kde/doinst.sh/sddm-qt5 b/kde/doinst.sh/sddm-qt5 index cd5ea21..ed9aee6 100644 --- a/kde/doinst.sh/sddm-qt5 +++ b/kde/doinst.sh/sddm-qt5 @@ -13,3 +13,43 @@ config() { config etc/sddm.conf.new +# Create the daemon account and homedirectory otherwise SDDM won't start: +sddmuid=64 +sddmgid=64 +sddmhome=/var/lib/sddm + +if ! chroot . getent group sddm > /dev/null; then + chroot . groupadd -g $sddmgid sddm + res=$? + if [ $res -ne 0 ]; then +cat < /dev/null; then + useradd -c "SDDM Daemon Owner" -d $sddmhome -u $sddmuid \ + -g sddm -s /bin/false sddm + res=$? + if [ $res -ne 0 ]; then + cat < /dev/null + fi +fi + +mkdir -p $sddmhome +chown -R sddm:sddm $sddmhome > /dev/null + diff --git a/kde/post-install/oxygen-fonts.post-install b/kde/post-install/oxygen-fonts.post-install index 0b23495..300b6c5 100755 --- a/kde/post-install/oxygen-fonts.post-install +++ b/kde/post-install/oxygen-fonts.post-install @@ -1,5 +1,5 @@ # Install fonts: -FONTSDIR=/opt/kf5/share/fonts/oxygen +FONTSDIR=/usr/share/fonts/TTF/oxygen mkdir -p $PKG/$FONTSDIR find . -name "*.ttf" -exec install -m644 {} $PKG/$FONTSDIR \; diff --git a/kde/post-install/plasma-desktop.post-install b/kde/post-install/plasma-desktop.post-install index 1a86dad..10b156d 100644 --- a/kde/post-install/plasma-desktop.post-install +++ b/kde/post-install/plasma-desktop.post-install @@ -1,4 +1,4 @@ # Move the polkit dbus configuration files to the proper place: mkdir -p $PKG/etc -mv $PKG/opt/kf5//etc/dbus-1 $PKG/etc/ +mv $PKG/etc/kde/dbus-1 $PKG/etc/ diff --git a/kde/post-install/plasma-workspace.post-install b/kde/post-install/plasma-workspace.post-install index 6adbcb6..bb5ddec 100644 --- a/kde/post-install/plasma-workspace.post-install +++ b/kde/post-install/plasma-workspace.post-install @@ -7,35 +7,32 @@ cat $CWD/post-install/plasma-workspace/xinit/xinitrc.plasma \ > $PKG/etc/X11/xinit/xinitrc.plasma chmod 0755 $PKG/etc/X11/xinit/xinitrc.plasma -# Fix a path in the startkde script: -sed -e 's,/opt/kf5/lib64/libexec/kf5/start_kdeinit_wrapper,/usr/lib64/libexec/kf5/start_kdeinit_wrapper,' -i $PKG/opt/kf5/bin/startkde +## Fix a path in the startkde script: +#sed -e 's,/opt/kd5/lib64/libexec/kf5/start_kdeinit_wrapper,/usr/lib64/libexec/kf5/start_kdeinit_wrapper,' -i $PKG/opt/kf5/bin/startkde # Allow other login managers to show KDE Plasma2 desktop sessions: mkdir -p $PKG/usr/share/xsessions cat $CWD/post-install/plasma-workspace/xsession/kde5-plasma.desktop \ - | sed -e "s,@PREFIX@,/opt/kf5,g" \ + | sed -e "s,@PREFIX@,/usr,g" \ > $PKG/usr/share/xsessions/kde5-plasma.desktop cat $CWD/post-install/plasma-workspace/xsession/kde5-plasma-safe.desktop \ - | sed -e "s,@PREFIX@,/opt/kf5,g" \ + | sed -e "s,@PREFIX@,/usr,g" \ > $PKG/usr/share/xsessions/kde5-plasma-safe.desktop -mkdir -p $PKG/opt/kf5/bin +mkdir -p $PKG/usr/bin cat $CWD/post-install/plasma-workspace/xsession/kde5init \ - | sed -e "s,@PREFIX@,/opt/kf5,g" \ + | sed -e "s,@PREFIX@,/usr,g" \ -e "s,@LIBDIRSUFFIX@,$LIBDIRSUFFIX,g" \ - > $PKG/opt/kf5/bin/kde5init -chmod 755 $PKG/opt/kf5/bin/kde5init + > $PKG/usr/bin/kde5init +chmod 755 $PKG/usr/bin/kde5init # What is "plugins/plugins"? -mv $PKG/opt/kf5/lib64/qt5/plugins/{plugins,}/phonon_platform -rmdir $PKG/opt/kf5/lib64/qt5/plugins/plugins +mv $PKG/usr/lib64/qt5/plugins/{plugins,}/phonon_platform +rmdir $PKG/usr/lib64/qt5/plugins/plugins # Move the polkit dbus configuration files to the proper place: mkdir -p $PKG/etc -mv $PKG/opt/kf5//etc/dbus-1 $PKG/etc/ - -# Create a utility symlink - required on x86 but not on x86_64 ??? -ln -s /usr/lib${LIBDIRSUFFIX}/libexec/kf5 $PKG/opt/kf5/lib${LIBDIRSUFFIX}/libexec/ +mv $PKG//etc/kde/dbus-1 $PKG/etc/ # For shadow, this file needs to be setuid root just like the KDE4 version: -chmod +s $PKG/opt/kf5/lib$LIBDIRSUFFIX/libexec/kcheckpass +chmod +s $PKG/usr/lib$LIBDIRSUFFIX/libexec/kcheckpass diff --git a/kde/post-install/plasma-workspace/xinit/xinitrc.plasma b/kde/post-install/plasma-workspace/xinit/xinitrc.plasma index 18fd622..390020e 100644 --- a/kde/post-install/plasma-workspace/xinit/xinitrc.plasma +++ b/kde/post-install/plasma-workspace/xinit/xinitrc.plasma @@ -24,18 +24,18 @@ if [ -f $usermodmap ]; then xmodmap $usermodmap fi -# KDE Frameworks 5 plus Plasma Next: -export KF5=/opt/kf5 -export PATH=$KF5/bin:$KF5/lib@LIBDIRSUFFIX@/qt5/bin:$PATH -export QML2_IMPORT_PATH=$KF5/lib@LIBDIRSUFFIX@/qt5/qml:/usr/lib@LIBDIRSUFFIX@/qt5/qml -export QT_PLUGIN_PATH=$KF5/lib@LIBDIRSUFFIX@/qt5/plugins:/usr/lib@LIBDIRSUFFIX@/qt5/plugins -export XDG_CONFIG_DIRS=$KF5/etc/xdg:/etc/xdg:/etc/kde/xdg -export XDG_DATA_DIRS=$KF5/share:/usr/share:/usr/local/share - -export XDG_DATA_HOME="$HOME/.local5" -export XDG_CONFIG_HOME="$HOME/.config5" -export XDG_CACHE_HOME="$HOME/.cache5" -export KDEHOME="$HOME/.kde5" +## KDE Frameworks 5 plus Plasma Next: +#export KF5=/opt/kf5 +#export PATH=$KF5/bin:$KF5/lib@LIBDIRSUFFIX@/qt5/bin:$PATH +#export QML2_IMPORT_PATH=$KF5/lib@LIBDIRSUFFIX@/qt5/qml:/usr/lib@LIBDIRSUFFIX@/qt5/qml +#export QT_PLUGIN_PATH=$KF5/lib@LIBDIRSUFFIX@/qt5/plugins:/usr/lib@LIBDIRSUFFIX@/qt5/plugins +#export XDG_CONFIG_DIRS=$KF5/etc/xdg:/etc/xdg:/etc/kde/xdg +#export XDG_DATA_DIRS=$KF5/share:/usr/share:/usr/local/share + +#export XDG_DATA_HOME="$HOME/.local5" +#export XDG_CONFIG_HOME="$HOME/.config5" +#export XDG_CACHE_HOME="$HOME/.cache5" +#export KDEHOME="$HOME/.kde5" # Start the window manager: if [ -z "$DESKTOP_SESSION" -a -x /usr/bin/ck-launch-session ]; then diff --git a/kde/post-install/plasma-workspace/xsession/kde5init b/kde/post-install/plasma-workspace/xsession/kde5init index 75fb697..b9acc91 100644 --- a/kde/post-install/plasma-workspace/xsession/kde5init +++ b/kde/post-install/plasma-workspace/xsession/kde5init @@ -1,15 +1,16 @@ # KDE Frameworks 5 plus Plasma Next: export KF5=@PREFIX@ -export PATH=$KF5/bin:$KF5/lib@LIBDIRSUFFIX@/qt5/bin:$PATH -export QML2_IMPORT_PATH=$KF5/lib@LIBDIRSUFFIX@/qt5/qml:/usr/lib@LIBDIRSUFFIX@/qt5/qml -export QT_PLUGIN_PATH=$KF5/lib@LIBDIRSUFFIX@/qt5/plugins:/usr/lib@LIBDIRSUFFIX@/qt5/plugins -export XDG_CONFIG_DIRS=$KF5/etc/xdg:/etc/xdg:/etc/kde/xdg -export XDG_DATA_DIRS=$KF5/share:/usr/share:/usr/local/share -export XDG_DATA_HOME="$HOME/.local5" -export XDG_CONFIG_HOME="$HOME/.config5" -export XDG_CACHE_HOME="$HOME/.cache5" -export KDEHOME="$HOME/.kde5" +#export PATH=$KF5/bin:$KF5/lib@LIBDIRSUFFIX@/qt5/bin:$PATH +#export QML2_IMPORT_PATH=$KF5/lib@LIBDIRSUFFIX@/qt5/qml:/usr/lib@LIBDIRSUFFIX@/qt5/qml +#export QT_PLUGIN_PATH=$KF5/lib@LIBDIRSUFFIX@/qt5/plugins:/usr/lib@LIBDIRSUFFIX@/qt5/plugins +#export XDG_CONFIG_DIRS=$KF5/etc/xdg:/etc/xdg:/etc/kde/xdg +#export XDG_DATA_DIRS=$KF5/share:/usr/share:/usr/local/share + +#export XDG_DATA_HOME="$HOME/.local5" +#export XDG_CONFIG_HOME="$HOME/.config5" +#export XDG_CACHE_HOME="$HOME/.cache5" +#export KDEHOME="$HOME/.kde5" # Start the window manager: exec $KF5/bin/startkde "$*" diff --git a/kde/post-install/powerdevil.post-install b/kde/post-install/powerdevil.post-install index 1a86dad..19920d4 100644 --- a/kde/post-install/powerdevil.post-install +++ b/kde/post-install/powerdevil.post-install @@ -1,4 +1,4 @@ # Move the polkit dbus configuration files to the proper place: mkdir -p $PKG/etc -mv $PKG/opt/kf5//etc/dbus-1 $PKG/etc/ +mv $PKG//etc/kde/dbus-1 $PKG/etc/ diff --git a/kde/post-install/sddm-qt5.post-install b/kde/post-install/sddm-qt5.post-install index 0bcecce..a99ec44 100644 --- a/kde/post-install/sddm-qt5.post-install +++ b/kde/post-install/sddm-qt5.post-install @@ -6,6 +6,15 @@ rm -rf $PKG/etc/pam.d # Set the KDE5 theme 'breeze' as default, integrates better with Plasma 5: sed -i -e "s/^CurrentTheme.*/CurrentTheme=breeze/" $PKG/etc/sddm.conf +# SDDM follows the systemd convention of starting the first graphical session +# on tty1. We prefer the old convention where tty1 through tty6 +# are reserved for text consoles: +cat <> $PKG//etc/sddm.conf + +[XDisplay] +MinimumVT=7 +EOT + # Do not clobber existing configuration files: mv $PKG/etc/sddm.conf{,.new} -- cgit v1.2.3