Skip to content

Commit

Permalink
Merge pull request #1 from BOINC/master
Browse files Browse the repository at this point in the history
Merging changes from upstream
  • Loading branch information
mikaey authored Mar 4, 2021
2 parents c19add3 + aac02d1 commit 8b151db
Show file tree
Hide file tree
Showing 130 changed files with 3,483 additions and 1,157 deletions.
54 changes: 54 additions & 0 deletions .github/workflows/android.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: Android
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
schedule:
- cron: '5 12 * * 0'

jobs:
build:
name: ${{ matrix.type }}-build
runs-on: ubuntu-latest
strategy:
matrix:
type: [manager]
fail-fast: false
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 2

- name: Set up JDK 1.9
uses: actions/setup-java@v1
with:
java-version: 1.9

- name: Setup Android SDK
uses: android-actions/setup-android@v2

- name: Cache dependencies
uses: actions/[email protected]
with:
path: 3rdParty/buildCache
key: android-${{ matrix.type }}-${{ hashFiles('android/*.sh') }}
restore-keys: android-${{ matrix.type }}-

- name: Build
run: |
./android/ci_build_all.sh
bash <(curl -s https://codecov.io/bash)
- name: Deploy to BinTray
if: ${{ success() }}
env:
BINTRAY_API_KEY: ${{ secrets.BINTRAY_API_KEY }}
PULL_REQUEST: ${{ github.event.number }}
PULL_REQUEST_SHA: ${{ github.event.pull_request.head.sha }}
run: ./deploy/prepare_deployment.sh android_${{ matrix.type }} && ./deploy/deploy_to_bintray.sh deploy/android_${{ matrix.type }}/

- uses: actions/upload-artifact@v2
with:
name: android_${{ matrix.type }}_${{ github.event.pull_request.head.sha }}
path: deploy/android_${{ matrix.type }}/*.7z
99 changes: 99 additions & 0 deletions .github/workflows/linux.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,99 @@
name: Linux
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
schedule:
- cron: '10 12 * * 0'

jobs:
build:
name: ${{ matrix.type }}-build
runs-on: ubuntu-latest
strategy:
matrix:
type: [libs, server, client, apps, manager-with-webview, manager-without-webview, unit-test, integration-test]
fail-fast: false
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 2

- name: Install dependencies
run: |
sudo add-apt-repository 'deb http://archive.ubuntu.com/ubuntu bionic main universe'
sudo apt-get -qq update
sudo apt-get install -y freeglut3-dev libcurl4-openssl-dev libxmu-dev libxi-dev libfcgi-dev libxss-dev libnotify-dev libxcb-util0-dev libgtk2.0-dev libwebkitgtk-dev p7zip-full libxxf86vm-dev
- name: Install dependencies for integration testing
if: matrix.type == 'integration-test'
run: |
sudo apt-get install ansible
sudo service mysql stop
./integration_test/installTestSuite.sh
- name: Cache dependencies
uses: actions/[email protected]
with:
path: 3rdParty/buildCache
key: linux-${{ matrix.type }}-${{ hashFiles('3rdParty/*Linux*.sh') }}
restore-keys: linux-${{ matrix.type }}-

- name: Automake
if: ${{ success() }}
run: ./_autosetup

- name: Configure libs
if: ${{ success() && matrix.type == 'libs' }}
run: ./configure --disable-server --disable-client --disable-manager

- name: Configure server
if: ${{ success() && matrix.type == 'server' }}
run: ./configure --enable-server --disable-client --disable-manager

- name: Configure client
if: ${{ success() && matrix.type == 'client' }}
run: ./configure --disable-server --enable-client --disable-manager

- name: Configure apps
if: success() && matrix.type == 'apps'
run: ./configure --enable-apps --disable-server --disable-client --disable-manager

- name: Configure manager with webview
if: success() && matrix.type == 'manager-with-webview'
run: ./3rdParty/buildLinuxDependencies.sh && ./configure --disable-server --disable-client --with-wx-prefix=${GITHUB_WORKSPACE}/3rdParty/buildCache/linux

- name: Configure manager without webview
if: success() && matrix.type == 'manager-without-webview'
run: ./3rdParty/buildLinuxDependencies.sh --disable-webview && ./configure --disable-server --disable-client --with-wx-prefix=${GITHUB_WORKSPACE}/3rdParty/buildCache/linux

- name: Configure server for unit testing
if: success() && matrix.type == 'unit-test'
run: ./3rdParty/buildLinuxDependencies.sh --gtest-only && ./configure --disable-client --disable-manager --enable-unit-tests CFLAGS="-g -O0" CXXFLAGS="-g -O0"

- name: Make
if: success() && ! contains(matrix.type, 'integration-test')
run: make

- name: Execute unit-test and report coverage
if: success() && matrix.type == 'unit-test'
run: ./tests/executeUnitTests.sh --report-coverage

- name: Execute integration-test
if: success() && matrix.type == 'integration-test'
run: ./integration_test/executeTestSuite.sh

- name: Deploy to BinTray
if: ${{ success() && ! contains(matrix.type, 'libs') && ! contains(matrix.type, 'server') && ! contains(matrix.type, 'test') }}
env:
BINTRAY_API_KEY: ${{ secrets.BINTRAY_API_KEY }}
PULL_REQUEST: ${{ github.event.number }}
PULL_REQUEST_SHA: ${{ github.event.pull_request.head.sha }}
run: ./deploy/prepare_deployment.sh linux_${{ matrix.type }} && ./deploy/deploy_to_bintray.sh deploy/linux_${{ matrix.type }}/

- uses: actions/upload-artifact@v2
if: ${{ ! contains(matrix.type, 'libs') && ! contains(matrix.type, 'server') && ! contains(matrix.type, 'test') }}
with:
name: linux_${{ matrix.type }}_${{ github.event.pull_request.head.sha }}
path: deploy/linux_${{ matrix.type }}/*.7z
46 changes: 46 additions & 0 deletions .github/workflows/mingw.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Linux-MinGW
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
schedule:
- cron: '0 12 * * 0'

jobs:
build:
name: ${{ matrix.type }}-build
runs-on: ubuntu-latest
strategy:
matrix:
type: [libs-mingw, apps-mingw]
fail-fast: false
steps:
- uses: actions/checkout@v2

- name: Install dependencies
run: |
sudo apt-get -qq update
sudo apt-get install -y mingw-w64 binutils-mingw-w64-i686 binutils-mingw-w64-x86-64 gcc-mingw-w64 gcc-mingw-w64-i686 gcc-mingw-w64-x86-64 g++-mingw-w64 g++-mingw-w64-i686 g++-mingw-w64-x86-64 p7zip-full
- name: Make libs with mingw
if: success() && matrix.type == 'libs-mingw'
run: cd lib && MINGW=x86_64-w64-mingw32 make -f Makefile.mingw

- name: Make apps with mingw
if: success() && matrix.type == 'apps-mingw'
run: cd lib && MINGW=x86_64-w64-mingw32 make -f Makefile.mingw wrapper

- name: Deploy to BinTray
if: ${{ success() && ! contains(matrix.type, 'libs-mingw') }}
env:
BINTRAY_API_KEY: ${{ secrets.BINTRAY_API_KEY }}
PULL_REQUEST: ${{ github.event.number }}
PULL_REQUEST_SHA: ${{ github.event.pull_request.head.sha }}
run: ./deploy/prepare_deployment.sh win_${{ matrix.type }} && ./deploy/deploy_to_bintray.sh deploy/win_${{ matrix.type }}/

- uses: actions/upload-artifact@v2
if: ${{ ! contains(matrix.type, 'libs') }}
with:
name: win_${{ matrix.type }}_${{ github.event.pull_request.head.sha }}
path: deploy/win_${{ matrix.type }}/*.7z
41 changes: 41 additions & 0 deletions .github/workflows/osx.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: OSX
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
schedule:
- cron: '20 12 * * 0'

jobs:
build:
name: ${{ matrix.type }}-build
runs-on: macos-latest
strategy:
matrix:
type: [manager]
fail-fast: false
steps:
- uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: '12.2'
- uses: actions/checkout@v2

- name: Cache dependencies
uses: actions/[email protected]
with:
path: 3rdParty/buildCache
key: osx-${{ matrix.type }}-${{ hashFiles('3rdParty/*Mac*.sh', 'mac_build/dependencyNames.sh', 'mac_build/[bB]uild*.sh') }}
restore-keys: osx-${{ matrix.type }}-

- name: install dependencies
run: ./3rdParty/buildMacDependencies.sh -q

- name: make
if: success()
run: ./mac_build/buildMacBOINC-CI.sh --no_shared_headers

- name: deploy
if: ${{ success() }}
run: echo "Would start deployment now"
#run: ./deploy/prepare_deployment.sh osx_${BOINC_TYPE} deploy/osx_${BOINC_TYPE}/ && ./deploy/deploy_to_bintray.sh deploy/osx_${BOINC_TYPE}/
87 changes: 87 additions & 0 deletions .github/workflows/windows.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
name: Windows
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
schedule:
- cron: '15 12 * * 0'

jobs:
build:
name: ${{ matrix.configuration }}-${{ matrix.platform }}-build
runs-on: windows-latest
strategy:
matrix:
platform: [x64]
configuration: [Release]
env:
VCPKG_BINARY_SOURCES: 'clear;files,${{ github.workspace }}\3rdParty\buildCache\windows\vcpkgcache\,readwrite'
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
with:
fetch-depth: 2

- name: Download GoogleTestAdapter
uses: suisei-cn/actions-download-file@v1
id: DownloadGoogleTestAdapter
with:
url: "https://github.com/csoltenborn/GoogleTestAdapter/releases/download/v0.18.0/GoogleTestAdapter-0.18.0.vsix"
target: ${{ github.workspace }}\temp\

- name: Unzip GoogleTestAdapter
uses: DuckSoft/[email protected]
with:
pathSource: ${{ github.workspace }}\temp\GoogleTestAdapter-0.18.0.vsix
pathTarget: ${{ github.workspace }}\temp\GoogleTestAdapter

- name: Setup msbuild
uses: microsoft/setup-msbuild@v1

- name: Setup vstest
uses: darenm/Setup-VSTest@v1

- name: Fix vcpkg
run: vcpkg.exe integrate remove

- name: Cache dependencies
uses: actions/[email protected]
with:
path: |
${{ github.workspace }}\3rdParty\buildCache\windows\vcpkgcache\
${{ github.workspace }}\3rdParty\Windows\cuda\
key: windows-${{ matrix.platform }}-${{ matrix.configuration }}-${{ hashFiles('win_build/vcpkg_3rdparty_dependencies_vs2019.vcxproj') }}
restore-keys: windows-${{ matrix.platform }}-${{ matrix.configuration }}-

- name: Build
run: msbuild win_build\boinc_vs2019.sln -p:Configuration=${{ matrix.configuration }} -p:Platform=${{ matrix.platform }} -p:VcpkgTripletConfig=ci -m

- name: Run tests
run: vstest.console.exe win_build\Build\${{ matrix.platform }}\${{ matrix.configuration }}\unittests.exe /TestAdapterPath:${{ github.workspace }}\temp\GoogleTestAdapter

- name: Deploy to BinTray
if: ${{ success() }}
env:
BINTRAY_API_KEY: ${{ secrets.BINTRAY_API_KEY }}
PULL_REQUEST: ${{ github.event.number }}
PULL_REQUEST_SHA: ${{ github.event.pull_request.head.sha }}
platform: ${{ matrix.platform }}
configuration: ${{ matrix.configuration }}
shell: cmd
run: |
call deploy\prepare_deployment.bat
call deploy\deploy_to_bintray.bat
- uses: actions/upload-artifact@v2
with:
name: win_apps_${{ github.event.pull_request.head.sha }}
path: deploy/win_apps/*.7z
- uses: actions/upload-artifact@v2
with:
name: win_client_${{ github.event.pull_request.head.sha }}
path: deploy/win_client/*.7z
- uses: actions/upload-artifact@v2
with:
name: win_manager_${{ github.event.pull_request.head.sha }}
path: deploy/win_manager/*.7z
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,9 @@
/html/nbproject/
*.project

# CLion files
.idea

#
*.pfx
*.pvk
Expand Down
Loading

0 comments on commit 8b151db

Please sign in to comment.