Feature change
[ACE_TAO.git] / .github / workflows / linux.yml
blob09be9ee9cf106c63156bc3d70591c0b4cad78ce5
1 name: linux
3 on:
4   push:
5   pull_request:
6   schedule:
7     - cron: '0 7 * * SUN'
9 jobs:
10   build:
11     strategy:
12       matrix:
13         include:
14           - CC: gcc-4.8
15             CXX: g++-4.8
16             PackageDeps: g++-4.8
17             platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux.GNU
18             os: ubuntu-16.04
19           - CC: gcc-6
20             CXX: g++-6
21             PackageDeps: g++-6
22             platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux.GNU
23             os: ubuntu-18.04
24           - CC: gcc-7
25             CXX: g++-7
26             PackageDeps: g++-7
27             platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux.GNU
28             os: ubuntu-18.04
29           - CC: gcc-8
30             CXX: g++-8
31             PackageDeps: g++-8
32             platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux.GNU
33             os: ubuntu-18.04
34           - CC: gcc-9
35             CXX: g++-9
36             PackageDeps: g++-9
37             platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux.GNU
38             os: ubuntu-18.04
39           - CC: gcc-10
40             CXX: g++-10
41             PackageDeps: g++-10
42             platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux.GNU
43             os: ubuntu-20.04
44           - CC: clang-5.0
45             CXX: clang++-5.0
46             PackageDeps: clang-5.0
47             platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux_clang.GNU
48             os: ubuntu-16.04
49           - CC: clang-6.0
50             CXX: clang++-6.0
51             PackageDeps: clang-6.0
52             platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux_clang.GNU
53             os: ubuntu-18.04
54           - CC: clang-7
55             CXX: clang++-7
56             PackageDeps: clang-7
57             platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux_clang.GNU
58             os: ubuntu-18.04
59           - CC: clang-8
60             CXX: clang++-8
61             PackageDeps: clang-8
62             platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux_clang.GNU
63             os: ubuntu-18.04
64           - CC: clang-9
65             CXX: clang++-9
66             PackageDeps: clang-9
67             Repo: llvm-toolchain-$(lsb_release -cs)-9
68             platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux_clang.GNU
69             os: ubuntu-18.04
70           - CC: clang-10
71             CXX: clang++-10
72             PackageDeps: clang-10
73             Repo: llvm-toolchain-$(lsb_release -cs)-10
74             platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux_clang.GNU
75             os: ubuntu-20.04
76           - feature: CORBAe micro
77             CC: gcc-10
78             CXX: g++-10
79             PackageDeps: g++-10
80             platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux.GNU
81             os: ubuntu-20.04
82             optional_feature: corba_e_micro=1
83             optional_macros: corba_e_micro=1
84           - feature: CORBAe compact
85             CC: gcc-10
86             CXX: g++-10
87             PackageDeps: g++-10
88             platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux.GNU
89             os: ubuntu-20.04
90             optional_feature: corba_e_compact=1
91             optional_macros: corba_e_compact=1
92           - feature: ACE for TAO
93             CC: gcc-10
94             CXX: g++-10
95             PackageDeps: g++-10
96             platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux.GNU
97             os: ubuntu-20.04
98             optional_feature: ace_for_tao=1
99             optional_macros: ace_for_tao=1
100           - feature: wchar
101             CC: gcc-10
102             CXX: g++-10
103             PackageDeps: g++-10
104             platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux.GNU
105             os: ubuntu-20.04
106             optional_feature: uses_wchar=1
107     runs-on: ${{ matrix.os }}
108     name: ${{ matrix.os }} ${{ matrix.CXX }} ${{ matrix.feature }}
109     env:
110       ACE_ROOT: ${{ github.workspace }}/ACE
111       TAO_ROOT: ${{ github.workspace }}/TAO
112       MPC_ROOT: ${{ github.workspace }}/MPC
113       CC: ${{ matrix.CC }}
114       CXX: ${{ matrix.CXX }}
115     steps:
116     - name: checkout ACE/TAO
117       uses: actions/checkout@v2
118     - name: checkout MPC
119       uses: actions/checkout@v2
120       with:
121         repository: DOCGroup/MPC
122         path: MPC
123     - name: Add Repo
124       run: |
125         wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key|sudo apt-key add -
126         sudo apt-add-repository "deb http://apt.llvm.org/$(lsb_release -cs)/ ${{ matrix.Repo }} main"
127       if: matrix.Repo != ''
128     - name: Add packages
129       run: |
130         sudo apt-get --yes update
131         sudo apt-get --yes install libxerces-c-dev libssl-dev ${{ matrix.PackageDeps }}
132     - name: create $ACE_ROOT/ace/config.h
133       run: |
134         '#include "ace/config-linux.h"' > ${env:ACE_ROOT}/ace/config.h
135       shell: pwsh
136     - name: create $ACE_ROOT/include/makeinclude/platform_macros.GNU
137       run: |
138         '${{ matrix.platform_file }}' >  ${env:ACE_ROOT}/include/makeinclude/platform_macros.GNU
139       shell: pwsh
140     - name: extend $ACE_ROOT/include/makeinclude/platform_macros.GNU
141       run: |
142         'ipv6=1' >> ${env:ACE_ROOT}/include/makeinclude/platform_macros.GNU
143         'xerces3=1' >> ${env:ACE_ROOT}/include/makeinclude/platform_macros.GNU
144         'ssl=1' >> ${env:ACE_ROOT}/include/makeinclude/platform_macros.GNU
145       shell: pwsh
146     - name: add optional optional macros
147       run: |
148         '${{ matrix.optional_macros }}' >> ${env:ACE_ROOT}/include/makeinclude/platform_macros.GNU
149       shell: pwsh
150       if: matrix.optional_macros != ''
151     - name: create $ACE_ROOT/bin/MakeProjectCreator/config/default.features
152       run: |
153         'ipv6=1' > ${env:ACE_ROOT}/bin/MakeProjectCreator/config/default.features
154         'xerces3=1' >> ${env:ACE_ROOT}/bin/MakeProjectCreator/config/default.features
155         'ssl=1' >> ${env:ACE_ROOT}/bin/MakeProjectCreator/config/default.features
156         'versioned_namespace=1' >> ${env:ACE_ROOT}/bin/MakeProjectCreator/config/default.features
157       shell: pwsh
158     - name: add optional optional feature
159       run: |
160         '${{ matrix.optional_feature }}' >> ${env:ACE_ROOT}/bin/MakeProjectCreator/config/default.features
161       if: matrix.optional_feature != ''
162     - name: Run mwc.pl on $(TAO_ROOT)/TAO_ACE.mwc
163       run: |
164         perl ${env:ACE_ROOT}/bin/mwc.pl -type gnuace ${env:TAO_ROOT}/TAO_ACE.mwc -workers 4
165       shell: pwsh
166     - name: Run mwc.pl on $(ACE_ROOT)/tests/tests.mwc
167       run: |
168         perl ${env:ACE_ROOT}/bin/mwc.pl -type gnuace ${env:ACE_ROOT}/tests/tests.mwc -workers 4
169       shell: pwsh
170     - name: Build TAO_ACE project
171       run: |
172         make -j 6 -C ${env:TAO_ROOT}
173       shell: pwsh
174     - name: Build ACE/tests project
175       run: |
176         make -j 6 -C ${env:ACE_ROOT}/tests
177       shell: pwsh