Skip to content

Commit b218772

Browse files
committed
gha tweaks
1 parent 641f622 commit b218772

File tree

2 files changed

+39
-32
lines changed

2 files changed

+39
-32
lines changed

.github/workflows/ci.yml

Lines changed: 34 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -16,18 +16,18 @@ jobs:
1616
strategy:
1717
fail-fast: false
1818
matrix:
19-
variant:
20-
- name: Default (full feature set)
21-
b2_variant: "debug,release"
22-
- name: No capture / dynamic allocation
23-
b2_variant: "leaf_debug_capture0,leaf_release_capture0"
19+
config:
20+
- name: Default
21+
variant: "debug,release"
22+
- name: No capture
23+
variant: "leaf_debug_capture0,leaf_release_capture0"
2424
- name: No diagnostics
25-
b2_variant: "leaf_debug_diag0,leaf_release_diag0"
25+
variant: "leaf_debug_diag0,leaf_release_diag0"
2626
- name: Embedded
27-
b2_variant: "leaf_debug_embedded,leaf_release_embedded"
27+
variant: "leaf_debug_embedded,leaf_release_embedded"
2828
- name: Single header
29-
b2_variant: "leaf_debug_single_header,leaf_release_single_header"
30-
config:
29+
variant: "leaf_debug_single_header,leaf_release_single_header"
30+
platform:
3131
- toolset: gcc-5
3232
cxxstd: "11,14,1z"
3333
container: ubuntu:18.04
@@ -196,27 +196,29 @@ jobs:
196196
cxxstd: "11,14,17,20,2b"
197197
os: macos-26
198198

199-
runs-on: ${{matrix.config.os}}
199+
name: ${{matrix.platform.compiler || matrix.platform.toolset}} ${{matrix.config.name}}
200+
201+
runs-on: ${{matrix.platform.os}}
200202

201203
container:
202-
image: ${{matrix.config.container}}
204+
image: ${{matrix.platform.container}}
203205
volumes:
204206
- /node20217:/node20217:rw,rshared
205-
- ${{ startsWith(matrix.config.container, 'ubuntu:1') && '/node20217:/__e/node20:ro,rshared' || ' ' }}
207+
- ${{ startsWith(matrix.platform.container, 'ubuntu:1') && '/node20217:/__e/node20:ro,rshared' || ' ' }}
206208

207209
defaults:
208210
run:
209211
shell: bash
210212

211213
steps:
212214
- name: Setup container environment
213-
if: matrix.config.container
215+
if: matrix.platform.container
214216
run: |
215217
apt-get update
216218
apt-get -y install sudo python3 git g++ curl xz-utils
217219
218220
- name: Install nodejs20glibc2.17
219-
if: ${{ startsWith( matrix.config.container, 'ubuntu:1' ) }}
221+
if: ${{ startsWith( matrix.platform.container, 'ubuntu:1' ) }}
220222
run: |
221223
curl -LO https://archives.boost.io/misc/node/node-v20.9.0-linux-x64-glibc-217.tar.xz
222224
tar -xf node-v20.9.0-linux-x64-glibc-217.tar.xz --strip-components 1 -C /node20217
@@ -225,10 +227,10 @@ jobs:
225227
- uses: actions/checkout@v4
226228

227229
- name: Install packages
228-
if: matrix.config.install
230+
if: matrix.platform.install
229231
run: |
230232
sudo apt-get update
231-
sudo apt-get -y install ${{matrix.config.install}}
233+
sudo apt-get -y install ${{matrix.platform.install}}
232234
233235
- name: Setup Boost
234236
run: |
@@ -253,9 +255,9 @@ jobs:
253255
./b2 -d0 headers
254256
255257
- name: Create user-config.jam
256-
if: matrix.config.compiler
258+
if: matrix.platform.compiler
257259
run: |
258-
echo "using ${{matrix.config.toolset}} : : ${{matrix.config.compiler}} ;" > ~/user-config.jam
260+
echo "using ${{matrix.platform.toolset}} : : ${{matrix.platform.compiler}} ;" > ~/user-config.jam
259261
260262
- name: Generate headers
261263
run: |
@@ -265,24 +267,24 @@ jobs:
265267
- name: Run tests
266268
run: |
267269
cd ../boost-root
268-
./b2 -j3 libs/$LIBRARY/test toolset=${{matrix.config.toolset}} cxxstd=${{matrix.config.cxxstd}} ${ADDRMD:+address-model=$ADDRMD} link=shared,static variant=${{matrix.variant.b2_variant}}
270+
./b2 -j3 libs/$LIBRARY/test toolset=${{matrix.platform.toolset}} cxxstd=${{matrix.platform.cxxstd}} ${ADDRMD:+address-model=$ADDRMD} link=shared,static variant=${{matrix.config.variant}}
269271
270272
windows:
271273
strategy:
272274
fail-fast: false
273275
matrix:
274-
variant:
275-
- name: Default (full feature set)
276-
b2_variant: "debug,release"
277-
- name: No capture / dynamic allocation
278-
b2_variant: "leaf_debug_capture0,leaf_release_capture0"
276+
config:
277+
- name: Default
278+
variant: "debug,release"
279+
- name: No capture
280+
variant: "leaf_debug_capture0,leaf_release_capture0"
279281
- name: No diagnostics
280-
b2_variant: "leaf_debug_diag0,leaf_release_diag0"
282+
variant: "leaf_debug_diag0,leaf_release_diag0"
281283
- name: Embedded
282-
b2_variant: "leaf_debug_embedded,leaf_release_embedded"
284+
variant: "leaf_debug_embedded,leaf_release_embedded"
283285
- name: Single header
284-
b2_variant: "leaf_debug_single_header,leaf_release_single_header"
285-
config:
286+
variant: "leaf_debug_single_header,leaf_release_single_header"
287+
platform:
286288
- toolset: msvc-14.3
287289
cxxstd: "14,17,20,latest"
288290
addrmd: 32,64
@@ -296,7 +298,9 @@ jobs:
296298
addrmd: 64
297299
os: windows-2022
298300

299-
runs-on: ${{matrix.config.os}}
301+
name: ${{matrix.platform.compiler || matrix.platform.toolset}} ${{matrix.config.name}}
302+
303+
runs-on: ${{matrix.platform.os}}
300304

301305
steps:
302306
- uses: actions/checkout@v4
@@ -332,4 +336,4 @@ jobs:
332336
shell: cmd
333337
run: |
334338
cd ../boost-root
335-
b2 -j3 libs/%LIBRARY%/test toolset=${{matrix.config.toolset}} cxxstd=${{matrix.config.cxxstd}} address-model=${{matrix.config.addrmd}} variant=${{matrix.variant.b2_variant}}
339+
b2 -j3 libs/%LIBRARY%/test toolset=${{matrix.platform.toolset}} cxxstd=${{matrix.platform.cxxstd}} address-model=${{matrix.platform.addrmd}} variant=${{matrix.config.variant}}

include/boost/leaf/config/tls_win32.hpp

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -252,7 +252,7 @@ namespace detail
252252
hinstance_ = hinstDLL;
253253
char name[64];
254254
int num_written = std::snprintf(name, sizeof(name), "Local\\boost_leaf_tls_%lu", GetCurrentProcessId());
255-
BOOST_LEAF_ASSERT(num_written >= 0 && num_written < sizeof(name)), (void) num_written;
255+
BOOST_LEAF_ASSERT(num_written >= 0 && num_written < int(sizeof(name))), (void) num_written;
256256
HANDLE mapping = CreateFileMappingA(INVALID_HANDLE_VALUE, nullptr, PAGE_READWRITE, 0, sizeof(slot_map *), name);
257257
if (!mapping)
258258
{
@@ -345,7 +345,10 @@ namespace detail
345345
#pragma comment(linker, "/INCLUDE:_boost_leaf_tls_callback")
346346
#endif
347347
#elif defined(__GNUC__)
348-
extern "C" __attribute__((used, weak)) PIMAGE_TLS_CALLBACK boost_leaf_tls_callback __attribute__((section(".CRT$XLB"))) = tls_callback;
348+
#pragma GCC diagnostic push
349+
#pragma GCC diagnostic ignored "-Wattributes"
350+
extern "C" __attribute__((used, selectany)) PIMAGE_TLS_CALLBACK boost_leaf_tls_callback __attribute__((section(".CRT$XLB"))) = tls_callback;
351+
#pragma GCC diagnostic pop
349352
#endif
350353
} // namespace detail
351354

0 commit comments

Comments
 (0)