summaryrefslogtreecommitdiff
path: root/misc
diff options
context:
space:
mode:
authorArne Schwabe <arne@rfc2549.org>2014-01-03 16:02:48 +0100
committerArne Schwabe <arne@rfc2549.org>2014-01-03 16:02:48 +0100
commit4f244609f3cf32ae2ab17069f0e267eb59f05f04 (patch)
treea0aefd5342678cbb7d7e6a0a77c8ea5acc194596 /misc
parent9e0e3572c2133f2396d27ced5ddb265b6e604b58 (diff)
Update build script to include revision, update openvpn code, remove openssl compat (disables export ciphers)
Diffstat (limited to 'misc')
-rwxr-xr-xmisc/build-native.sh18
1 files changed, 18 insertions, 0 deletions
diff --git a/misc/build-native.sh b/misc/build-native.sh
index 72ecd1cb..34cd137d 100755
--- a/misc/build-native.sh
+++ b/misc/build-native.sh
@@ -1,3 +1,21 @@
+if [ -d openvpn/.git ]; then
+ GIT=git
+ cd openvpn
+ CONFIGURE_GIT_CHFILES=$($GIT diff-files --name-status -r --ignore-submodules --quiet -- || echo "+")
+ CONFIGURE_GIT_UNCOMMITTED=$($GIT diff-index --cached --quiet --ignore-submodules HEAD || echo "*")
+ CONFIGURE_GIT_REVISION=$($GIT rev-parse --symbolic-full-name HEAD | cut -d/ -f3)-$($GIT rev-parse --short=16 HEAD)
+ echo "#define CONFIGURE_GIT_REVISION \"${CONFIGURE_GIT_REVISION}\"" > config-version.h.tmp; \
+ echo "#define CONFIGURE_GIT_FLAGS \"${CONFIGURE_GIT_CHFILES}${CONFIGURE_GIT_UNCOMMITTED}\"" >> config-version.h.tmp
+
+ if ! [ -f config-version.h ] || ! cmp -s config-version.h.tmp config-version.h; then \
+ echo "replacing config-version.h"
+ mv config-version.h.tmp config-version.h
+ else
+ rm -f config-version.h.tmp
+ fi
+ cd ..
+fi
+
ndk-build APP_API=all -j 8
if [ $? = 0 ]; then
rm -rf build/native-libs/