Skip to content

Commit

Permalink
Fix ndk version in ci script (#16357) (#16369)
Browse files Browse the repository at this point in the history
  • Loading branch information
dumganhar authored Oct 9, 2023
1 parent c82a99f commit c9f0b91
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/native-bindings.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ jobs:
add-to-path: false
local-cache: true
- name: Generate decorators
env:
ANDROID_NDK_HOME: ${{ steps.setup-ndk.outputs.ndk-path }}
run: |
bash ./native/utils/generate_decorators.sh
git checkout HEAD package.json package-lock.json
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/native-compile-platforms.yml
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ jobs:
COCOS_ENGINE_DEV: 1
run: |
NATIVE_ROOT=$GITHUB_WORKSPACE/native
ANDORID_NDK=$ANDROID_NDK_LATEST_HOME
ANDROID_NDK=${{ steps.setup-ndk.outputs.ndk-path }}
NATIVE_DIR=$GITHUB_WORKSPACE/templates/android-template
echo "Compiling Android ... "
cd $GITHUB_WORKSPACE/templates/
Expand All @@ -112,7 +112,7 @@ jobs:
ASSET_DIR=$GITHUB_WORKSPACE/templates/android/build/build-android/
sed -i "s@^PROP_NDK_PATH.*@PROP_NDK_PATH=$ANDORID_NDK@g" gradle.properties
sed -i "s@^PROP_NDK_PATH.*@PROP_NDK_PATH=$ANDROID_NDK@g" gradle.properties
sed -i "s@^APPLICATION_ID.*@APPLICATION_ID=com.cocos.android@g" gradle.properties
sed -i "s@^RES_PATH.*@RES_PATH=$ASSET_DIR@g" gradle.properties
sed -i "s@^COCOS_ENGINE_PATH.*@COCOS_ENGINE_PATH=$NATIVE_ROOT@g" gradle.properties
Expand All @@ -123,7 +123,7 @@ jobs:
sed -i "s@^PROP_APP_ABI.*@PROP_APP_ABI=arm64-v8a@g" gradle.properties
echo "Compile Android - cmake ..."
echo "ANDORID_NDK ${ANDROID_NDK} or ${ANDROID_NDK_HOME}"
echo "ANDROID_NDK ${ANDROID_NDK} or ${ANDROID_NDK_HOME}"
# ./gradlew :CocosGame:assembleDebug --quiet
./gradlew :CocosGame:assembleRelease --quiet
echo "Compile Android Debug Done!"
Expand Down Expand Up @@ -156,7 +156,7 @@ jobs:
COCOS_ENGINE_DEV: 1
run: |
NATIVE_ROOT=$GITHUB_WORKSPACE/native
ANDORID_NDK=$ANDROID_NDK_LATEST_HOME
ANDROID_NDK=${{ steps.setup-ndk.outputs.ndk-path }}
NATIVE_DIR=$GITHUB_WORKSPACE/templates/android-template
echo "Compiling Android ... "
cd $GITHUB_WORKSPACE/templates/
Expand Down Expand Up @@ -187,7 +187,7 @@ jobs:
ASSET_DIR=$GITHUB_WORKSPACE/templates/android/build/build-android/
sed -i "s@^PROP_NDK_PATH.*@PROP_NDK_PATH=$ANDORID_NDK@g" gradle.properties
sed -i "s@^PROP_NDK_PATH.*@PROP_NDK_PATH=$ANDROID_NDK@g" gradle.properties
sed -i "s@^APPLICATION_ID.*@APPLICATION_ID=com.cocos.android@g" gradle.properties
sed -i "s@^RES_PATH.*@RES_PATH=$ASSET_DIR@g" gradle.properties
sed -i "s@^COCOS_ENGINE_PATH.*@COCOS_ENGINE_PATH=$NATIVE_ROOT@g" gradle.properties
Expand All @@ -199,7 +199,7 @@ jobs:
sed -i "s@^PROP_APP_ABI.*@PROP_APP_ABI=arm64-v8a@g" gradle.properties
echo "Compile Android - cmake ..."
echo "ANDORID_NDK ${ANDROID_NDK} or ${ANDROID_NDK_HOME}"
echo "ANDROID_NDK ${ANDROID_NDK} or ${ANDROID_NDK_HOME}"
./gradlew :CocosGame:assembleDebug --quiet
df -h
./gradlew clean
Expand Down

0 comments on commit c9f0b91

Please sign in to comment.