wok-next annotate mosh/receipt @ rev 21020

Cleaning is almost finished... I should proceed to upgrades.
author Aleksej Bobylev <al.bobylev@gmail.com>
date Fri Nov 02 14:15:08 2018 +0200 (2018-11-02)
parents 757d032c55c7
children d457c4e37c1b
rev   line source
al@20534 1 # SliTaz package receipt v2.
pascal@15179 2
pascal@15179 3 PACKAGE="mosh"
pascal@19962 4 VERSION="1.3.2"
pascal@15179 5 CATEGORY="security"
al@20534 6 SHORT_DESC="A Openbsd Secure Shell remplacement"
pascal@15179 7 MAINTAINER="pascal.bellard@slitaz.org"
pascal@15179 8 LICENSE="GPL3"
al@20534 9 WEB_SITE="http://mosh.mit.edu/"
al@20534 10
pascal@15179 11 TARBALL="$PACKAGE-$VERSION.tar.gz"
pascal@15179 12 WGET_URL="${WEB_SITE}$TARBALL"
pascal@15179 13
al@20513 14 BUILD_DEPENDS="protobuf-dev openssl-dev zlib-dev \
pascal@19962 15 ncurses-dev automake autoconf libtool"
pascal@15179 16
al@20534 17 compile_rules() {
pascal@19962 18 ./autogen.sh
al@20534 19 ./configure \
al@21020 20 --enable-compile-warnings=error \
al@21020 21 &&
pascal@15179 22 make &&
al@21020 23 make DESTDIR=$install install
pascal@15179 24 }
pascal@15179 25
al@20534 26 genpkg_rules() {
al@20534 27 copy @std
al@20534 28 DEPENDS="gcc-lib-base perl protobuf openssl zlib ncurses ssh"
al@20534 29 TAGS="ssh"
pascal@15179 30 }
pascal@18178 31
al@20534 32 post_install() {
pascal@18730 33 if ! grep ^DROPBEAR_OPTIONS "$1/etc/daemons.conf" | grep -q -- -a; then
pascal@18178 34 cat <<EOT
al@20534 35
al@20534 36 .----------------------------------------------------.
al@20534 37 | The mosh server needs dropbear to allow connections |
al@20534 38 | to forwarded ports from any host. Nothing to do if |
al@20534 39 | you are using OpenSSH or you plan to use the mosh |
al@20534 40 | client only. |
al@20534 41 '-----------------------------------------------------'
pascal@18178 42 EOT
pascal@18178 43 echo -n "Add -a for DROPBEAR_OPTIONS in /etc/daemons.conf now ?"
pascal@18178 44 read -t 30 answer
al@20534 45 [ "$answer" == "y" ] &&
pascal@18730 46 sed -i 's/^DROPBEAR_OPTIONS="/&-a /' "$1/etc/daemons.conf" &&
pascal@18178 47 [ -z "$1" ] && /etc/init.d/dropbear restart
pascal@18178 48 fi
pascal@18469 49 true
pascal@18178 50 }