SliTaz Packages

Community Doc Forum Pro Shop Bugs Hg
.

Receipt for package "rsync"

# SliTaz package receipt.

PACKAGE="rsync"
VERSION="3.2.7"
CATEGORY="network"
TAGS="sync copy secure"
SHORT_DESC="Utility that provides fast incremental file transfer."
MAINTAINER="pankso@slitaz.org"
LICENSE="GPL3"
WEB_SITE="https://rsync.samba.org/"

TARBALL="$PACKAGE-$VERSION.tar.gz"
WGET_URL="${WEB_SITE}ftp/rsync/src/$TARBALL"

SUGGESTED="bash openssl"
DEPENDS="attr acl lz4-lib popt xxhash-lib zstd"
BUILD_DEPENDS="acl-dev attr-dev lz4-dev popt-dev xxhash-dev zstd-dev"

CONFIG_FILES="/etc/rsyncd.conf"
SECRET_FILES="/etc/rsyncd.secrets"
HOST_ARCH="i486 arm"

# TazPanel
TAZPANEL_DAEMON="man::rsync|help::rsync|edit|options|web::$WEB_SITE"

current_version()
{
    wget -O - $WEB_SITE 2>/dev/null | \
    sed "/$PACKAGE-/!d;/tar/!d;s|.tar.*||;s|.*-||;q"
}

# Rules to configure and make the package.
compile_rules()
{
    ./configure            \
        --prefix=/usr        \
        --mandir=/usr/share/man    \
        --disable-iconv        \
        --disable-iconv-open    \
        --disable-openssl    \
        $CONFIGURE_ARGS
    sed -i  -e 's/HAVE_ICONV_H ./HAVE_ICONV_H 0/' \
        -e 's/HAVE_ICONV_OPEN ./HAVE_ICONV_OPEN 0/' config.h
    sed -i 's/-liconv//'    Makefile
    make &&
    make install DESTDIR=$DESTDIR
}

# Rules to gen a SliTaz package suitable for Tazpkg.
genpkg_rules()
{
    cook_copy_folders    bin

    # Configuration file is /etc/rsyncd.conf.
    # User and password in /etc/rsyncd.secrets, syntax : user:passwd
    #
    cp -a $stuff/etc    $fs
    cp -a $stuff/usr    $fs
    chown root.root        $fs/etc/init.d/*
    chmod 0644        $fs/etc/rsyncd.conf
}

post_install()
{
    [ -s "$1/etc/inetd.conf" ] &&
    ! grep -qs rsync "$1/etc/inetd.conf" &&
    cat >> "$1/etc/inetd.conf" <<EOT
#rsync    stream    tcp    nowait    root    rsync    rsync    -daemon
EOT
    true
}

post_remove()
{
    grep -q rsync        "$1/etc/inetd.conf" &&
    sed -i '/rsync/d'    "$1/etc/inetd.conf"
}
6025 packages and 203154 files in current database (Thu Apr 25 06:17:47 2024)