Skip to content

Commit 49afb3d

Browse files
committed
actually get the JNI commit hash
1 parent aaab789 commit 49afb3d

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

circle_scripts/deps.sh

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ _ANDROID_NDK_HASH_="ad7ce5467e18d40050dc51b8e7affc3e635c85bd8c59be62de32352328ed
4040
_ANDROID_NDK_UNPACKDIR_="android-ndk-r21e"
4141

4242
_ANDOIRD_CMAKE_VER_="3.10.2.4988404"
43+
_GITREPO_HOME_="/home/runner/work/ToxAndroidRefImpl/ToxAndroidRefImpl" # this works only for github CI for now
4344
## ----------------------
4445

4546
# export ASAN_CLANG_FLAGS=" -fsanitize=address -fno-omit-frame-pointer -fno-optimize-sibling-calls "
@@ -665,8 +666,10 @@ echo "-------- compiler version --------"
665666
echo ""
666667
echo ""
667668

669+
pushd "$_GITREPO_HOME_"
668670
git_hash_for_jni=$(git rev-parse --verify --short=8 HEAD 2>/dev/null|tr -dc '[A-Fa-f0-9]' 2>/dev/null)
669671
echo "XX:""$git_hash_for_jni"":YY"
672+
popd
670673

671674
cd $_s_/jni-c-toxcore/; export V=1;$GCC -O3 -fPIC -g -shared \
672675
$WARNS \
@@ -1256,8 +1259,10 @@ echo "-------- compiler version --------"
12561259
echo ""
12571260
echo ""
12581261

1262+
pushd "$_GITREPO_HOME_"
12591263
git_hash_for_jni=$(git rev-parse --verify --short=8 HEAD 2>/dev/null|tr -dc '[A-Fa-f0-9]' 2>/dev/null)
12601264
echo "XX:""$git_hash_for_jni"":YY"
1265+
popd
12611266

12621267
set -x
12631268

@@ -1693,8 +1698,10 @@ echo "compiling jni-c-toxcore ..."
16931698
# make certain warnings into errors!
16941699
WARNS=' -Werror=div-by-zero -Werror=sign-compare -Werror=format=2 -Werror=implicit-function-declaration '
16951700

1701+
pushd "$_GITREPO_HOME_"
16961702
git_hash_for_jni=$(git rev-parse --verify --short=8 HEAD 2>/dev/null|tr -dc '[A-Fa-f0-9]' 2>/dev/null)
16971703
echo "XX:""$git_hash_for_jni"":YY"
1704+
popd
16981705

16991706
cd $_s_/jni-c-toxcore/; export V=1;$GCC -O3 -fPIC -g -shared -Wall -Wextra \
17001707
-Wno-unused-parameter -Wno-unused-variable -Wno-unused-function \
@@ -2126,8 +2133,10 @@ echo "compiling jni-c-toxcore ..."
21262133
# make certain warnings into errors!
21272134
WARNS=' -Werror=div-by-zero -Werror=sign-compare -Werror=format=2 -Werror=implicit-function-declaration '
21282135

2136+
pushd "$_GITREPO_HOME_"
21292137
git_hash_for_jni=$(git rev-parse --verify --short=8 HEAD 2>/dev/null|tr -dc '[A-Fa-f0-9]' 2>/dev/null)
21302138
echo "XX:""$git_hash_for_jni"":YY"
2139+
popd
21312140

21322141
cd $_s_/jni-c-toxcore/; export V=1;$GCC -O3 -fPIC -g -shared -Wall -Wextra \
21332142
-Wno-unused-parameter -Wno-unused-variable -Wno-unused-function \

0 commit comments

Comments
 (0)