Commit | Line | Data |
---|---|---|
ffcb22f1 VB |
1 | TERMUX_PKG_HOMEPAGE=https://openvpn.net |
2 | TERMUX_PKG_DESCRIPTION='An easy-to-use, robust, and highly configurable VPN (Virtual Private Network)' | |
3 | TERMUX_PKG_VERSION=2.4.0 | |
4 | TERMUX_PKG_DEPENDS="openssl, liblzo" | |
5 | TERMUX_PKG_SRCURL=https://swupdate.openvpn.net/community/releases/openvpn-${TERMUX_PKG_VERSION}.tar.xz | |
6 | TERMUX_PKG_SHA256=6f23ba49a1dbeb658f49c7ae17d9ea979de6d92c7357de3d55cd4525e1b2f87e | |
7 | TERMUX_PKG_EXTRA_CONFIGURE_ARGS=' --disable-plugin-auth-pam --disable-systemd --disable-debug' | |
8 | TERMUX_PKG_EXTRA_CONFIGURE_ARGS+=' --enable-iproute2 --enable-small --enable-x509-alt-username' | |
9 | TERMUX_PKG_MAINTAINER='Vishal Biswas @vishalbiswas' | |
10 | ||
11 | termux_step_pre_configure () { | |
12 | # we modify configure.ac | |
13 | # uncomment if you want to apply configure.patch | |
14 | # autoreconf -i $TERMUX_PKG_SRCDIR | |
15 | ||
16 | export ac_cv_func_getpwnam='yes' | |
17 | # need to provide getpass, else you "can't get console input" | |
18 | export ac_cv_func_getpass='yes' | |
19 | cp "$TERMUX_PKG_BUILDER_DIR/netbsd_getpass.c" "$TERMUX_PKG_SRCDIR/src/openvpn/" | |
20 | ||
21 | # paths to external programs used by openvpn | |
22 | export IFCONFIG="$TERMUX_PREFIX/bin/applets/ifconfig" | |
23 | export ROUTE="$TERMUX_PREFIX/bin/applets/route" | |
24 | export IPROUTE="$TERMUX_PREFIX/bin/ip" | |
25 | export NETSTAT="$TERMUX_PREFIX/bin/applets/netstat" | |
26 | ||
27 | # CFLAGS="$CFLAGS -DTARGET_ANDROID" | |
28 | LDFLAGS="$LDFLAGS -llog " | |
29 | } | |
30 | ||
31 | termux_step_post_make_install () { | |
32 | # helper script | |
33 | install -m700 "${TERMUX_PKG_BUILDER_DIR}"/termux-openvpn "${TERMUX_PREFIX}"/bin/ | |
34 | # Install examples | |
35 | install -d -m755 "${TERMUX_PREFIX}"/share/openvpn/examples | |
36 | cp "${TERMUX_PKG_SRCDIR}"/sample/sample-config-files/* "${TERMUX_PREFIX}"/share/openvpn/examples | |
37 | } |