# Prerequisites:
# rsh/remsh or ssh (you need one or the other)
# yodl2man (to generate man pages; will use existing ones if not available)
# Python
# Perl
# zlib or lz4 >= 1.4 (optional)
# OpenSSL or GnuTLS
# xxHash (optional)
# Zstandard (zstd; optional)
# LZ4 (optional)
# Get the tarball
cd
test -f installed/rsync-3.4.1.tar.gz && mv installed/rsync-3.4.1.tar.gz .
test ! -f rsync-3.4.1.tar.gz &&
wget https://download.samba.org/pub/rsync/src/rsync-3.4.1.tar.gz
# Verify tarball w/ sha256sum:
# (this came from my gpg-verified tarball)
echo "2924bcb3a1ed8b551fc101f740b9f0fe0a202b115027647cf69850d65fd88c\
52 rsync-3.4.1.tar.gz" | sha256sum -c
# Extract the source
mkdir -p -m 0700 ~/src
cd ~/src
find -maxdepth 1 -type d -name "rsync-*" -exec rm -r {} \;
tar xzvf ~/rsync-3.4.1.tar.gz
cd rsync-3.4.1
test $UID = 0 && chown -R root:root .
# Read ./README.md, ./INSTALL.md, and if upgrading ./NEWS.md
# Install cmarkgfm or commonmark with Python 3.x's pip3 if you need to
# generate man pages. Man pages are included with the tarball, but
# not when you get it directly with git.
# You may want to upgrade pip itself (as root) first:
# su -c "python3 -m pip install --upgrade pip cmarkgfm commonmark"
# Configure the build
# Obviously, if you will be using it with IPv6, leave off --disable-ipv6
./configure --prefix=/usr --mandir=/usr/man --disable-ipv6
# Build it
make
# Become root to install it
su
# Remove the Slackware package, if there is one
test -x /sbin/removepkg && /sbin/removepkg rsync
# Install it
make install
## If you're running it as a daemon, restart it:
# killall rsync
# sleep 2
# killall -9 rsync
# /usr/bin/rsync --daemon
# Become yourself again
exit
# Save the source for later
cd
mkdir -p -m 0700 installed
rm -f installed/rsync-*.tar.*
mv rsync-3.4.1.tar.gz installed/
# If you ever want to uninstall rsync, this should do it:
su
for pfx in /usr /usr/local /usr/share;
do
test -f ${pfx}/bin/rrsync && rm -f ${pfx}/bin/rrsync
test -f ${pfx}/bin/rsync && rm -f ${pfx}/bin/rsync
test -f ${pfx}/bin/rsync-ssl && rm -f ${pfx}/bin/rsync-ssl
find ${pfx}/man -type f -name rrsync.1 -exec rm {} \;
find ${pfx}/man -type f -name rsync.1 -exec rm {} \;
find ${pfx}/man -type f -name rsync-ssl.1 -exec rm {} \;
find ${pfx}/man -type f -name rsyncd.conf.5 -exec rm {} \;
done
exit
find ~/src -maxdepth 1 -type d -name "rsync-*" -exec rm -r {} \;
rm -f ~/installed/rsync-*.tar.*