Skip to content

Commit

Permalink
* brasero: Fix doinst.sh.
Browse files Browse the repository at this point in the history
* fcgi: Fix SlackBuild. Add doinst.sh.
* fcgiwrap: Upgraded to 1.1.0.
* lxdm: Testing version 0.5.2.
* nginx: Upgraded to 1.8.0. Depends on luajit.
* openrc: Upgraded to 0.18.3. Fix default runlevels using Slackware's init order.
  • Loading branch information
w41l committed Oct 28, 2015
1 parent 4792309 commit 6ea79e8
Show file tree
Hide file tree
Showing 38 changed files with 684 additions and 317 deletions.
6 changes: 3 additions & 3 deletions brasero/doinst.sh
@@ -1,7 +1,7 @@
if [ -x usr/bin/glib-compile-schemas -a -d usr/share/glib-2.0/schemas ]; then
usr/bin/glib-compile-schemas usr/share/glib-2.0/schemas 1>/dev/null 2>/dev/null
if [ -x /usr/bin/glib-compile-schemas -a -d usr/share/glib-2.0/schemas ]; then
/usr/bin/glib-compile-schemas usr/share/glib-2.0/schemas 1>/dev/null 2>/dev/null
fi

if [ -x /usr/bin/gtk-update-icon-cache -a -r /usr/share/icons/hicolor/icon-theme.cache ]; then
usr/bin/gtk-update-icon-cache -t -f usr/share/icons/hicolor 1>/dev/null 2>/dev/null
/usr/bin/gtk-update-icon-cache -t -f usr/share/icons/hicolor 1>/dev/null 2>/dev/null
fi
7 changes: 5 additions & 2 deletions fcgi/fcgi.SlackBuild
Expand Up @@ -74,6 +74,8 @@ sed -i 's/\r//' doc/fastcgi-prog-guide/ch2c.htm
# fix file permissions
chmod a-x include/fcgios.h libfcgi/os_unix.c

autoreconf -ivsf

chown -R root:root .
find . \
\( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
Expand All @@ -91,8 +93,9 @@ CXXFLAGS="$SLKCFLAGS" \
--libdir=/usr/lib$LIBDIRSUFFIX --includedir=/usr/include \
--mandir=/usr/man --infodir=/usr/info \
--sysconfdir=/etc \
--localstatedir=/var --sharedstatedir=/var/lib \
--disable-static --enable-shared
--localstatedir=/var \
--disable-static --enable-shared \
|| exit 1

make
make install DESTDIR=$PKG
Expand Down
14 changes: 14 additions & 0 deletions fcgiwrap/doinst.sh
@@ -0,0 +1,14 @@
config() {
NEW="$1"
OLD="$(dirname $NEW)/$(basename $NEW .new)"
# If there's no config file by that name, mv it over:
if [ ! -r $OLD ]; then
mv $NEW $OLD
elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then
# toss the redundant copy
rm $NEW
fi
# Otherwise, we leave the .new copy for the admin to consider...
}

config etc/rc.d/rc.fcgiwrap.new
22 changes: 13 additions & 9 deletions fcgiwrap/fcgiwrap.SlackBuild
Expand Up @@ -2,7 +2,7 @@

# Slackware build script for fcgiwrap

# Copyright 2012 Widya Walesa <walecha99@gmail.com>
# Copyright 2012-2015 Widya Walesa <walecha99@gmail.com>
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
Expand All @@ -24,10 +24,10 @@
# YOUR DATA IS DESTROYED, YOUR HOUSE BURNS DOWN OR YOUR DOG RUNS OFF.

PRGNAM=fcgiwrap
VERSION=1.0.3
BUILD=1
TAG="_wls"
NUMJOBS="-j4"
VERSION=${VERSION:-1.1.0}
BUILD=${BUILD:-1}
TAG=${TAG:-"_wls"}
NUMJOBS=${NUMJOBS:-"-j7"}

if [ -z "$ARCH" ]; then
case "$( uname -m )" in
Expand All @@ -46,6 +46,9 @@ DOCS="README.rst"
if [ "$ARCH" = "i486" ]; then
SLKCFLAGS="-O2 -pipe -march=i486 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "i586" ]; then
SLKCFLAGS="-O2 -pipe -march=i586 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -pipe -march=i686 -mtune=i686"
LIBDIRSUFFIX=""
Expand All @@ -63,7 +66,7 @@ rm -rf $PKG
mkdir -p $WRK $PKG $OUTPUT
cd $WRK
rm -rf $PRGNAM-$VERSION
tar xvf $CWD/$PRGNAM-$VERSION.tar.xz
tar xvf $CWD/$PRGNAM-$VERSION.tar.?z*
cd $PRGNAM-$VERSION

chown -R root:root .
Expand All @@ -74,16 +77,16 @@ find . \
-exec chmod 644 {} \;

autoreconf -ivsf
make clean

CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
./configure \
--build=$ARCH-slackware-linux --host=$ARCH-slackware-linux \
--build=$ARCH-slackware-linux \
--prefix=/usr \
--mandir=/man \
--sysconfdir=/etc \
--localstatedir=/var --sharedstatedir=/var/lib
--localstatedir=/var \
|| exit 1

make V=1

Expand All @@ -108,6 +111,7 @@ cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
cat $CWD/slack-required > $PKG/install/slack-required
cat $CWD/doinst.sh > $PKG/install/doinst.sh

cd $PKG
/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.txz
Expand Down
99 changes: 99 additions & 0 deletions lxdm/Xsession
@@ -0,0 +1,99 @@
#! /bin/sh
# Xsession - run as user

# This file is extracted from kde-workspace (kdm/kfrontend/genkdmconf.c)
# Copyright (C) 2001-2005 Oswald Buddenhagen <ossi@kde.org>

session=$1

# Note that the respective logout scripts are not sourced.
case $SHELL in
*/bash)
[ -z "$BASH" ] && exec $SHELL $0 "$@"
set +o posix
[ -f /etc/profile ] && . /etc/profile
if [ -f $HOME/.bash_profile ]; then
. $HOME/.bash_profile
elif [ -f $HOME/.bash_login ]; then
. $HOME/.bash_login
elif [ -f $HOME/.profile ]; then
. $HOME/.profile
fi
;;
*/zsh)
[ -z "$ZSH_NAME" ] && exec $SHELL $0 "$@"
[ -d /etc/zsh ] && zdir=/etc/zsh || zdir=/etc
zhome=${ZDOTDIR:-$HOME}
# zshenv is always sourced automatically.
[ -f $zdir/zprofile ] && . $zdir/zprofile
[ -f $zhome/.zprofile ] && . $zhome/.zprofile
[ -f $zdir/zlogin ] && . $zdir/zlogin
[ -f $zhome/.zlogin ] && . $zhome/.zlogin
emulate -R sh
;;
*/csh|*/tcsh)
# [t]cshrc is always sourced automatically.
# Note that sourcing csh.login after .cshrc is non-standard.
xsess_tmp=`mktemp /tmp/xsess-env-XXXXXX`
$SHELL -c "if (-f /etc/csh.login) source /etc/csh.login; if (-f ~/.login) source ~/.login; /bin/sh -c 'export -p' >! $xsess_tmp"
. $xsess_tmp
rm -f $xsess_tmp
;;
*) # Plain sh, ksh, and anything we do not know.
[ -f /etc/profile ] && . /etc/profile
[ -f $HOME/.profile ] && . $HOME/.profile
;;
esac

[ -f /etc/xprofile ] && . /etc/xprofile
[ -f $HOME/.xprofile ] && . $HOME/.xprofile

# run all system xinitrc shell scripts.
if [ -d /etc/X11/xinit/xinitrc.d ]; then
for i in /etc/X11/xinit/xinitrc.d/* ; do
if [ -x "$i" ]; then
. "$i"
fi
done
fi

# Load Xsession scripts
# OPTIONFILE, USERXSESSION, USERXSESSIONRC and ALTUSERXSESSION are required
# by the scripts to work
xsessionddir="/etc/X11/Xsession.d"
OPTIONFILE=/etc/X11/Xsession.options
USERXSESSION=$HOME/.xsession
USERXSESSIONRC=$HOME/.xsessionrc
ALTUSERXSESSION=$HOME/.Xsession

if [ -d "$xsessionddir" ]; then
for i in `ls $xsessionddir`; do
script="$xsessionddir/$i"
echo "Loading X session script $script"
if [ -r "$script" -a -f "$script" ] && expr "$i" : '^[[:alnum:]_-]\+$' > /dev/null; then
. "$script"
fi
done
fi

if [ -d /etc/X11/Xresources ]; then
for i in /etc/X11/Xresources/*; do
[ -f $i ] && xrdb -merge $i
done
elif [ -f /etc/X11/Xresources ]; then
xrdb -merge /etc/X11/Xresources
fi
[ -f $HOME/.Xresources ] && xrdb -merge $HOME/.Xresources

case $session in
"")
exec xmessage -center -buttons OK:0 -default OK "Sorry, $DESKTOP_SESSION is no valid session."
;;
failsafe)
exec xterm -geometry 80x24-0-0
;;
*)
eval exec ck-launch-session dbus-launch --sh-syntax --exit-with-session "$session"
;;
esac
exec xmessage -center -buttons OK:0 -default OK "Sorry, cannot execute $session. Check $DESKTOP_SESSION.desktop."
14 changes: 0 additions & 14 deletions lxdm/doinst.sh
Expand Up @@ -13,17 +13,3 @@ config() {

config etc/lxdm/lxdm.conf.new

if [ -x /usr/bin/update-mime-database ]; then
/usr/bin/update-mime-database /usr/share/mime >/dev/null 2>&1
fi

if [ -x /usr/bin/update-desktop-database ]; then
/usr/bin/update-desktop-database -q /usr/share/applications >/dev/null 2>&1
fi

if [ -e /usr/share/icons/hicolor/icon-theme.cache ]; then
if [ -x /usr/bin/gtk-update-icon-cache ]; then
/usr/bin/gtk-update-icon-cache -q /usr/share/icons/hicolor >/dev/null 2>&1
fi
fi

38 changes: 12 additions & 26 deletions lxdm/lxdm.SlackBuild
Expand Up @@ -2,7 +2,7 @@

# Slackware build script for lxdm

# Copyright 2012 Widya Walesa <walecha99@gmail.com>
# Copyright 2012-2015 Widya Walesa <walecha99@gmail.com>
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
Expand All @@ -24,22 +24,10 @@
# YOUR DATA IS DESTROYED, YOUR HOUSE BURNS DOWN OR YOUR DOG RUNS OFF.

PRGNAM=lxdm
VERSION=20121024
BUILD=1
VERSION=${VERSION:-0.5.2}
BUILD=${BUILD:-1}
TAG=${TAG:-_wls}
NUMJOBS=${NUMJOBS:--j4}

if ! grep "^lxdm:" /etc/group >/dev/null 2>&1; then
echo "Please add group lxdm";
echo "/usr/sbin/groupadd -g 52 lxdm";
exit 1;
fi

if ! grep "^lxdm:" /etc/passwd >/dev/null 2>&1; then
echo "Please add user lxdm";
echo "/usr/sbin/useradd -u 52 -g lxdm -s /bin/false -c \"LXDE Display Manager daemon\" -d /var/lib/lxdm lxdm";
exit 1;
fi
NUMJOBS=${NUMJOBS:--j7}

if [ -z "$ARCH" ]; then
case "$( uname -m )" in
Expand All @@ -58,6 +46,9 @@ DOCS="AUTHORS COPYING ChangeLog INSTALL NEWS README TODO"
if [ "$ARCH" = "i486" ]; then
SLKCFLAGS="-O2 -pipe -march=i486 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "i586" ]; then
SLKCFLAGS="-O2 -pipe -march=i586 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -pipe -march=i686 -mtune=i686"
LIBDIRSUFFIX=""
Expand All @@ -78,15 +69,16 @@ rm -rf $PRGNAM-$VERSION
tar xvf $CWD/$PRGNAM-$VERSION.tar.?z*
cd $PRGNAM-$VERSION

autoreconf -ivsf

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 {} \;

./autogen.sh

CC=clang \
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
./configure \
Expand All @@ -98,27 +90,21 @@ CXXFLAGS="$SLKCFLAGS" \
--mandir=/usr/man --infodir=/usr/info \
--sysconfdir=/etc --docdir=/usr/doc/$PRGNAM-$VERSION \
--localstatedir=/var --sharedstatedir=/var/lib \
--with-xconn=xcb \
--without-pam \
--enable-gtk3

make $NUMJOBS V=1

#cat $CWD/greeter.ui.patch | patch -p0
#cat $CWD/lxdm.patch | patch -p0
#cat $CWD/Xsession.patch | patch -p1

make V=1
make install DESTDIR=$PKG

( cd $PKG/etc/lxdm;
ln -s lxdm.conf default.conf;
rm lxdm.conf;
cat $CWD/lxdm.conf.new > lxdm.conf.new;
chmod 640 lxdm.conf.new;
chown lxdm:lxdm lxdm.conf.new;
)

mkdir -p $PKG/var/lib/lxdm
chown lxdm:lxdm $PKG/var/lib/lxdm
chmod 750 $PKG/var/lib/lxdm

find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \
Expand Down

0 comments on commit 6ea79e8

Please sign in to comment.