Skip to content

Add support for modular build structure. #249

Add support for modular build structure.

Add support for modular build structure. #249

Workflow file for this run

# Copyright (c) 2020 Mohammad Ashar Khan
# Copyright (c) 2021 Cem Bassoy
# Distributed under Boost Software License, Version 1.0
# (See accompanying file LICENSE_1_0.txt or copy at http://boost.org/LICENSE_1_0.txt)
name: "Windows"
on:
push:
paths-ignore:
- '**.md'
- 'doc/**'
pull_request:
paths-ignore:
- '**.md'
- 'doc/**'
jobs:
build:
name: "Windows=${{matrix.config.os}} msvc=${{matrix.config.version}} std=c++${{matrix.config.cxxstd}}"
runs-on: ${{matrix.config.os}}
strategy:
fail-fast: true
matrix:
config:
# - {os: windows-2016, toolset: msvc, version: 14.16, cxxstd: 11}
# - {os: windows-2019, toolset: msvc, version: 14.28, cxxstd: 11}
# - {os: windows-2019, toolset: msvc, version: 14.28, cxxstd: 17}
- {os: windows-2019, toolset: msvc, version: 14.29, cxxstd: latest}
# - {os: windows-2022, toolset: msvc, version: 14.30, cxxstd: latest}
steps:
- uses: actions/checkout@v2
- name: Enable Developer Command Prompt
uses: ilammy/msvc-dev-cmd@v1
with:
toolset: ${{matrix.config.version}}
- name: Setup BOOST_ROOT
shell: powershell
run: |
cd $env:GITHUB_WORKSPACE
cd ..
git clone -b master --depth 1 https://github.com/boostorg/boost.git boost-root
cd boost-root
git submodule update --init --depth=1 tools/build
git submodule update --init --depth=1 libs/config
git submodule update --init --depth=1 tools/boostdep
xcopy /s /e /q $env:GITHUB_WORKSPACE libs\numeric\ublas
python tools/boostdep/depinst/depinst.py -g " --depth=1" -I benchmarks numeric/ublas
echo "BOOST_ROOT=$pwd" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
echo "TOOLSET=${{matrix.config.toolset}}-${{matrix.config.version}}" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
- name: Prepare BOOST_ROOT
shell: powershell
run: |
echo $env:TOOLSET
# Creating %USERPROFILE%/user-config.jam file
@'
import os regex toolset ;
local toolset = [ regex.split [ os.environ TOOLSET ] "-" ] ;
using $(toolset[1]) : $(toolset[2-]:J="-") : ;
'@ | sc "$env:USERPROFILE/user-config.jam"
- name: Bootstrap BOOST_ROOT
shell: cmd
run: |
cd %BOOST_ROOT%
cmd /c bootstrap
b2 -j8 headers
# - name: Test Benchmarks
# shell: cmd
# run: |
# cd %BOOST_ROOT%
# cd libs\numeric\ublas
# %BOOST_ROOT%\b2 -j 4 benchmarks toolset=%TOOLSET% cxxstd=${{matrix.config.cxxstd}} address-model=64
- name: Test Tensor Examples
shell: cmd
run: |
cd %BOOST_ROOT%
cd libs\numeric\ublas
%BOOST_ROOT%\b2 -j8 examples/tensor toolset=%TOOLSET% cxxstd=${{matrix.config.cxxstd}} address-model=64
- name: Test Tensor
shell: cmd
run: |
cd %BOOST_ROOT%
cd libs\numeric\ublas
%BOOST_ROOT%\b2 -j8 test/tensor toolset=%TOOLSET% cxxstd=${{matrix.config.cxxstd}} address-model=64