From 7bf5eb2b5ba050d845f3f7c052bfa23e4df87078 Mon Sep 17 00:00:00 2001 From: Alex Lorenz Date: Fri, 17 May 2024 12:30:13 -0700 Subject: [PATCH] andy2 --- .github/workflows/bcny-firebase.yml | 28 +++++++++++++++++++--------- 1 file changed, 19 insertions(+), 9 deletions(-) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index dc6a3bc05f..ebb91863bd 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -336,13 +336,6 @@ jobs: - name: Install absl-py run: pip install absl-py - - name: Build SDK - shell: bash - if: false - run: | - cd ${{ github.workspace }}/SourceCache/firebase-cpp-sdk - build_scripts/android/build.sh android_build . - - name: Build run: | echo "NDK: $NDK_ROOT" @@ -362,17 +355,19 @@ jobs: -DANDROID_ABI=$arch \ -DANDROID_PLATFORM=android-19 \ -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=$dst_dir/$module/build/intermediates/cmake/release/obj/$arch \ + -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/firebase/usr \ -DCMAKE_BUILD_TYPE=Release \ -DANDROID_NDK=$ndk_dir \ -DCMAKE_TOOLCHAIN_FILE=$ndk_dir/build/cmake/android.toolchain.cmake \ -GNinja \ -DFIREBASE_INCLUDE_LIBRARY_DEFAULT=OFF \ + -D FIREBASE_GITHUB_ACTION_BUILD=YES \ $extra_params" echo "Configuring $module..." eval "$config_command" - build_command="cmake --build $dst_dir/$module/.externalNativeBuild/cmake/release/$arch" echo "Building $module..." - eval "$build_command" + cmake --build $dst_dir/$module/.externalNativeBuild/cmake/release/$arch + cmake --build $dst_dir/$module/.externalNativeBuild/cmake/release/$arch -- install } arch="${{ matrix.arch }}" cd ${{ github.workspace }}/SourceCache/firebase-cpp-sdk @@ -394,3 +389,18 @@ jobs: cmake_build $arch "auth" "-DFIREBASE_CPP_USE_PRIOR_GRADLE_BUILD=ON -DFIREBASE_INCLUDE_AUTH=ON" cmake_build $arch "functions" "-DFIREBASE_CPP_USE_PRIOR_GRADLE_BUILD=ON -DFIREBASE_INCLUDE_FUNCTIONS=ON" cmake_build $arch "remote_config" "-DFIREBASE_CPP_USE_PRIOR_GRADLE_BUILD=ON -DFIREBASE_INCLUDE_REMOTE_CONFIG=ON" + + - name: Install (manual) + run: | + echo "Copying static libraries ..." + source="${{ github.workspace }}/SourceCache/firebase-cpp-sdk" + destination_dir=${{ github.workspace }}/BuildRoot/Library/firebase/usr/libs/android/${{ matrix.arch }} + while IFS= read -r file; do + cp "$file" "$destination_dir" + echo "Copied: $file" + done < <(find $source -type f -name "*.a") + + - uses: actions/upload-artifact@v3 + with: + name: firebase-android-${{ matrix.arch }} + path: ${{ github.workspace }}/BuildRoot/Library/firebase