dropbear: update to 2018.76 (#2356)
[termux-packages] / packages / dropbear / build.sh
index 827fc1f..13ac840 100755 (executable)
@@ -1,18 +1,23 @@
 TERMUX_PKG_HOMEPAGE=https://matt.ucc.asn.au/dropbear/dropbear.html
 TERMUX_PKG_DESCRIPTION="Small SSH server and client"
-TERMUX_PKG_DEPENDS="libutil"
-TERMUX_PKG_VERSION=2017.75
-TERMUX_PKG_REVISION=1
+TERMUX_PKG_DEPENDS="libutil, readline"
+TERMUX_PKG_CONFLICTS="openssh"
+TERMUX_PKG_VERSION=2018.76
 TERMUX_PKG_SRCURL=https://matt.ucc.asn.au/dropbear/releases/dropbear-${TERMUX_PKG_VERSION}.tar.bz2
-TERMUX_PKG_SHA256=6cbc1dcb1c9709d226dff669e5604172a18cf5dbf9a201474d5618ae4465098c
+TERMUX_PKG_SHA256=f2fb9167eca8cf93456a5fc1d4faf709902a3ab70dd44e352f3acbc3ffdaea65
 TERMUX_PKG_EXTRA_CONFIGURE_ARGS="--disable-syslog --disable-utmp --disable-utmpx --disable-wtmp"
+TERMUX_PKG_BUILD_IN_SRC="yes"
+TERMUX_PKG_CLANG=no
 # Avoid linking to libcrypt for server password authentication:
 TERMUX_PKG_EXTRA_CONFIGURE_ARGS+=" ac_cv_lib_crypt_crypt=no"
+# use own implementation of getpass
+TERMUX_PKG_EXTRA_CONFIGURE_ARGS+=" ac_cv_func_getpass=yes LIBS=-lreadline"
+# build a multi-call binary
 TERMUX_PKG_EXTRA_MAKE_ARGS="MULTI=1"
-TERMUX_PKG_BUILD_IN_SRC="yes"
 
 termux_step_create_debscripts () {
-        echo "mkdir -p $TERMUX_PREFIX/etc/dropbear" >> postinst
+        echo "#!$TERMUX_PREFIX/bin/sh" > postinst
+       echo "mkdir -p $TERMUX_PREFIX/etc/dropbear" >> postinst
         echo "for a in rsa dss ecdsa; do" >> postinst
         echo "    KEYFILE=$TERMUX_PREFIX/etc/dropbear/dropbear_\${a}_host_key" >> postinst
         echo "    test ! -f \$KEYFILE && dropbearkey -t \$a -f \$KEYFILE" >> postinst