|
1 | | -name: Build all Platforms |
2 | | - |
3 | | -on: |
4 | | - push: |
5 | | - pull_request: |
6 | | - branches: [ master ] |
7 | | - workflow_dispatch: # Can also be called manually for whatever reason |
8 | | - |
9 | | -# Let's set all project specific definitions globally |
10 | | -env: |
11 | | - PRJ_NAME: LiveTraffic # The plugin's name, expected to be the .xpl file's name and used as the plugin folder name |
12 | | - |
13 | | -jobs: |
14 | | - ##################################### |
15 | | - # Linux with GCC |
16 | | - build-lin: |
17 | | - runs-on: ubuntu-20.04 |
18 | | - env: |
19 | | - platform: lin |
20 | | - steps: |
21 | | - - name: Checkout Code |
22 | | - uses: actions/checkout@v3 # must checkout before we can use our own actions |
23 | | - with: |
24 | | - submodules: 'recursive' |
25 | | - - name: Build |
26 | | - uses: ./.github/actions/build-lin |
27 | | - id: build |
28 | | - with: |
29 | | - pluginName: ${{ env.PRJ_NAME }} |
30 | | - - name: Upload Artifact |
31 | | - uses: ./.github/actions/upload-plugin |
32 | | - with: |
33 | | - pluginName: ${{ env.PRJ_NAME }} |
34 | | - archFolder: lin_x64 |
35 | | - xplFileName: "${{ steps.build.outputs.xpl-file-name }}" |
36 | | - |
37 | | - ##################################### |
38 | | - # MacOS with CMake/clang and sign/notarize in self-written script |
39 | | - build-mac: |
40 | | - runs-on: macos-11 |
41 | | - steps: |
42 | | - - name: Checkout Code |
43 | | - uses: actions/checkout@v3 # must checkout before we can use our own actions |
44 | | - with: |
45 | | - submodules: 'recursive' |
46 | | - - name: Build |
47 | | - uses: ./.github/actions/build-mac |
48 | | - id: build |
49 | | - with: |
50 | | - pluginName: ${{ env.PRJ_NAME }} |
51 | | - - name: Check if Secrets available |
52 | | - id: checksecrets |
53 | | - env: |
54 | | - MACOS_CERTIFICATE: ${{ secrets.MACOS_CERTIFICATE }} |
55 | | - shell: bash |
56 | | - run: | |
57 | | - if [ "$MACOS_CERTIFICATE" == "" ]; then |
58 | | - echo "secretspresent=" >> $GITHUB_OUTPUT |
59 | | - else |
60 | | - echo "secretspresent=true" >> $GITHUB_OUTPUT |
61 | | - fi |
62 | | - - name: Codesign and Notarization |
63 | | - if: ${{ steps.checksecrets.outputs.secretspresent }} |
64 | | - uses: ./.github/actions/sign-notarize |
65 | | - with: |
66 | | - xplFileName: ${{ steps.build.outputs.xpl-file-name }} |
67 | | - certificate: ${{ secrets.MACOS_CERTIFICATE }} |
68 | | - certPwd: ${{ secrets.MACOS_CERT_PWD }} |
69 | | - notarizeUser: ${{ secrets.NOTARIZATION_USERNAME }} |
70 | | - notarizeTeam: ${{ secrets.NOTARIZATION_TEAM }} |
71 | | - notarizeAppPwd: ${{ secrets.NOTARIZATION_PASSWORD }} |
72 | | - - name: Upload Artifact |
73 | | - uses: ./.github/actions/upload-plugin |
74 | | - with: |
75 | | - pluginName: ${{ env.PRJ_NAME }} |
76 | | - archFolder: mac_x64 |
77 | | - xplFileName: ${{ steps.build.outputs.xpl-file-name }} |
78 | | - |
79 | | - ##################################### |
80 | | - # Windows with MS Visual Studio |
81 | | - build-win: |
82 | | - runs-on: windows-2022 |
83 | | - env: |
84 | | - platform: win |
85 | | - steps: |
86 | | - - name: Checkout Code |
87 | | - uses: actions/checkout@v3 # must checkout before we can use our own actions |
88 | | - with: |
89 | | - submodules: 'recursive' |
90 | | - - name: Build |
91 | | - uses: ./.github/actions/build-win |
92 | | - id: build |
93 | | - with: |
94 | | - pluginName: ${{ env.PRJ_NAME }} |
95 | | - - name: Upload Artifact |
96 | | - uses: ./.github/actions/upload-plugin |
97 | | - with: |
98 | | - pluginName: ${{ env.PRJ_NAME }} |
99 | | - archFolder: win_x64 |
100 | | - xplFileName: "${{ steps.build.outputs.xpl-file-name }}" |
101 | | - pdbFileName: "${{ steps.build.outputs.pdb-file-name }}" |
| 1 | +name: Build all Platforms |
| 2 | + |
| 3 | +on: |
| 4 | + push: |
| 5 | + pull_request: |
| 6 | + branches: [ master ] |
| 7 | + workflow_dispatch: # Can also be called manually for whatever reason |
| 8 | + |
| 9 | +# Let's set all project specific definitions globally |
| 10 | +env: |
| 11 | + PRJ_NAME: LiveTraffic # The plugin's name, expected to be the .xpl file's name and used as the plugin folder name |
| 12 | + version_beta: ${{ github.ref != 'refs/heads/master' && '1' || '0' }} # On non-master branches we build BETA versions |
| 13 | + |
| 14 | +jobs: |
| 15 | + ##################################### |
| 16 | + # Linux with GCC |
| 17 | + build-lin: |
| 18 | + runs-on: ubuntu-20.04 |
| 19 | + env: |
| 20 | + platform: lin |
| 21 | + steps: |
| 22 | + - name: Checkout Code |
| 23 | + uses: actions/checkout@v4 # must checkout before we can use our own actions |
| 24 | + with: |
| 25 | + submodules: 'recursive' |
| 26 | + - name: Build |
| 27 | + uses: ./.github/actions/build-lin |
| 28 | + id: build |
| 29 | + with: |
| 30 | + pluginName: ${{ env.PRJ_NAME }} |
| 31 | + - name: Upload Artifact |
| 32 | + uses: ./.github/actions/upload-plugin |
| 33 | + with: |
| 34 | + pluginName: ${{ env.PRJ_NAME }} |
| 35 | + archFolder: lin_x64 |
| 36 | + xplFileName: "${{ steps.build.outputs.xpl-file-name }}" |
| 37 | + |
| 38 | + ##################################### |
| 39 | + # MacOS with CMake/clang and sign/notarize in self-written script |
| 40 | + build-mac: |
| 41 | + runs-on: macos-12 |
| 42 | + env: |
| 43 | + platform: mac |
| 44 | + steps: |
| 45 | + - name: Checkout Code |
| 46 | + uses: actions/checkout@v4 # must checkout before we can use our own actions |
| 47 | + with: |
| 48 | + submodules: 'recursive' |
| 49 | + - name: Build |
| 50 | + uses: ./.github/actions/build-mac |
| 51 | + id: build |
| 52 | + with: |
| 53 | + pluginName: ${{ env.PRJ_NAME }} |
| 54 | + - name: Check if Secrets available |
| 55 | + id: checksecrets |
| 56 | + env: |
| 57 | + MACOS_CERTIFICATE: ${{ secrets.MACOS_CERTIFICATE }} |
| 58 | + shell: bash |
| 59 | + run: | |
| 60 | + if [ "$MACOS_CERTIFICATE" == "" ]; then |
| 61 | + echo "secretspresent=" >> $GITHUB_OUTPUT |
| 62 | + else |
| 63 | + echo "secretspresent=true" >> $GITHUB_OUTPUT |
| 64 | + fi |
| 65 | + - name: Codesign and Notarization |
| 66 | + if: ${{ steps.checksecrets.outputs.secretspresent }} |
| 67 | + uses: ./.github/actions/sign-notarize |
| 68 | + with: |
| 69 | + xplFileName: ${{ steps.build.outputs.xpl-file-name }} |
| 70 | + certificate: ${{ secrets.MACOS_CERTIFICATE }} |
| 71 | + certPwd: ${{ secrets.MACOS_CERT_PWD }} |
| 72 | + notarizeUser: ${{ secrets.NOTARIZATION_USERNAME }} |
| 73 | + notarizeTeam: ${{ secrets.NOTARIZATION_TEAM }} |
| 74 | + notarizeAppPwd: ${{ secrets.NOTARIZATION_PASSWORD }} |
| 75 | + - name: Upload Artifact |
| 76 | + uses: ./.github/actions/upload-plugin |
| 77 | + with: |
| 78 | + pluginName: ${{ env.PRJ_NAME }} |
| 79 | + archFolder: mac_x64 |
| 80 | + xplFileName: ${{ steps.build.outputs.xpl-file-name }} |
| 81 | + |
| 82 | + ##################################### |
| 83 | + # Windows with MS Visual Studio |
| 84 | + build-win: |
| 85 | + runs-on: windows-2022 |
| 86 | + env: |
| 87 | + platform: win |
| 88 | + steps: |
| 89 | + - name: Checkout Code |
| 90 | + uses: actions/checkout@v4 # must checkout before we can use our own actions |
| 91 | + with: |
| 92 | + submodules: 'recursive' |
| 93 | + - name: Build |
| 94 | + uses: ./.github/actions/build-win |
| 95 | + id: build |
| 96 | + with: |
| 97 | + pluginName: ${{ env.PRJ_NAME }} |
| 98 | + - name: Upload Artifact |
| 99 | + uses: ./.github/actions/upload-plugin |
| 100 | + with: |
| 101 | + pluginName: ${{ env.PRJ_NAME }} |
| 102 | + archFolder: win_x64 |
| 103 | + xplFileName: "${{ steps.build.outputs.xpl-file-name }}" |
| 104 | + pdbFileName: "${{ steps.build.outputs.pdb-file-name }}" |
0 commit comments