From 873a133ec2b5cab091db55448a89845ad5bebef4 Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Mon, 23 Oct 2023 13:22:42 -0400 Subject: [PATCH 01/21] Update build workflow --- .github/workflows/bcny-firebase.yml | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index 37f33a10c7..a5d3994b11 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -36,8 +36,16 @@ jobs: python-version: 3.9 architecture: 'x64' - - name: Install absl-py - run: pip install absl-py + - name: Install Desktop SDK prerequisites + uses: nick-invision/retry@v2 + with: + timeout_minutes: 15 + max_attempts: 3 + command: | + python scripts/gha/install_prereqs_desktop.py --gha_build --arch 'x64' + + # - name: Install absl-py + # run: pip install absl-py - name: Configure firebase run: From 6cd9d06329bde279422a44488bd1416f2f0d3de4 Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Mon, 23 Oct 2023 13:36:58 -0400 Subject: [PATCH 02/21] Fix paths --- .github/workflows/bcny-firebase.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index a5d3994b11..f5b6051836 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -42,7 +42,7 @@ jobs: timeout_minutes: 15 max_attempts: 3 command: | - python scripts/gha/install_prereqs_desktop.py --gha_build --arch 'x64' + python ${{ github.workspace }}/SourceCache/firebase-cpp-sdk/scripts/gha/install_prereqs_desktop.py --gha_build --arch 'x64' # - name: Install absl-py # run: pip install absl-py From 9835e466f17dc46b9f834711d0cbabdcf86cfca3 Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Mon, 23 Oct 2023 13:51:29 -0400 Subject: [PATCH 03/21] See if our checkout paths make a difference --- .github/workflows/bcny-firebase.yml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index f5b6051836..159cbea5b1 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -19,8 +19,7 @@ jobs: steps: - uses: actions/checkout@v3 with: - fetch-depth: 1 - path: ${{ github.workspace }}/SourceCache/firebase-cpp-sdk + submodules: true ref: refs/heads/compnerd/swift repository: thebrowsercompany/firebase-cpp-sdk @@ -42,7 +41,7 @@ jobs: timeout_minutes: 15 max_attempts: 3 command: | - python ${{ github.workspace }}/SourceCache/firebase-cpp-sdk/scripts/gha/install_prereqs_desktop.py --gha_build --arch 'x64' + python scripts/gha/install_prereqs_desktop.py --gha_build --arch 'x64' # - name: Install absl-py # run: pip install absl-py @@ -55,7 +54,7 @@ jobs: -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/firebase/usr ` -G "Visual Studio 17 2022" ` -A ${{ matrix.platform }} ` - -S ${{ github.workspace }}/SourceCache/firebase-cpp-sdk ` + -S . ` -D FIREBASE_CPP_BUILD_PACKAGE=YES ` -D FIREBASE_GITHUB_ACTION_BUILD=YES ` -D FIREBASE_INCLUDE_LIBRARY_DEFAULT=OFF ` From 564a80beeb9bd3b9689f9ff9ff86ef8d40e11aef Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Mon, 23 Oct 2023 14:58:14 -0400 Subject: [PATCH 04/21] Try to get closer to upstream --- .github/workflows/bcny-firebase.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index 159cbea5b1..e53f26bbc7 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -32,7 +32,7 @@ jobs: - uses: actions/setup-python@v4 id: python with: - python-version: 3.9 + python-version: 3.7 architecture: 'x64' - name: Install Desktop SDK prerequisites @@ -62,7 +62,6 @@ jobs: -D FIREBASE_INCLUDE_FIRESTORE=YES ` -D FIREBASE_USE_BORINGSSL=YES ` -D MSVC_RUNTIME_LIBRARY_STATIC=NO ` - -D Python3_EXECUTABLE=${{ steps.python.outputs.python-path }} - name: Build firebase run: cmake --build ${{ github.workspace }}/BinaryCache/firebase --config Release - name: Install firebase From 77de34e1295dd0f92d941b105cae4a840c3c57f0 Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Mon, 23 Oct 2023 15:07:46 -0400 Subject: [PATCH 05/21] Fix path --- .github/workflows/bcny-firebase.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index e53f26bbc7..aad50c00c9 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -54,7 +54,7 @@ jobs: -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/firebase/usr ` -G "Visual Studio 17 2022" ` -A ${{ matrix.platform }} ` - -S . ` + -S ${{ github.workspace }} ` -D FIREBASE_CPP_BUILD_PACKAGE=YES ` -D FIREBASE_GITHUB_ACTION_BUILD=YES ` -D FIREBASE_INCLUDE_LIBRARY_DEFAULT=OFF ` From 1d838b90e3cbb961e22616411404d283bd58bf56 Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Mon, 23 Oct 2023 15:31:24 -0400 Subject: [PATCH 06/21] Fix platform --- .github/workflows/bcny-firebase.yml | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index aad50c00c9..2d5426c00c 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -41,10 +41,7 @@ jobs: timeout_minutes: 15 max_attempts: 3 command: | - python scripts/gha/install_prereqs_desktop.py --gha_build --arch 'x64' - - # - name: Install absl-py - # run: pip install absl-py + python scripts/gha/install_prereqs_desktop.py --gha_build --arch ${{ matrix.platform }} - name: Configure firebase run: From c8ec4fbf7cf6a86ffc06c5ca8080b6d33ca34b3b Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Mon, 23 Oct 2023 15:42:22 -0400 Subject: [PATCH 07/21] Debug with dir --- .github/workflows/bcny-firebase.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index 2d5426c00c..a136de238b 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -45,7 +45,7 @@ jobs: - name: Configure firebase run: - cmake -B ${{ github.workspace }}/BinaryCache/firebase ` + cmake -B ${{ github.workspace }}\\BinaryCache\\firebase ` -D BUILD_SHARED_LIBS=NO ` -D CMAKE_BUILD_TYPE=Release ` -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/firebase/usr ` @@ -59,6 +59,9 @@ jobs: -D FIREBASE_INCLUDE_FIRESTORE=YES ` -D FIREBASE_USE_BORINGSSL=YES ` -D MSVC_RUNTIME_LIBRARY_STATIC=NO ` + + - name: List structure + run: dir . - name: Build firebase run: cmake --build ${{ github.workspace }}/BinaryCache/firebase --config Release - name: Install firebase From 3cb934a52792601f445091110fdd0e5447551fa3 Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Mon, 23 Oct 2023 15:51:34 -0400 Subject: [PATCH 08/21] Go back to mostly what we used to have --- .github/workflows/bcny-firebase.yml | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index a136de238b..0e67c8eaab 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -19,7 +19,8 @@ jobs: steps: - uses: actions/checkout@v3 with: - submodules: true + fetch-depth: 1 + path: ${{ github.workspace }}/SourceCache/firebase-cpp-sdk ref: refs/heads/compnerd/swift repository: thebrowsercompany/firebase-cpp-sdk @@ -35,23 +36,26 @@ jobs: python-version: 3.7 architecture: 'x64' - - name: Install Desktop SDK prerequisites - uses: nick-invision/retry@v2 - with: - timeout_minutes: 15 - max_attempts: 3 - command: | - python scripts/gha/install_prereqs_desktop.py --gha_build --arch ${{ matrix.platform }} + - name: Install absl-py + run: pip install absl-py + + # - name: Install Desktop SDK prerequisites + # uses: nick-invision/retry@v2 + # with: + # timeout_minutes: 15 + # max_attempts: 3 + # command: | + # python scripts/gha/install_prereqs_desktop.py --gha_build --arch ${{ matrix.platform }} - name: Configure firebase run: - cmake -B ${{ github.workspace }}\\BinaryCache\\firebase ` + cmake -B ${{ github.workspace }}/BinaryCache/firebase ` -D BUILD_SHARED_LIBS=NO ` -D CMAKE_BUILD_TYPE=Release ` -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/firebase/usr ` -G "Visual Studio 17 2022" ` -A ${{ matrix.platform }} ` - -S ${{ github.workspace }} ` + -S ${{ github.workspace }}/SourceCache/firebase-cpp-sdk ` -D FIREBASE_CPP_BUILD_PACKAGE=YES ` -D FIREBASE_GITHUB_ACTION_BUILD=YES ` -D FIREBASE_INCLUDE_LIBRARY_DEFAULT=OFF ` From baee60559286167e2ab6fb8667a67ea142a12f94 Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Mon, 23 Oct 2023 15:59:34 -0400 Subject: [PATCH 09/21] Remove trailing back tick --- .github/workflows/bcny-firebase.yml | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index 0e67c8eaab..aa07469088 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -39,14 +39,6 @@ jobs: - name: Install absl-py run: pip install absl-py - # - name: Install Desktop SDK prerequisites - # uses: nick-invision/retry@v2 - # with: - # timeout_minutes: 15 - # max_attempts: 3 - # command: | - # python scripts/gha/install_prereqs_desktop.py --gha_build --arch ${{ matrix.platform }} - - name: Configure firebase run: cmake -B ${{ github.workspace }}/BinaryCache/firebase ` @@ -62,7 +54,7 @@ jobs: -D FIREBASE_INCLUDE_AUTH=YES ` -D FIREBASE_INCLUDE_FIRESTORE=YES ` -D FIREBASE_USE_BORINGSSL=YES ` - -D MSVC_RUNTIME_LIBRARY_STATIC=NO ` + -D MSVC_RUNTIME_LIBRARY_STATIC=NO - name: List structure run: dir . From 1e491b3c376ce3be4d8256bd5922bd36eaa1b53b Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Mon, 23 Oct 2023 16:12:02 -0400 Subject: [PATCH 10/21] Pull over the deletion of Strawberry from the upstream script --- .github/workflows/bcny-firebase.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index aa07469088..6639abbcff 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -39,6 +39,9 @@ jobs: - name: Install absl-py run: pip install absl-py + - name: Remove Strawberry + run: "rm -r C:\\Strawberry" + - name: Configure firebase run: cmake -B ${{ github.workspace }}/BinaryCache/firebase ` From fc3b80e0f048a66f95c5c2a7b75f256f79053765 Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Mon, 23 Oct 2023 13:23:28 -0400 Subject: [PATCH 11/21] Test the workflow on push --- .github/workflows/bcny-firebase.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index 6639abbcff..8245b36db2 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -1,6 +1,7 @@ name: firebase on: + pull_request: workflow_dispatch: jobs: From 03d1bd7c8f4824ed2ef29239202ef29876211c9c Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Wed, 8 Nov 2023 06:23:27 -0500 Subject: [PATCH 12/21] add ssh debugging --- .github/workflows/bcny-firebase.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index 8245b36db2..9648470dea 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -43,6 +43,12 @@ jobs: - name: Remove Strawberry run: "rm -r C:\\Strawberry" + - name: Start SSH session + uses: luchihoratiu/debug-via-ssh@main + with: + NGROK_AUTH_TOKEN: ${{ secrets.NGROK_AUTH_TOKEN }} + SSH_PASS: ${{ secrets.SSH_PASS }} + - name: Configure firebase run: cmake -B ${{ github.workspace }}/BinaryCache/firebase ` From fd3ce590b2a36fdf69f7e55fb0d5d88010411446 Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Wed, 8 Nov 2023 12:03:37 +0000 Subject: [PATCH 13/21] use requirements --- .github/workflows/bcny-firebase.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index 9648470dea..92869901c3 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -37,8 +37,9 @@ jobs: python-version: 3.7 architecture: 'x64' - - name: Install absl-py - run: pip install absl-py + - name: Run Python Setup + run: | + python3 -m pip install -r ${{ github.workspace }}/SourceCache/firebase-cpp-sdk/external/pip_requirements.txt --user - name: Remove Strawberry run: "rm -r C:\\Strawberry" From a94b2061544681b0f5ae19ae34db3674e85cb789 Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Wed, 8 Nov 2023 12:06:16 +0000 Subject: [PATCH 14/21] Remove SSH setup --- .github/workflows/bcny-firebase.yml | 6 ------ 1 file changed, 6 deletions(-) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index 92869901c3..8ef0014ce0 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -44,12 +44,6 @@ jobs: - name: Remove Strawberry run: "rm -r C:\\Strawberry" - - name: Start SSH session - uses: luchihoratiu/debug-via-ssh@main - with: - NGROK_AUTH_TOKEN: ${{ secrets.NGROK_AUTH_TOKEN }} - SSH_PASS: ${{ secrets.SSH_PASS }} - - name: Configure firebase run: cmake -B ${{ github.workspace }}/BinaryCache/firebase ` From 721c201b228013402df4e1c7263f53dd830e5f35 Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Wed, 8 Nov 2023 12:21:38 +0000 Subject: [PATCH 15/21] Revert to Python 3.9 --- .github/workflows/bcny-firebase.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index 8ef0014ce0..b7e917693b 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -34,7 +34,7 @@ jobs: - uses: actions/setup-python@v4 id: python with: - python-version: 3.7 + python-version: 3.9 architecture: 'x64' - name: Run Python Setup From 7e510dcd193629ba5db73d916f86c87f95e5cb4f Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Wed, 8 Nov 2023 12:27:20 +0000 Subject: [PATCH 16/21] See if we need the vssetup --- .github/workflows/bcny-firebase.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index b7e917693b..29db17584e 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -25,16 +25,16 @@ jobs: ref: refs/heads/compnerd/swift repository: thebrowsercompany/firebase-cpp-sdk - - uses: compnerd/gha-setup-vsdevenv@main - with: - host_arch: amd64 - components: 'Microsoft.VisualStudio.Component.VC.Tools.x86.x64;Microsoft.VisualStudio.Component.VC.Tools.ARM64' - arch: ${{ matrix.arch }} + # - uses: compnerd/gha-setup-vsdevenv@main + # with: + # host_arch: amd64 + # components: 'Microsoft.VisualStudio.Component.VC.Tools.x86.x64;Microsoft.VisualStudio.Component.VC.Tools.ARM64' + # arch: ${{ matrix.arch }} - uses: actions/setup-python@v4 id: python with: - python-version: 3.9 + python-version: 3.7 architecture: 'x64' - name: Run Python Setup From a652451b3f441b406d53b560c98289b6c7b74340 Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Wed, 8 Nov 2023 13:31:20 +0000 Subject: [PATCH 17/21] Try running in bash instead of pwsh --- .github/workflows/bcny-firebase.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index 29db17584e..f88c68d2b4 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -45,6 +45,7 @@ jobs: run: "rm -r C:\\Strawberry" - name: Configure firebase + shell: bash run: cmake -B ${{ github.workspace }}/BinaryCache/firebase ` -D BUILD_SHARED_LIBS=NO ` From 89b8d27cf71ce905b09540999448e38ce61f6f54 Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Wed, 8 Nov 2023 14:12:06 +0000 Subject: [PATCH 18/21] backticks to back slashes --- .github/workflows/bcny-firebase.yml | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index f88c68d2b4..1810ebbadf 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -47,19 +47,19 @@ jobs: - name: Configure firebase shell: bash run: - cmake -B ${{ github.workspace }}/BinaryCache/firebase ` - -D BUILD_SHARED_LIBS=NO ` - -D CMAKE_BUILD_TYPE=Release ` - -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/firebase/usr ` - -G "Visual Studio 17 2022" ` - -A ${{ matrix.platform }} ` - -S ${{ github.workspace }}/SourceCache/firebase-cpp-sdk ` - -D FIREBASE_CPP_BUILD_PACKAGE=YES ` - -D FIREBASE_GITHUB_ACTION_BUILD=YES ` - -D FIREBASE_INCLUDE_LIBRARY_DEFAULT=OFF ` - -D FIREBASE_INCLUDE_AUTH=YES ` - -D FIREBASE_INCLUDE_FIRESTORE=YES ` - -D FIREBASE_USE_BORINGSSL=YES ` + cmake -B ${{ github.workspace }}/BinaryCache/firebase \ + -D BUILD_SHARED_LIBS=NO \ + -D CMAKE_BUILD_TYPE=Release \ + -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/firebase/usr \ + -G "Visual Studio 17 2022" \ + -A ${{ matrix.platform }} \ + -S ${{ github.workspace }}/SourceCache/firebase-cpp-sdk \ + -D FIREBASE_CPP_BUILD_PACKAGE=YES \ + -D FIREBASE_GITHUB_ACTION_BUILD=YES \ + -D FIREBASE_INCLUDE_LIBRARY_DEFAULT=OFF \ + -D FIREBASE_INCLUDE_AUTH=YES \ + -D FIREBASE_INCLUDE_FIRESTORE=YES \ + -D FIREBASE_USE_BORINGSSL=YES \ -D MSVC_RUNTIME_LIBRARY_STATIC=NO - name: List structure From f0ac27bf61f4acf35716a3f8e6f7e2cc8e5807a7 Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Wed, 8 Nov 2023 14:17:51 +0000 Subject: [PATCH 19/21] Put backticks back, try upstream's method --- .github/workflows/bcny-firebase.yml | 31 ++++++++++++++++------------- 1 file changed, 17 insertions(+), 14 deletions(-) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index 1810ebbadf..5b19f6aad4 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -44,22 +44,25 @@ jobs: - name: Remove Strawberry run: "rm -r C:\\Strawberry" + - name: Build SDK + run: + python3 ${{ github.workspace }}/SourceCache/firebase-cpp-sdk/scripts/gha/build_desktop.py --arch "${{ matrix.arch }}" --config "Release" --msvc_runtime_library "dynamic" --gha_build + - name: Configure firebase - shell: bash run: - cmake -B ${{ github.workspace }}/BinaryCache/firebase \ - -D BUILD_SHARED_LIBS=NO \ - -D CMAKE_BUILD_TYPE=Release \ - -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/firebase/usr \ - -G "Visual Studio 17 2022" \ - -A ${{ matrix.platform }} \ - -S ${{ github.workspace }}/SourceCache/firebase-cpp-sdk \ - -D FIREBASE_CPP_BUILD_PACKAGE=YES \ - -D FIREBASE_GITHUB_ACTION_BUILD=YES \ - -D FIREBASE_INCLUDE_LIBRARY_DEFAULT=OFF \ - -D FIREBASE_INCLUDE_AUTH=YES \ - -D FIREBASE_INCLUDE_FIRESTORE=YES \ - -D FIREBASE_USE_BORINGSSL=YES \ + cmake -B ${{ github.workspace }}/BinaryCache/firebase ` + -D BUILD_SHARED_LIBS=NO ` + -D CMAKE_BUILD_TYPE=Release ` + -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/firebase/usr ` + -G "Visual Studio 17 2022" ` + -A ${{ matrix.platform }} ` + -S ${{ github.workspace }}/SourceCache/firebase-cpp-sdk ` + -D FIREBASE_CPP_BUILD_PACKAGE=YES ` + -D FIREBASE_GITHUB_ACTION_BUILD=YES ` + -D FIREBASE_INCLUDE_LIBRARY_DEFAULT=OFF ` + -D FIREBASE_INCLUDE_AUTH=YES ` + -D FIREBASE_INCLUDE_FIRESTORE=YES ` + -D FIREBASE_USE_BORINGSSL=YES ` -D MSVC_RUNTIME_LIBRARY_STATIC=NO - name: List structure From 6e57aa317b1807b15b3e91cff18e3b5cd40a4930 Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Wed, 8 Nov 2023 18:15:43 +0000 Subject: [PATCH 20/21] go more in the direction of the upstream ci --- .github/workflows/bcny-firebase.yml | 70 ++++++++++------------------- 1 file changed, 23 insertions(+), 47 deletions(-) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index 5b19f6aad4..e2cc6717d0 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -21,16 +21,9 @@ jobs: - uses: actions/checkout@v3 with: fetch-depth: 1 - path: ${{ github.workspace }}/SourceCache/firebase-cpp-sdk ref: refs/heads/compnerd/swift repository: thebrowsercompany/firebase-cpp-sdk - # - uses: compnerd/gha-setup-vsdevenv@main - # with: - # host_arch: amd64 - # components: 'Microsoft.VisualStudio.Component.VC.Tools.x86.x64;Microsoft.VisualStudio.Component.VC.Tools.ARM64' - # arch: ${{ matrix.arch }} - - uses: actions/setup-python@v4 id: python with: @@ -39,53 +32,36 @@ jobs: - name: Run Python Setup run: | - python3 -m pip install -r ${{ github.workspace }}/SourceCache/firebase-cpp-sdk/external/pip_requirements.txt --user + python3 -m pip install -r .\external\pip_requirements.txt --user - name: Remove Strawberry run: "rm -r C:\\Strawberry" - name: Build SDK run: - python3 ${{ github.workspace }}/SourceCache/firebase-cpp-sdk/scripts/gha/build_desktop.py --arch "${{ matrix.arch }}" --config "Release" --msvc_runtime_library "dynamic" --gha_build - - - name: Configure firebase - run: - cmake -B ${{ github.workspace }}/BinaryCache/firebase ` - -D BUILD_SHARED_LIBS=NO ` - -D CMAKE_BUILD_TYPE=Release ` - -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/firebase/usr ` - -G "Visual Studio 17 2022" ` - -A ${{ matrix.platform }} ` - -S ${{ github.workspace }}/SourceCache/firebase-cpp-sdk ` - -D FIREBASE_CPP_BUILD_PACKAGE=YES ` - -D FIREBASE_GITHUB_ACTION_BUILD=YES ` - -D FIREBASE_INCLUDE_LIBRARY_DEFAULT=OFF ` - -D FIREBASE_INCLUDE_AUTH=YES ` - -D FIREBASE_INCLUDE_FIRESTORE=YES ` - -D FIREBASE_USE_BORINGSSL=YES ` - -D MSVC_RUNTIME_LIBRARY_STATIC=NO + python3 .\scripts\gha\build_desktop.py --arch "${{ matrix.arch }}" --config "Release" --msvc_runtime_library "dynamic" --gha_build - name: List structure run: dir . - - name: Build firebase - run: cmake --build ${{ github.workspace }}/BinaryCache/firebase --config Release - - name: Install firebase - run: cmake --build ${{ github.workspace }}/BinaryCache/firebase --config Release --target install - - name: Install firebase (manual) - run: | - Copy-Item "${{ github.workspace }}/BinaryCache/firebase/external/src/firestore/Firestore/core/include/firebase/firestore/firestore_errors.h" "${{ github.workspace }}/BuildRoot/Library/firebase/usr/include/firebase/firestore/firestore_errors.h" - Copy-Item "${{ github.workspace }}/BinaryCache/firebase/external/src/firestore/Firestore/core/include/firebase/firestore/geo_point.h" "${{ github.workspace }}/BuildRoot/Library/firebase/usr/include/firebase/firestore/geo_point.h" - Copy-Item "${{ github.workspace }}/BinaryCache/firebase/external/src/firestore/Firestore/core/include/firebase/firestore/timestamp.h" "${{ github.workspace }}/BuildRoot/Library/firebase/usr/include/firebase/firestore/timestamp.h" + # - name: Build firebase + # run: cmake --build ${{ github.workspace }}/BinaryCache/firebase --config Release + # - name: Install firebase + # run: cmake --build ${{ github.workspace }}/BinaryCache/firebase --config Release --target install + # - name: Install firebase (manual) + # run: | + # Copy-Item "${{ github.workspace }}/BinaryCache/firebase/external/src/firestore/Firestore/core/include/firebase/firestore/firestore_errors.h" "${{ github.workspace }}/BuildRoot/Library/firebase/usr/include/firebase/firestore/firestore_errors.h" + # Copy-Item "${{ github.workspace }}/BinaryCache/firebase/external/src/firestore/Firestore/core/include/firebase/firestore/geo_point.h" "${{ github.workspace }}/BuildRoot/Library/firebase/usr/include/firebase/firestore/geo_point.h" + # Copy-Item "${{ github.workspace }}/BinaryCache/firebase/external/src/firestore/Firestore/core/include/firebase/firestore/timestamp.h" "${{ github.workspace }}/BuildRoot/Library/firebase/usr/include/firebase/firestore/timestamp.h" - Write-Host "Copying static libraries ..." - $source = "${{ github.workspace }}/BinaryCache/firebase" - $libraries = Get-ChildItem -Path $source -File -Recurse -Filter *.lib - foreach ($library in $libraries) { - $destination = Join-Path -Path "${{ github.workspace }}/BuildRoot/Library/firebase/usr/libs/windows" -ChildPath $library.Name - Copy-Item -Path $library.FullName -Destination $destination -Force - Write-Host "... copied ${destination}" - } - - uses: actions/upload-artifact@v3 - with: - name: firebase-windows-${{ matrix.arch }} - path: ${{ github.workspace }}/BuildRoot/Library/firebase + # Write-Host "Copying static libraries ..." + # $source = "${{ github.workspace }}/BinaryCache/firebase" + # $libraries = Get-ChildItem -Path $source -File -Recurse -Filter *.lib + # foreach ($library in $libraries) { + # $destination = Join-Path -Path "${{ github.workspace }}/BuildRoot/Library/firebase/usr/libs/windows" -ChildPath $library.Name + # Copy-Item -Path $library.FullName -Destination $destination -Force + # Write-Host "... copied ${destination}" + # } + # - uses: actions/upload-artifact@v3 + # with: + # name: firebase-windows-${{ matrix.arch }} + # path: ${{ github.workspace }}/BuildRoot/Library/firebase From 760405feaa3d92da26778f7e9c653e9d82e1a920 Mon Sep 17 00:00:00 2001 From: Brian Michel Date: Wed, 8 Nov 2023 18:24:04 +0000 Subject: [PATCH 21/21] Don't limit fetch depth --- .github/workflows/bcny-firebase.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/bcny-firebase.yml b/.github/workflows/bcny-firebase.yml index e2cc6717d0..529bdfb82c 100644 --- a/.github/workflows/bcny-firebase.yml +++ b/.github/workflows/bcny-firebase.yml @@ -20,7 +20,7 @@ jobs: steps: - uses: actions/checkout@v3 with: - fetch-depth: 1 + submodules: false ref: refs/heads/compnerd/swift repository: thebrowsercompany/firebase-cpp-sdk