SliTaz Packages

Community Doc Forum Pro Shop Bugs Hg
.

Receipt for package "php-common"

# SliTaz package receipt.

PACKAGE="php-common"
VERSION="5.2.17"
CATEGORY="development"
SHORT_DESC="Common files for PHP modules."
MAINTAINER="pascal.bellard@slitaz.org"
WEB_SITE="http://www.php.net/"
WANTED="php"
CONFIG_FILES="/etc/php.ini"

# Rules to gen a SliTaz package suitable for Tazpkg.
genpkg_rules()
{
    mkdir -p $fs/etc \
        $fs/usr/share/applications \
        $fs/usr/share/pixmaps
    cp -a $stuff/phpinfo $fs/usr/share
    cp $stuff/php.desktop $fs/usr/share/applications 
    cp $stuff/php.png $fs/usr/share/pixmaps 
    cp $install/etc/php.ini $fs/etc
}

# Post and pre install commands
pre_install()
{
    # Backup existing php.ini
    if [ -f "$1/etc/php.ini" ]; then
        echo -n "Creating php.ini backup..."
        cp $1/etc/php.ini $1/etc/php.ini.bak
        status
    fi
}
post_install()
{
    # Restore original php.ini
    if [ -f "$1/etc/php.ini.bak" ]; then
        echo -n "Restoring php.ini backup..."
        mv -f $1/etc/php.ini.bak $1/etc/php.ini 
        status
    fi
}
3382 packages and 430813 files in stable database (Mon Mar 4 17:53:49 2019)