wok-6.x annotate slim-pam/receipt @ rev 25310

updated slim, slim-pam and slim-theme-default (1.3.5 -> 1.3.6)
author Hans-G?nter Theisgen
date Wed Jul 20 17:04:10 2022 +0100 (2022-07-20)
parents 3105f866bc3e
children ca6fa52862c9
rev   line source
pascal@2223 1 # SliTaz package receipt.
pascal@2223 2
pascal@2223 3 PACKAGE="slim-pam"
Hans-G?nter@25310 4 VERSION="1.3.6"
pascal@2223 5 CATEGORY="x-window"
al@14601 6 SHORT_DESC="Desktop-independent graphical login manager for X11 (PAM enabled)."
pascal@2223 7 MAINTAINER="pascal.bellard@slitaz.org"
al@14601 8 LICENSE="GPL2"
pascal@20679 9 WEB_SITE="https://sourceforge.net/projects/slim.berlios/"
Hans-G?nter@25310 10 REPOLOGY="slim-login-manager"
Hans-G?nter@25310 11
pascal@2223 12 SOURCE="slim"
pascal@2223 13 TARBALL="$SOURCE-$VERSION.tar.gz"
Hans-G?nter@25310 14 WGET_URL="https://downloads.sourceforge.net/project/slim.berlios/$TARBALL"
al@14601 15
pascal@2223 16 PROVIDE="slim:pam"
Hans-G?nter@25310 17 RELATED="slim slim-theme-default"
Hans-G?nter@25310 18 SUGGESTED="slim-theme-default slitaz-configs"
al@14601 19 DEPENDS="gcc-lib-base libjpeg libpng pam xorg-libXft xorg-libXmu"
Hans-G?nter@25310 20 BUILD_DEPENDS="cmake freetype-dev jpeg-dev libpng-dev pam-dev xorg-libXft-dev
Hans-G?nter@25310 21 xorg-libXmu-dev"
Hans-G?nter@25310 22
Hans-G?nter@25310 23 CONFIG_FILES="/etc/slim.conf"
pascal@10452 24
pascal@24353 25 # What is the latest version available today?
pascal@24353 26 current_version()
pascal@24353 27 {
pascal@24353 28 wget -O - https://sourceforge.net/projects/slim.berlios/files/ 2>/dev/null | \
pascal@24353 29 sed '/scope="row/!d;/slim-/!d;s|.*/slim-||;s|.tar.*||;q'
pascal@24353 30 }
pascal@24353 31
pascal@2223 32 # Rules to configure and make the package.
pascal@2223 33 compile_rules()
pascal@2223 34 {
Hans-G?nter@25310 35 patch --input=$WOK/$SOURCE/stuff/patches/app.cpp-$VERSION || return 1
Hans-G?nter@25310 36 patch --input=$WOK/$SOURCE/stuff/patches/cfg.cpp-$VERSION || return 1
Hans-G?nter@25310 37 patch --input=$WOK/$SOURCE/stuff/patches/slim.conf-$VERSION || return 1
Hans-G?nter@25310 38
Hans-G?nter@25310 39 mkdir _build &&
Hans-G?nter@25310 40 cd _build &&
Hans-G?nter@25310 41 cmake .. \
Hans-G?nter@25310 42 -D CMAKE_INSTALL_PREFIX=/usr \
Hans-G?nter@25310 43 -D X11_Xmu_LIB=-lXmu \
Hans-G?nter@25310 44 -D USE_PAM=yes &&
al@14601 45 make &&
Hans-G?nter@25310 46 make install DESTDIR=$DESTDIR
pascal@2223 47 }
pascal@2223 48
pascal@2223 49 # Rules to gen a SliTaz package suitable for Tazpkg.
pascal@2223 50 genpkg_rules()
pascal@2223 51 {
rcx@6055 52 mkdir -p $fs/usr/share/slim
pankso@13364 53
Hans-G?nter@25310 54 cp -a $install/etc $fs
Hans-G?nter@25310 55 cp -a $install/usr/bin $fs/usr
Hans-G?nter@25310 56 cp -a $install/usr/lib $fs/usr
Hans-G?nter@25310 57 cp -a $WOK/$SOURCE/stuff/themes $fs/usr/share/slim
Hans-G?nter@25310 58
Hans-G?nter@25310 59 # Configuration file and rc script.
Hans-G?nter@25310 60 cp -a $WOK/$SOURCE/stuff/etc $fs
Hans-G?nter@25310 61 chown -R root.root $fs
pascal@2223 62
al@14601 63 # slim-theme manager
al@14601 64 install -m755 $WOK/$SOURCE/stuff/slim-theme $fs/usr/bin/slim-theme
pascal@2223 65 }
pascal@2223 66
pascal@2223 67 post_install()
pascal@2223 68 {
pascal@2223 69 local USER
pascal@18730 70 USER=$(awk -F: '/:1000:1000:/ { print $1 }' < "$1/etc/passwd")
pascal@2223 71 [ -n "$USER" ] &&
pascal@18730 72 sed -i s/"default_user .*"/"default_user $USER"/ "$1/etc/slim.conf"
al@14601 73
al@14601 74 # In order to update the SLiM, we need to restart it.
al@14601 75 # We can't just "/etc/init.d/slim restart" because it momentarily interrupts
al@14601 76 # X session and the user will get a terrible console with strange letters.
al@14601 77 printf '%40s\n' | tr ' ' '='
al@14601 78 echo "In order to update the SLiM,"
al@14601 79 echo "please, reboot your system!"
pascal@2223 80 }
pascal@7632 81
pascal@7632 82 pre_remove()
pascal@7632 83 {
pascal@7632 84 tazpkg get-install ${PACKAGE%-pam}
pascal@7632 85 }
al@19756 86
Hans-G?nter@25310 87 testsuite()
Hans-G?nter@25310 88 {
Hans-G?nter@25310 89 ldd $install/usr/bin/slim
Hans-G?nter@25310 90 }