From 9987b5e79bfbc035d929624fae6862a4fd411767 Mon Sep 17 00:00:00 2001 From: itsmattkc <34096995+itsmattkc@users.noreply.github.com> Date: Wed, 16 Sep 2020 13:13:24 +1000 Subject: [PATCH 1/3] ci: utilize prebuilt crashpad --- .github/workflows/ci.yml | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9be7e10e8..03d48b946 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -61,17 +61,9 @@ jobs: - name: Acquire Boost run: curl -fLOSs --retry 3 http://olivevideoeditor.org/deps/boost-win.7z && 7z x boost-win.7z - - # Crashpad requires Python 2.7 - - name: Set up Python 2.7 - uses: actions/setup-python@v2 - with: - python-version: 2.7 - name: Acquire Crashpad - shell: cmd - run: | - git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git && depot_tools\fetch crashpad && cd crashpad && ..\depot_tools\gn gen out/Default && sed -i "s/${cflags_c}/${cflags_c} \/MD/g" out\Default\toolchain.ninja && ninja.exe -C out/Default + run: curl -fLOSs --retry 3 http://olivevideoeditor.org/deps/crashpad-win.7z && 7z x crashpad-win.7z - name: Configure CMake # Use a bash shell so we can use the same syntax for environment variable From fb9ca9b42cb14f50416dbe76c4c758f8a7bd3a71 Mon Sep 17 00:00:00 2001 From: itsmattkc <34096995+itsmattkc@users.noreply.github.com> Date: Wed, 16 Sep 2020 13:28:48 +1000 Subject: [PATCH 2/3] ci: package crashpad handler executable --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 03d48b946..cafc2a6a1 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -73,7 +73,7 @@ jobs: # Note the current convention is to use the -S and -B options here to specify source # and build directories, but this is only available with CMake 3.13 and higher. # The CMake binaries on the Github Actions machines are (as of this writing) 3.12 - run: PATH=$GITHUB_WORKSPACE:$GITHUB_WORKSPACE/crashpad:$PATH cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=$BUILD_TYPE -G "Ninja" + run: PATH=$GITHUB_WORKSPACE:$PATH cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=$BUILD_TYPE -G "Ninja" - name: Build working-directory: ${{runner.workspace}}/build @@ -97,7 +97,7 @@ jobs: shell: cmd env: HASH: ${{steps.vars.outputs.git_shorthash}} - run: mkdir olive-editor && copy app\olive-editor.exe olive-editor && copy app\olive-editor.pdb olive-editor && windeployqt olive-editor\olive-editor.exe && copy %GITHUB_WORKSPACE%\bin\*.dll olive-editor + run: mkdir olive-editor && copy app\olive-editor.exe olive-editor && copy app\olive-editor.pdb olive-editor && windeployqt olive-editor\olive-editor.exe && copy %GITHUB_WORKSPACE%\bin\*.dll olive-editor && copy %GITHUB_WORKSPACE%\out\Default\crashpad_handler.exe olive-editor - name: Deploy Installer working-directory: ${{runner.workspace}}/build From 189d05d50fdcc6b0dbc37fd28ad55fea5fcc0ab7 Mon Sep 17 00:00:00 2001 From: itsmattkc <34096995+itsmattkc@users.noreply.github.com> Date: Wed, 16 Sep 2020 14:03:19 +1000 Subject: [PATCH 3/3] ci: package name --- .github/workflows/ci.yml | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index cafc2a6a1..6fca90c47 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,8 +16,6 @@ jobs: # cross-platform coverage. # See: https://docs.github.com/en/actions/configuring-and-managing-workflows/configuring-a-workflow#configuring-a-build-matrix runs-on: windows-latest - env: - PKGNAME: Olive-%HASH%-Windows-x86_64 steps: - uses: actions/checkout@v2 @@ -88,31 +86,31 @@ jobs: # See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail run: ctest -C $BUILD_TYPE - - name: Get Git short hash + - name: Generate Package Name id: vars - run: echo ::set-output name=git_shorthash::$(git rev-parse --short=8 ${{github.sha}}) + run: echo ::set-output name=pkgname::Olive-$(git rev-parse --short=8 ${{github.sha}})-Windows-x86_64 - name: Create Package working-directory: ${{runner.workspace}}/build shell: cmd - env: - HASH: ${{steps.vars.outputs.git_shorthash}} run: mkdir olive-editor && copy app\olive-editor.exe olive-editor && copy app\olive-editor.pdb olive-editor && windeployqt olive-editor\olive-editor.exe && copy %GITHUB_WORKSPACE%\bin\*.dll olive-editor && copy %GITHUB_WORKSPACE%\out\Default\crashpad_handler.exe olive-editor - name: Deploy Installer working-directory: ${{runner.workspace}}/build shell: cmd env: - HASH: ${{steps.vars.outputs.git_shorthash}} + PKGNAME: ${{steps.vars.outputs.pkgname}} run: copy %GITHUB_WORKSPACE%\app\packaging\windows\nsis\* . && copy %GITHUB_WORKSPACE%\LICENSE . && "C:/Program Files (x86)/NSIS/makensis.exe" -V4 -DX64 "-XOutFile %PKGNAME%.exe" olive.nsi - name: Deploy Portable working-directory: ${{runner.workspace}}/build shell: cmd + env: + PKGNAME: ${{steps.vars.outputs.pkgname}} run: type NUL > olive-editor\portable && 7z a %PKGNAME%.zip olive-editor - name: Upload artifact uses: actions/upload-artifact@v2 with: name: Windows (x86_64) - path: ${{runner.workspace}}/build/${PKGNAME}.* + path: ${{runner.workspace}}/build/${{steps.vars.outputs.pkgname}}.*