1
0
mirror of https://github.com/termux/termux-packages synced 2024-06-18 03:17:06 +00:00
termux-packages/packages/dropbear/build.sh
Vishal Biswas 160d3aeb06 update ndk to 17 and switch some packages to clang build (#2415)
* update ndk to 17

* bump NDK version in setup-android script

* libnl: fix for ndk r17

* libpixman: use clang's __builtin_shufflevector instead of __builtin_shuffle (#1)

Required to make package build with ndk17.

* fix as for arm

* ndk17 still uses ld.bfd on aarch64

* use -fno-integrated-as for clang only

* glib: remove patch unnecessary after ndk17

* torsocks: remove unneeded patch after ndk17

* subversion: fix build as clang++ now errors out for mismatched flags

* libpulseaudio: fix build with ndk17

https://github.com/termux/termux-packages/pull/2415#issuecomment-388296684

* gst-plugins-good: disable video4linux2

ioctl is defined as __overloadable in ndk17 headers which
  conflicts with v4l2object's member ioctl

* libzmq: disable Werror to build with ndk17

* ltrace: hardcode symbol not available in ndk17

* busybox: build with clang for all arches except arm

* dropbear: build with clang instead of gcc

* gnupg: build with clang instead of gcc

* openssl: use clang for all arches except arm

* picolisp: build with clang instead of gcc

* valgrind: use clang on all arches except aarch64

* Revert "gst-plugins-good: disable video4linux2"

This reverts commit 43850b81cc.
Already applied on base branch.

* libllvm: use default arm triple
2018-05-27 14:55:20 +02:00

28 lines
1.3 KiB
Bash
Executable File

TERMUX_PKG_HOMEPAGE=https://matt.ucc.asn.au/dropbear/dropbear.html
TERMUX_PKG_DESCRIPTION="Small SSH server and client"
TERMUX_PKG_DEPENDS="libutil, readline"
TERMUX_PKG_CONFLICTS="openssh"
TERMUX_PKG_VERSION=2018.76
TERMUX_PKG_REVISION=2
TERMUX_PKG_SRCURL=https://matt.ucc.asn.au/dropbear/releases/dropbear-${TERMUX_PKG_VERSION}.tar.bz2
TERMUX_PKG_SHA256=f2fb9167eca8cf93456a5fc1d4faf709902a3ab70dd44e352f3acbc3ffdaea65
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="--disable-syslog --disable-utmp --disable-utmpx --disable-wtmp"
TERMUX_PKG_BUILD_IN_SRC="yes"
# 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_step_create_debscripts () {
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
echo "done" >> postinst
echo "exit 0" >> postinst
chmod 0755 postinst
}