Skip to content

Commit

Permalink
GitHub Actions CI: update workflow
Browse files Browse the repository at this point in the history
- update vcpkg to latest commit (includes updated libtorrent port)
- drop custom libtorrent port
- restore AppleClang workaround in the workflow file
- include install_manifest.txt in uploaded artifacts
- update actions to latest versions
- fix typos
  • Loading branch information
FranciscoPombal committed May 4, 2021
1 parent 2f1ec09 commit 211c92c
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 135 deletions.
24 changes: 14 additions & 10 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ name: GitHub Actions CI
on: [pull_request, push]

env:
VCPKG_COMMIT: e4ce66eecfd3e5cca5eac06c971921bf8e37cf88
VCPKG_COMMIT: 8f03e2264da6b95fa5b01dd89cdd5b499458d428
VCPKG_DEST_MACOS: /Users/runner/qbt_tools/vcpkg
VCPKG_DEST_WIN: C:\qbt_tools\vcpkg
LIBTORRENT_VERSION_TAG: v1.2.13
Expand Down Expand Up @@ -63,14 +63,15 @@ jobs:
cmake --build build
- name: install qBittorrent
run: sudo cmake --build build --target install
run: sudo cmake --install build --prefix /usr/local

- name: upload artifact as zip
uses: actions/upload-artifact@v2
with:
name: qBittorrent-CI_${{ matrix.os }}-x64_${{ matrix.qbt_gui }}
path: |
build/compile_commands.json
build/install_manifest.txt
build/target_graph.dot
build/qbittorrent
build/qbittorrent-nox
Expand All @@ -90,13 +91,13 @@ jobs:
- name: checkout repository
uses: actions/checkout@v2

# - ninja is needed for building qBittorrent (because it's preferrable, not a hard requirement)
# - ninja is needed for building qBittorrent (because it's preferable, not a hard requirement)
- name: install additional required packages with chocolatey
run: |
choco install ninja
- name: setup vcpkg (cached, if possible)
uses: lukka/run-vcpkg@v4
uses: lukka/run-vcpkg@v7
with:
vcpkgDirectory: ${{ env.VCPKG_DEST_WIN }}
vcpkgGitCommitId: ${{ env.VCPKG_COMMIT }}
Expand All @@ -123,13 +124,11 @@ jobs:
"qt5-winextras:x64-windows-static-release"
${{ env.RUNVCPKG_VCPKG_ROOT }}/vcpkg.exe upgrade `
--overlay-triplets=${{ github.workspace }}/triplets_overlay `
--overlay-ports=${{ github.workspace }}/vcpkg `
--no-dry-run
foreach($package in $packages)
{
${{ env.RUNVCPKG_VCPKG_ROOT }}/vcpkg.exe install $package `
--overlay-triplets=${{ github.workspace }}/triplets_overlay `
--overlay-ports=${{ github.workspace }}/vcpkg `
--clean-after-build
}
Expand Down Expand Up @@ -178,15 +177,15 @@ jobs:
- name: checkout repository
uses: actions/checkout@v2

# - ninja is needed for building qBittorrent (because it's preferrable, not a hard requirement)
# - ninja is needed for building qBittorrent (because it's preferable, not a hard requirement)
# - automake is needed for the installation the vcpkg installation of fontconfig, a dependency of qt5-base
- name: install additional required packages with homebrew
shell: bash
run: |
brew install automake ninja
- name: setup vcpkg (cached, if possible)
uses: lukka/run-vcpkg@v4
uses: lukka/run-vcpkg@v7
with:
vcpkgDirectory: ${{ env.VCPKG_DEST_MACOS }}
vcpkgGitCommitId: ${{ env.VCPKG_COMMIT }}
Expand All @@ -200,6 +199,13 @@ jobs:
Add-Content ${{ github.workspace }}/triplets_overlay/x64-osx-release.cmake `
-Value "set(VCPKG_BUILD_TYPE release)","set(VCPKG_OSX_DEPLOYMENT_TARGET 10.15)"
# NOTE: Avoids a libtorrent ABI issue. See https://github.com/arvidn/libtorrent/issues/4965
- name: force AppleClang to compile libtorrent with the same C++ standard as qBittorrent
run: |
(Get-Content -path ${{ env.RUNVCPKG_VCPKG_ROOT }}/ports/libtorrent/portfile.cmake).Replace( `
'${FEATURE_OPTIONS}', '${FEATURE_OPTIONS} -DCMAKE_CXX_STANDARD=17') `
| Set-Content -Path ${{ env.RUNVCPKG_VCPKG_ROOT }}/ports/libtorrent/portfile.cmake
- name: install dependencies via vcpkg
run: |
$packages = `
Expand All @@ -211,13 +217,11 @@ jobs:
"qt5-macextras:x64-osx-release"
${{ env.RUNVCPKG_VCPKG_ROOT }}/vcpkg upgrade `
--overlay-triplets=${{ github.workspace }}/triplets_overlay `
--overlay-ports=${{ github.workspace }}/vcpkg `
--no-dry-run
foreach($package in $packages)
{
${{ env.RUNVCPKG_VCPKG_ROOT }}/vcpkg install $package `
--overlay-triplets=${{ github.workspace }}/triplets_overlay `
--overlay-ports=${{ github.workspace }}/vcpkg `
--clean-after-build
}
Expand Down
26 changes: 0 additions & 26 deletions vcpkg/libtorrent/CONTROL

This file was deleted.

31 changes: 0 additions & 31 deletions vcpkg/libtorrent/no_use_iconv.patch

This file was deleted.

66 changes: 0 additions & 66 deletions vcpkg/libtorrent/portfile.cmake

This file was deleted.

2 changes: 0 additions & 2 deletions vcpkg/libtorrent/readme.md

This file was deleted.

0 comments on commit 211c92c

Please sign in to comment.