-
-
Notifications
You must be signed in to change notification settings - Fork 106
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
13 changed files
with
285 additions
and
203 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,7 +14,7 @@ jobs: | |
matrix: | ||
BUILD_TYPE: [Release] | ||
qt_arch: [android_arm64_v8a, android_armv7, android_x86_64] | ||
qt_version: [6.6.1] | ||
qt_version: [6.6.2] | ||
include: | ||
- BUILD_TYPE: Release | ||
qt_arch: android_arm64_v8a | ||
|
@@ -39,7 +39,7 @@ jobs: | |
VCPKGGITCOMMITID: eb33d2f7583405fca184bcdf7fdd5828ec88ac05 | ||
ANDROID_PLATFORM: android-23 | ||
ANDROID_NATIVE_API_LEVEL: 23 | ||
qt_modules: 'qtimageformats qtmultimedia qtscxml' | ||
qt_modules: 'qtwebengine qtimageformats qtmultimedia qtscxml qt5compat' | ||
|
||
# Map the job outputs to step outputs | ||
outputs: | ||
|
@@ -59,21 +59,61 @@ jobs: | |
cmake -E make_directory ${{github.workspace}}/build | ||
- name: Cache installed | ||
#if: false | ||
uses: actions/cache@v2 | ||
id: cache-installed | ||
with: | ||
path: | | ||
${{env.INSTALL_DIR}} | ||
key: cache-installed-android-qt${{matrix.qt_version}}-${{matrix.VCPKG_TARGET_TRIPLET}}-${{matrix.BUILD_TYPE}} | ||
key: install_android_qt${{matrix.qt_version}}_${{matrix.qt_arch}}_${{matrix.BUILD_TYPE}} | ||
|
||
- name: Cache Qt | ||
#if: false | ||
id: cache-qt | ||
uses: actions/cache@v1 # not v2! | ||
- name: run-vcpkg | ||
uses: lukka/run-vcpkg@v11 | ||
with: | ||
path: ${{env.TOOSL_DIR}}/qt | ||
key: qt${{matrix.qt_version}}_${{matrix.qt_arch}} | ||
# Indicates whether to only setup vcpkg (i.e. installing it and setting the environment variables VCPKG_ROOT, RUNVCPK_VCPKG_ROOT), without installing any port. | ||
#setupOnly: # optional | ||
#vcpkgGitURL: https://github.com/KangLin/vcpkg.git | ||
vcpkgGitCommitId: ${{env.VCPKGGITCOMMITID}} | ||
vcpkgDirectory: ${{ runner.workspace }}/vcpkg/ | ||
|
||
- name: build SeetaFace2 | ||
working-directory: ${{env.SOURCE_DIR}} | ||
run: | | ||
if [ ! -f ${{env.INSTALL_DIR}}/lib/cmake/SeetaFaceDetectorConfig.cmake ]; then | ||
git clone https://github.com/KangLin/SeetaFace2.git | ||
cd SeetaFace2 | ||
cmake -E make_directory build | ||
cd build | ||
cmake .. \ | ||
-DCMAKE_BUILD_TYPE=${{ matrix.BUILD_TYPE }} \ | ||
-DCMAKE_INSTALL_PREFIX=${{ env.INSTALL_DIR }} \ | ||
-DCMAKE_TOOLCHAIN_FILE=${{env.VCPKG_ROOT}}/scripts/buildsystems/vcpkg.cmake \ | ||
-DVCPKG_CHAINLbuildOAD_TOOLCHAIN_FILE=$ANDROID_NDK_HOME/build/cmake/android.toolchain.cmake \ | ||
-DANDROID_ABI=${{matrix.ANDROID_ABI}} \ | ||
-DANDROID_PLATFORM=${{matrix.ANDROID_PLATFORM}} \ | ||
-DBUILD_EXAMPLE=OFF | ||
cmake --build . --config ${{matrix.BUILD_TYPE}} | ||
cmake --build . --config ${{matrix.BUILD_TYPE}} --target install | ||
fi | ||
- name: build libfacedetection | ||
working-directory: ${{env.SOURCE_DIR}} | ||
run: | | ||
if [ ! -f ${{env.INSTALL_DIR}}/lib/cmake/facedetection/facedetectionConfig.cmake ]; then | ||
git clone https://github.com/ShiqiYu/libfacedetection.git | ||
cd libfacedetection | ||
cmake -E make_directory build | ||
cd build | ||
cmake .. \ | ||
-DCMAKE_BUILD_TYPE=${{ matrix.BUILD_TYPE }} \ | ||
-DCMAKE_INSTALL_PREFIX=${{ env.INSTALL_DIR }} \ | ||
-DCMAKE_TOOLCHAIN_FILE=${{env.VCPKG_ROOT}}/scripts/buildsystems/vcpkg.cmake \ | ||
-DVCPKG_CHAINLbuildOAD_TOOLCHAIN_FILE=$ANDROID_NDK_HOME/build/cmake/android.toolchain.cmake \ | ||
-DANDROID_ABI=${{matrix.ANDROID_ABI}} \ | ||
-DANDROID_PLATFORM=${{matrix.ANDROID_PLATFORM}} \ | ||
-DBUILD_SHARED_LIBS=ON | ||
cmake --build . --config ${{matrix.BUILD_TYPE}} | ||
cmake --build . --config ${{matrix.BUILD_TYPE}} --target install | ||
fi | ||
- name: Install Qt of gcc_64 | ||
uses: jurplel/install-qt-action@v3 | ||
|
@@ -84,7 +124,8 @@ jobs: | |
target: 'desktop' | ||
arch: 'gcc_64' | ||
set-env: false | ||
cached: '${{ steps.cache-qt.outputs.cache-hit }}' # optional, default is false | ||
cache: true | ||
cache-key-prefix: cached_qt | ||
|
||
- name: Install Qt of android | ||
uses: jurplel/install-qt-action@v3 | ||
|
@@ -101,33 +142,8 @@ jobs: | |
arch: '${{matrix.qt_arch}}' # optional | ||
# Additional Qt modules to install | ||
modules: '${{env.qt_modules}}' # optional. See: https://ddalcino.github.io/aqt-list-server/ | ||
cached: '${{ steps.cache-qt.outputs.cache-hit }}' # optional, default is false | ||
|
||
# - name: run-vcpkg | ||
# uses: lukka/[email protected] | ||
# with: | ||
# # Indicates whether to only setup vcpkg (i.e. installing it and setting the environment variables VCPKG_ROOT, RUNVCPK_VCPKG_ROOT), without installing any port. | ||
# #setupOnly: # optional | ||
# #vcpkgGitURL: https://github.com/KangLin/vcpkg.git | ||
# vcpkgGitCommitId: ${{env.VCPKGGITCOMMITID}} | ||
# vcpkgDirectory: ${{ runner.workspace }}/vcpkg/ | ||
# # Since the cache must be invalidated when content of the vcpkg.json file changes, let's | ||
# # compute its hash and append this to the computed cache's key. | ||
# appendedCacheKey: android_${{matrix.os}}-qt${{matrix.qt_version}}-${{matrix.VCPKG_TARGET_TRIPLET}}-${{matrix.BUILD_TYPE}}-${{env.VCPKGGITCOMMITID}} | ||
# additionalCachedPaths: $VCPKG_ROOT/installed | ||
# vcpkgTriplet: '${{ matrix.VCPKG_TARGET_TRIPLET }}' | ||
# vcpkgArguments: 'openssl ffmpeg opencv opencv[contrib] dlib ncnn' | ||
|
||
- name: run vcpkg | ||
working-directory: ${{env.SOURCE_DIR}} | ||
run: | | ||
if [ ! -d vcpkg ]; then | ||
git clone https://github.com/microsoft/vcpkg.git | ||
cd vcpkg | ||
git checkout -b ${{env.VCPKGGITCOMMITID}} ${{env.VCPKGGITCOMMITID}} | ||
./bootstrap-vcpkg.sh | ||
./vcpkg install --triplet=${{matrix.VCPKG_TARGET_TRIPLET}} openssl libyuv ffmpeg opencv[contrib] | ||
fi | ||
cache: true | ||
cache-key-prefix: cached_qt | ||
|
||
- name: git clone RabbitCommon | ||
working-directory: ${{env.SOURCE_DIR}} | ||
|
@@ -158,7 +174,11 @@ jobs: | |
-DVCPKG_VERBOSE=ON \ | ||
-DX_VCPKG_APPLOCAL_DEPS_INSTALL=ON \ | ||
-DCMAKE_TOOLCHAIN_FILE="${{env.VCPKG_ROOT}}\scripts\buildsystems\vcpkg.cmake" \ | ||
-DCMAKE_INSTALL_PREFIX=`pwd`/install | ||
-DCMAKE_INSTALL_PREFIX=`pwd`/install \ | ||
-DX_VCPKG_APPLOCAL_DEPS_INSTALL=ON \ | ||
-DVCPKG_APPLOCAL_DEPS=ON \ | ||
-DINSTALL_QT=ON \ | ||
-DENABLE_DOWNLOAD=ON | ||
cmake --build . --config ${{matrix.BUILD_TYPE}} --target all | ||
cmake --build . --config ${{matrix.BUILD_TYPE}} --target install | ||
APK_FILE=`find . -name "android-*.apk"` | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.