|
| 1 | +# This workflow will build a "Eclipse Platform Individual Bundles" using the eclipse.platform repository as it contains the largest set of inter-related bundles |
| 2 | +# For more information see: https://github.com/eclipse-platform/eclipse.platform |
| 3 | + |
| 4 | +name: Verify Eclipse Platform SWT Build |
| 5 | +concurrency: |
| 6 | + group: ${{ github.workflow }}-${{ github.ref }} |
| 7 | + cancel-in-progress: true |
| 8 | +on: |
| 9 | + pull_request: |
| 10 | + branches: |
| 11 | + - 'main' |
| 12 | + |
| 13 | +jobs: |
| 14 | + build-swt: |
| 15 | + runs-on: ${{ matrix.config.os }} |
| 16 | + strategy: |
| 17 | + fail-fast: false |
| 18 | + matrix: |
| 19 | + config: |
| 20 | + - { name: Linux, os: ubuntu-latest, native: gtk.linux.x86_64 } |
| 21 | + - { name: Windows, os: windows-latest, native: win32.win32.x86_64 } |
| 22 | + - { name: MacOS x86, os: macos-13, native: cocoa.macosx.x86_64 } |
| 23 | + - { name: MacOS ARM, os: macos-latest, native: cocoa.macosx.aarch64 } |
| 24 | + name: Verify ${{ matrix.config.name }} |
| 25 | + steps: |
| 26 | + - name: Checkout tycho code |
| 27 | + uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 |
| 28 | + with: |
| 29 | + path: 'tycho' |
| 30 | + - name: Checkout platform code |
| 31 | + uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 |
| 32 | + with: |
| 33 | + path: 'swt' |
| 34 | + submodules: 'recursive' |
| 35 | + lfs: true |
| 36 | + repository: 'eclipse-platform/eclipse.platform.swt' |
| 37 | + fetch-depth: 0 |
| 38 | + - name: Set up Java |
| 39 | + uses: actions/setup-java@2dfa2011c5b2a0f1489bf9e433881c92c1631f88 # v4.3.0 |
| 40 | + with: |
| 41 | + java-version: | |
| 42 | + 11 |
| 43 | + 21 |
| 44 | + 17 |
| 45 | + distribution: 'temurin' |
| 46 | + - name: Cache local Maven repository |
| 47 | + uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2 |
| 48 | + with: |
| 49 | + path: ~/.m2/repository |
| 50 | + key: ${{ runner.os }}-maven-verify-platform-swt-${{ hashFiles('**/pom.xml', '**/*.target') }} |
| 51 | + restore-keys: | |
| 52 | + ${{ runner.os }}-maven-verify-platform-swt- |
| 53 | + - name: Set up Maven |
| 54 | + uses: stCarolas/setup-maven@d6af6abeda15e98926a57b5aa970a96bb37f97d1 # v5 |
| 55 | + with: |
| 56 | + maven-version: 3.9.9 |
| 57 | + - name: Build Tycho |
| 58 | + working-directory: 'tycho' |
| 59 | + run: >- |
| 60 | + mvn -U -V -e -B -ntp |
| 61 | + -DskipTests |
| 62 | + --file pom.xml |
| 63 | + -T1C |
| 64 | + clean install |
| 65 | + - name: Run Platform SWT Build |
| 66 | + working-directory: 'swt' |
| 67 | + shell: bash |
| 68 | + run: >- |
| 69 | + mvn |
| 70 | + -ntp |
| 71 | + --batch-mode |
| 72 | + -Pbuild-individual-bundles |
| 73 | + -Pbree-libs |
| 74 | + -DskipTests |
| 75 | + -Dtycho.version=$(mvn help:evaluate -f ../tycho -Dexpression=project.version -q -DforceStdout) |
| 76 | + -T1C |
| 77 | + clean verify |
0 commit comments