SliTaz Packages

Community Doc Forum Pro Shop Bugs Hg
.

Receipt for package "vpnc"

# SliTaz package receipt.

PACKAGE="vpnc"
VERSION="0.5.3"
CATEGORY="network"
SHORT_DESC="VPN client compatible with Cisco's EasyVPN equipment."
MAINTAINER="pascal.bellard@slitaz.org"
LICENSE="GPL2"
TARBALL="$PACKAGE-$VERSION.tar.gz"
WEB_SITE="https://github.com/streambinder/vpnc"
WGET_URL="https://github.com/sailfishos/vpnc/archive/refs/tags/$VERSION-6.tar.gz"
CONFIG_FILES="/etc/vpnc"
TAGS="vpn tunnel"

DEPENDS="libgcrypt libgpg-error glibc-base perl"
BUILD_DEPENDS="libgcrypt-dev openssl-dev"

# What is the latest version available today?
current_version()
{
    wget -O - $WEB_SITE/commits/master 2>/dev/null | \
    sed '/commits_list_item/!d;s|.*commits/\(.......\).*|\1|;q'
}

# Rules to configure and make the package.
compile_rules()
{
    [ -s $TARBALL ] && tar xzf $TARBALL -C ..
    sed -i "s|perl -w .*|&\\n    sed -i '/Automatically/,\$\$!d' vpnc-debug.h|" Makefile
    make && make DESTDIR=$DESTDIR install
    install -d -m 755 $DESTDIR/usr/share/man/man1 &&
    install -d -m 755 $DESTDIR/usr/share/man/man8 &&
    install -d -m 755 $DESTDIR/usr/share/doc &&
    install -m 644 $src/*.1 $DESTDIR/usr/share/man/man1 &&
    install -m 644 $src/*.8 $DESTDIR/usr/share/man/man8 &&
    install -m 644 $src/[A-Z][A-Z]* $src/C* $DESTDIR/usr/share/doc
}

# Rules to gen a SliTaz package suitable for Tazpkg.
genpkg_rules()
{
    mkdir -p $fs/usr $fs/var/run/vpnc
    cp -a $install/etc $fs
    cp -a $install/usr/local/bin $fs/usr
    cp -a $install/usr/local/sbin $fs/usr
    sed -i 's|/usr/local/|/usr/|g' $fs/etc/vpnc/vpnc-script
}

# Pre and post install commands for Tazpkg.
post_install()
{
    cat <<EOT
-------------
You can now update /etc/vpnc/default.conf
-------------
EOT
}
6025 packages and 203154 files in current database (Thu Apr 25 06:17:47 2024)