summaryrefslogtreecommitdiff
path: root/.github/workflows/windows.yml
blob: 79f711f87ff74dfa251de821f9f68ecc9b1b3083 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
name: windows

on:
  push:
  pull_request:
  schedule:
    - cron: '0 1 * * SUN'

jobs:
  build:
    strategy:
      matrix:
        include:
          - name: VS2017Debug64
            vmimage: windows-2016
            mpctype: vs2017
            BuildPlatform: x64
            BuildConfiguration: Debug
            vcpkgarch: x64-windows
            vcpkglibdir: debug/lib
            vcpkgpackages: openssl xerces-c
          - name: VS2019Debug64
            vmimage: windows-2019
            mpctype: vs2019
            BuildPlatform: x64
            BuildConfiguration: Debug
            vcpkgarch: x64-windows
            vcpkglibdir: debug/lib
            vcpkgpackages: openssl xerces-c
          - name: VS2019Release32
            vmimage: windows-2019
            mpctype: vs2019
            BuildPlatform: Win32
            BuildConfiguration: Release
            vcpkgarch: x86-windows
            vcpkglibdir: lib
            vcpkgpackages: openssl xerces-c
    runs-on: ${{ matrix.vmimage }}
    name: ${{ matrix.name }}
    env:
      DOC_ROOT: ${{ github.workspace }}/ACE_TAO
      ACE_ROOT: ${{ github.workspace }}/ACE_TAO/ACE
      TAO_ROOT: ${{ github.workspace }}/ACE_TAO/TAO
      MPC_ROOT: ${{ github.workspace }}/
      CIAO_ROOT: ${{ github.workspace }}/CIAO
      DANCE_ROOT: ${{ github.workspace }}/DAnCE
      VCPKG_ROOT: ${{ github.workspace }}/vcpkg
      XERCESC_INCDIR: ${{ github.workspace }}/vcpkg/installed/${{ matrix.vcpkgarch }}/include
      XERCESC_LIBDIR: ${{ github.workspace }}/vcpkg/installed/${{ matrix.vcpkgarch }}/${{ matrix.vcpkglibdir }}
      SSL_INCDIR: ${{ github.workspace }}/vcpkg/installed/${{ matrix.vcpkgarch }}/include
      SSL_LIBDIR: ${{ github.workspace }}/vcpkg/installed/${{ matrix.vcpkgarch }}/${{ matrix.vcpkglibdir }}
    steps:
    - name: checkout MPC
      uses: actions/checkout@v2
    - name: checkout ACE_TAO
      uses: actions/checkout@v2
      with:
        repository: DOCGroup/ACE_TAO
        path: ${{ env.DOC_ROOT }}
    - name: checkout CIAO
      uses: actions/checkout@v2
      with:
        repository: DOCGroup/CIAO
        path: ${{ env.CIAO_ROOT }}
    - name: checkout DAnCE
      uses: actions/checkout@v2
      with:
        repository: DOCGroup/DAnCE
        path: ${{ env.DANCE_ROOT }}
    - name: Install vcpkg
      uses: lukka/run-vcpkg@v4
      with:
        vcpkgGitCommitId: 56fffbe49dfb4dd8fae0940f272c5fd2b86be991
        vcpkgArguments: --recurse ${{ matrix.vcpkgpackages }}
        vcpkgTriplet: ${{ matrix.vcpkgarch }}
        appendedCacheKey: ${{ matrix.name }}
    - name: create $ACE_ROOT/ace/config.h
      run: |
        '#include "ace/config-win32.h"' > ${env:ACE_ROOT}/ace/config.h
      shell: pwsh
    - name: create $ACE_ROOT/bin/MakeProjectCreator/config/default.features
      run: |
        echo "ipv6=1" | out-file -encoding ASCII ${env:ACE_ROOT}/bin/MakeProjectCreator/config/default.features
        echo "xerces3=1" | out-file -encoding ASCII ${env:ACE_ROOT}/bin/MakeProjectCreator/config/default.features
        echo "ssl=1" | out-file -append -encoding ASCII ${env:ACE_ROOT}/bin/MakeProjectCreator/config/default.features
        echo "openssl11=1" | out-file -append -encoding ASCII ${env:ACE_ROOT}/bin/MakeProjectCreator/config/default.features
        echo "versioned_namespace=1" | out-file -append -encoding ASCII ${env:ACE_ROOT}/bin/MakeProjectCreator/config/default.features
      shell: pwsh
    - name: Add optional features ${{ matrix.OptionalFeatures }}
      run: |
        echo "${{ matrix.OptionalFeatures }}" | out-file -append -encoding ASCII ${env:ACE_ROOT}/bin/MakeProjectCreator/config/default.features
      shell: pwsh
      if: matrix.OptionalFeatures != ''
    - name: Run mwc.pl on $(CIAO_ROOT)/CIAO_TAO_DAnCE.mwc
      run: |
        perl ${env:ACE_ROOT}/bin/mwc.pl -type ${{ matrix.mpctype }} ${env:CIAO_ROOT}/CIAO_TAO_DAnCE.mwc -workers 4
      shell: pwsh
    - name: Setup msbuild
      uses: microsoft/setup-msbuild@v1
    - name: Build solution $(CIAO_ROOT)/CIAO_TAO_DAnCE.sln
      run: |
        msbuild -maxcpucount -p:Platform=${{ matrix.BuildPlatform }} -p:Configuration=${{ matrix.BuildConfiguration }} ${env:CIAO_ROOT}/CIAO_TAO_DAnCE.sln
      shell: pwsh