Skip to content
This repository has been archived by the owner on Aug 30, 2023. It is now read-only.

Commit

Permalink
ref: Explicitly define minimal Android API version
Browse files Browse the repository at this point in the history
  • Loading branch information
tonyo committed Feb 22, 2019
1 parent ec00fe9 commit 3d9c1a1
Showing 1 changed file with 14 additions and 6 deletions.
20 changes: 14 additions & 6 deletions breakpad/android/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,20 @@ cat ${ANDROID_NDK_HOME}/source.properties

cd ${SCRIPT_DIR}/../deps/breakpad/android/sample_app

# Override APP_STL
# See https://developer.android.com/ndk/guides/cpp-support.html
APP_STL_CONFIG='APP_STL := c++_static'
if ! grep "${APP_STL_CONFIG}" jni/Application.mk; then
echo -e "\n${APP_STL_CONFIG}" >> jni/Application.mk
fi

CONFIG_LINES=(
# Override APP_STL
# See https://developer.android.com/ndk/guides/cpp-support.html
'APP_STL := c++_static'
# See https://developer.android.com/ndk/guides/application_mk#app_platform
'APP_PLATFORM := android-16'
)

for conf_line in "${CONFIG_LINES[@]}"; do
if ! grep "${conf_line}" jni/Application.mk; then
echo -e "\n${conf_line}" >> jni/Application.mk
fi
done

# Compile!
${ANDROID_NDK_HOME}/ndk-build --debug

0 comments on commit 3d9c1a1

Please sign in to comment.