wok annotate php-common/receipt @ rev 21501

updated mutagen (1.28 -> 1.42.0)
author Hans-G?nter Theisgen
date Thu May 02 15:41:19 2019 +0100 (2019-05-02)
parents f892b13c8f81
children 84a3b4b621e1
rev   line source
pascal@1315 1 # SliTaz package receipt.
pascal@1315 2
pascal@1315 3 PACKAGE="php-common"
erjo@16733 4 VERSION="5.5.13"
pascal@1315 5 CATEGORY="development"
pascal@1315 6 SHORT_DESC="Common files for PHP modules."
pascal@1315 7 MAINTAINER="pascal.bellard@slitaz.org"
pascal@15198 8 LICENSE="BSD"
pascal@21278 9 WEB_SITE="https://www.php.net/"
pascal@1315 10 WANTED="php"
pascal@1315 11 CONFIG_FILES="/etc/php.ini"
pascal@1315 12
pascal@1315 13 # Rules to gen a SliTaz package suitable for Tazpkg.
pascal@1315 14 genpkg_rules()
pascal@1315 15 {
pankso@10819 16 mkdir -p $fs/etc \
pankso@10819 17 $fs/usr/share/applications \
pankso@10819 18 $fs/usr/share/pixmaps
pankso@10819 19 cp -a $stuff/phpinfo $fs/usr/share
pankso@10819 20 cp $stuff/php.desktop $fs/usr/share/applications
pankso@10819 21 cp $stuff/php.png $fs/usr/share/pixmaps
pankso@10819 22 cp $install/etc/php.ini $fs/etc
pascal@20439 23 sed -i 's|.*\(extension_dir.*/usr/share/php.*\)$|\1|' $fs/etc/php.ini
pascal@1315 24 }
pascal@1315 25
pascal@1315 26 # Post and pre install commands
pascal@1315 27 pre_install()
pascal@1315 28 {
pascal@1315 29 # Backup existing php.ini
pascal@1315 30 if [ -f "$1/etc/php.ini" ]; then
pascal@20319 31 echo
pascal@1315 32 echo -n "Creating php.ini backup..."
pascal@18730 33 cp "$1/etc/php.ini" "$1/etc/php.ini.bak"
pascal@1315 34 status
pascal@1315 35 fi
pascal@1315 36 }
pascal@1315 37 post_install()
pascal@1315 38 {
pascal@1315 39 # Restore original php.ini
pascal@1315 40 if [ -f "$1/etc/php.ini.bak" ]; then
pascal@20319 41 echo
pascal@1315 42 echo -n "Restoring php.ini backup..."
pascal@18730 43 mv -f "$1/etc/php.ini.bak" "$1/etc/php.ini"
pascal@1315 44 status
pascal@1315 45 fi
pascal@1315 46 }