diff --git a/.github/workflows/apple.yml b/.github/workflows/apple.yml index 9bd337780..0b8950a5f 100644 --- a/.github/workflows/apple.yml +++ b/.github/workflows/apple.yml @@ -5,68 +5,68 @@ name: "Apple MacOS" -on: +on: push: - paths-ignore: + paths-ignore: - '**.md' - 'doc/**' pull_request: - paths-ignore: + paths-ignore: - '**.md' - 'doc/**' jobs: build: - name: "MacOS 11 clang -std=c++${{matrix.cxxstd}}" - runs-on: macos-11 + name: "MacOS clang -std=c++${{matrix.cxxstd}}" + runs-on: macos-latest strategy: - fail-fast: true + fail-fast: false matrix: - cxxstd: [2a] + cxxstd: [20,2b] steps: - uses: actions/checkout@v2 - + - name: Git Clone Boost.uBlas run: | cd ${GITHUB_WORKSPACE} cd .. - + git clone -b master --depth 1 https://github.com/boostorg/boost.git boost-root cd boost-root echo "BOOST_ROOT=${PWD}" >> ${GITHUB_ENV} echo $BOOST_ROOT - + git submodule update --init --depth=1 --jobs 8 tools/build git submodule update --init --depth=1 --jobs 8 libs/config git submodule update --init --depth=1 --jobs 8 tools/boostdep - + mkdir -p libs/numeric/ cp -rp ${GITHUB_WORKSPACE}/. libs/numeric/ublas python tools/boostdep/depinst/depinst.py -g " --depth=1" -I benchmarks numeric/ublas - + - name: Bootstrap and Compile Boost.uBlas run: | cd $BOOST_ROOT ./bootstrap.sh ./b2 -j8 headers - echo "using clang : : $(brew --prefix llvm)/bin/clang++ ;" >> ~/user-config.jam; + echo "using clang ;" >> ~/user-config.jam; + - - name: Test Benchmarks run: | cd $BOOST_ROOT cd libs/numeric/ublas $BOOST_ROOT/b2 -j8 benchmarks cxxstd=${{matrix.cxxstd}} - + - name: Test Tensor Examples run: | cd $BOOST_ROOT cd libs/numeric/ublas $BOOST_ROOT/b2 -j8 examples/tensor cxxstd=${{matrix.cxxstd}} - + - name: Test Tensor run: | cd $BOOST_ROOT cd libs/numeric/ublas $BOOST_ROOT/b2 -j8 test/tensor cxxstd=${{matrix.cxxstd}} - + diff --git a/.github/workflows/clangtidy.yml b/.github/workflows/clangtidy.yml index 11b1aea41..1deae8115 100644 --- a/.github/workflows/clangtidy.yml +++ b/.github/workflows/clangtidy.yml @@ -5,48 +5,52 @@ name: "Static Analysis" -on: +on: push: - paths-ignore: + paths-ignore: - '**.md' - 'doc/**' pull_request: - paths-ignore: + paths-ignore: - '**.md' - 'doc/**' jobs: check: name: Linux Clang-Tidy - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 - - - name: Install Clang 11 - run: sudo apt-get update && sudo apt-get install -y clang-11 clang-tidy-11 - + - uses: actions/checkout@v4 + + - name: Install Clang + run: sudo apt-get update && sudo apt-get install -y clang clang-tidy + + - name: Setup + run: sudo apt-get update && sudo apt-get -y install sudo python3 git g++ curl xz-utils + - name: "Install Boost from Source" run: | cd .. git clone --depth 1 https://github.com/boostorg/boost.git --recursive --shallow-submodules cd boost - ./bootstrap.sh + ./bootstrap.sh ./b2 headers sudo cp -r -L boost /usr/include rm -rf boost - + - name: "Run Clang-Tidy" - run: clang-tidy-11 examples/tensor/*.cpp test/tensor/*.cpp -- -Iinclude -std=c++20 > reports.txt + run: clang-tidy examples/tensor/*.cpp test/tensor/*.cpp -- -Iinclude -std=c++20 > reports.txt - name: "Print Clang-Tidy Report" run: cat reports.txt - - - uses: actions/setup-python@v2 - + + - uses: actions/setup-python@v5 + with: { 'python-version': '3' } + - name: "Post review comments" if: github.event.pull_request.head.repo.full_name == github.repository run: | pip3 install 'unidiff~=0.6.0' --force-reinstall pip3 install 'PyGithub~=1.51' --force-reinstall pip3 install 'requests~=2.23' --force-reinstall - python ./.ci/post_review.py --repository ${{ github.repository }} --token ${{ github.token}} --pr ${{ github.event.pull_request.number }} --path reports.txt - + python ./.ci/post_review.py --repository ${{ github.repository }} --token ${{ github.token}} --pr ${{ github.event.pull_request.number }} --path reports.txt + diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index 20b9c5311..44555cf55 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -5,64 +5,82 @@ name: "Linux" -on: +on: push: - paths-ignore: + paths-ignore: - '**.md' - 'doc/**' pull_request: - paths-ignore: + paths-ignore: - '**.md' - 'doc/**' jobs: build: - name: Ubuntu 20.04 "cxx=${{matrix.config.cxx}}, std=c++${{matrix.config.cxxstd}}, variant=c++${{matrix.config.variant}}" - runs-on: ubuntu-20.04 + name: Ubuntu "cxx=${{matrix.config.cxx}}, std=c++${{matrix.config.cxxstd}}, variant=c++${{matrix.config.variant}}" + runs-on: ubuntu-latest + container: + image: ${{matrix.config.container}} + volumes: + - /node20217:/node20217:rw,rshared + - ${{ startsWith(matrix.config.container, 'ubuntu:1') && '/node20217:/__e/node20:ro,rshared' || ' ' }} strategy: - fail-fast: true + fail-fast: false # If any compiler fails to compile, continue CI for next compiler in matrix instead of failing early matrix: - config: - - { name: clang, cc: clang-10, cxx: clang++-10, cxxstd: 20, variant: debug, opt: off} - - { name: clang, cc: clang-11, cxx: clang++-11, cxxstd: 20, variant: debug, opt: off} - - { name: clang, cc: clang-10, cxx: clang++-10, cxxstd: 20, variant: release, opt: speed, cxxflags: -fopenmp, ldflags: -lgomp=libomp5} - - { name: clang, cc: clang-11, cxx: clang++-11, cxxstd: 20, variant: release, opt: speed, cxxflags: -fopenmp, ldflags: -lgomp=libomp5} - - { name: gcc, cc: gcc-10, cxx: g++-10, cxxstd: 20, variant: debug, opt: off} - - { name: gcc, cc: gcc-10, cxx: g++-10, cxxstd: 20, variant: release, opt: speed, cxxflags: -fopenmp, ldflags: -lgomp} - + config: + - { name: clang, cc: clang-10, cxx: clang++-10, cxxstd: 20, variant: debug, opt: off, container: 'ubuntu:20.04' } + - { name: clang, cc: clang-11, cxx: clang++-11, cxxstd: 20, variant: debug, opt: off, container: 'ubuntu:20.04' } + - { name: clang, cc: clang-10, cxx: clang++-10, cxxstd: 20, variant: release, opt: speed, cxxflags: -fopenmp, ldflags: -lgomp=libomp5, container: 'ubuntu:20.04' } + - { name: clang, cc: clang-11, cxx: clang++-11, cxxstd: 20, variant: release, opt: speed, cxxflags: -fopenmp, ldflags: -lgomp=libomp5, container: 'ubuntu:20.04' } + - { name: gcc, cc: gcc-10, cxx: g++-10, cxxstd: 20, variant: debug, opt: off, container: 'ubuntu:20.04' } + - { name: gcc, cc: gcc-10, cxx: g++-10, cxxstd: 20, variant: release, opt: speed, cxxflags: -fopenmp, ldflags: -lgomp, container: 'ubuntu:20.04' } + steps: - - uses: actions/checkout@v2 - + - name: Setup container environment + if: matrix.config.container + run: | + apt-get update + apt-get -y install sudo python3 git g++ curl xz-utils + + - name: Install nodejs20glibc2.17 + if: ${{ startsWith( matrix.config.container, 'ubuntu:1' ) }} + run: | + curl -LO https://archives.boost.io/misc/node/node-v20.9.0-linux-x64-glibc-217.tar.xz + tar -xf node-v20.9.0-linux-x64-glibc-217.tar.xz --strip-components 1 -C /node20217 + ldd /__e/node20/bin/node + - name: Install g++-10 if: matrix.config.cxx == 'g++-10' - run: sudo apt update && sudo apt-get install -y g++-10 libomp-dev - + run: sudo apt update && sudo apt-get install -y g++-10 libomp-dev + - name: Install Clang 10 if: matrix.config.cxx == 'clang++-10' run: sudo apt-get update && sudo apt-get install -y clang-10 - + - name: Install Clang 11 if: matrix.config.cxx == 'clang++-11' run: sudo apt-get update && sudo apt-get install -y clang-11 - + + - uses: actions/checkout@v4 + - name: Git Clone Boost.uBlas run: | cd ${GITHUB_WORKSPACE} cd .. - + git clone -b master --depth 1 https://github.com/boostorg/boost.git boost-root cd boost-root echo "BOOST_ROOT=${PWD}" >> ${GITHUB_ENV} echo $BOOST_ROOT - + git submodule update --init --depth=1 --jobs 8 tools/build git submodule update --init --depth=1 --jobs 8 libs/config git submodule update --init --depth=1 --jobs 8 tools/boostdep - + mkdir -p libs/numeric/ cp -rp ${GITHUB_WORKSPACE}/. libs/numeric/ublas - python tools/boostdep/depinst/depinst.py -g " --depth=1" -I benchmarks numeric/ublas + python3 tools/boostdep/depinst/depinst.py -g " --depth=1" -I benchmarks numeric/ublas - name: Bootstrap Boost and Compile Boost run: | @@ -70,13 +88,13 @@ jobs: ./bootstrap.sh ./b2 -j8 headers echo "using ${{ matrix.config.name }} : : ${{ matrix.config.cxx }} ;" >> ~/user-config.jam; - + # - name: Test Benchmarks # run: | # cd $BOOST_ROOT # cd libs/numeric/ublas # $BOOST_ROOT/b2 -j 4 benchmarks toolset=clang cxxstd=${{matrix.config.cxxstd}} cxxflags="-O3" - + - name: Test Tensor Examples run: | cd $BOOST_ROOT/libs/numeric/ublas @@ -86,7 +104,7 @@ jobs: else $BOOST_ROOT/b2 -j8 examples/tensor toolset=${{matrix.config.name}} cxxstd=${{matrix.config.cxxstd}} variant=${{matrix.config.variant}} optimization=${{matrix.config.opt}} cxxflags="${{matrix.config.cxxflags}}" linkflags="${{matrix.config.ldflags}}" fi - + - name: Test Tensor Unit-Tests run: | cd $BOOST_ROOT/libs/numeric/ublas @@ -95,5 +113,5 @@ jobs: $BOOST_ROOT/b2 -j8 test/tensor toolset=${{matrix.config.name}} cxxstd=${{matrix.config.cxxstd}} variant=${{matrix.config.variant}} optimization=${{matrix.config.opt}} else $BOOST_ROOT/b2 -j8 test/tensor toolset=${{matrix.config.name}} cxxstd=${{matrix.config.cxxstd}} variant=${{matrix.config.variant}} optimization=${{matrix.config.opt}} cxxflags="${{matrix.config.cxxflags}}" linkflags="${{matrix.config.ldflags}}" - fi - + fi + diff --git a/.github/workflows/sanitizer.yml b/.github/workflows/sanitizer.yml index a2edff34b..02177d1d0 100644 --- a/.github/workflows/sanitizer.yml +++ b/.github/workflows/sanitizer.yml @@ -5,57 +5,75 @@ name: "Clang Sanitizer" -on: +on: push: - paths-ignore: + paths-ignore: - '**.md' - 'doc/**' pull_request: - paths-ignore: + paths-ignore: - '**.md' - 'doc/**' jobs: build: name: "${{matrix.config.name}} with ${{matrix.config.description}} sanitizer with std=${{matrix.config.cxx}} and variant=${{matrix.config.variant}}" - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest + container: + image: ${{matrix.config.container}} + volumes: + - /node20217:/node20217:rw,rshared + - ${{ startsWith(matrix.config.container, 'ubuntu:1') && '/node20217:/__e/node20:ro,rshared' || ' ' }} strategy: fail-fast: false # If any compiler fails to compile, continue CI for next compiler in matrix instead of failing early matrix: config: - - { name: clang, description: address and leak, cc: clang-11, cxx: clang++-11, cxxstd: 20, variant: debug, opt: off , cxxflags: -fsanitize=address -fno-omit-frame-pointer, ldflags: -fsanitize=address } - - { name: clang, description: undefined behavior, cc: clang-11, cxx: clang++-11, cxxstd: 20, variant: debug, opt: off , cxxflags: -fsanitize=undefined, ldflags: -fsanitize=undefined } - - { name: clang, description: thread, cc: clang-11, cxx: clang++-11, cxxstd: 20, variant: debug, opt: off , cxxflags: -fsanitize=thread, ldflags: -fsanitize=thread } - - { name: gcc, description: address and leak, cc: gcc-10, cxx: g++-10, cxxstd: 20, variant: release, opt: speed, cxxflags: -fopenmp -fsanitize=address -fno-omit-frame-pointer, ldflags: -fsanitize=address -fopenmp} -# - { name: gcc, description: undefined behavior, cc: gcc-10, cxx: g++-10, cxxstd: 20, variant: release, opt: speed, cxxflags: -fopenmp -fsanitize=undefined, ldflags: -fsanitize=undefined -fopenmp} -# - { name: gcc, description: thread, cc: gcc-10, cxx: g++-10, cxxstd: 20, variant: release, opt: speed, cxxflags: -fopenmp -fsanitize=thread, ldflags: -fsanitize=thread -fopenmp} - + - { name: clang, description: address and leak, cc: clang-11, cxx: clang++-11, cxxstd: 20, variant: debug, opt: off , cxxflags: -fsanitize=address -fno-omit-frame-pointer, ldflags: -fsanitize=address , container: 'ubuntu:20.04' } + - { name: clang, description: undefined behavior, cc: clang-11, cxx: clang++-11, cxxstd: 20, variant: debug, opt: off , cxxflags: -fsanitize=undefined, ldflags: -fsanitize=undefined, container: 'ubuntu:20.04' } + - { name: clang, description: thread, cc: clang-11, cxx: clang++-11, cxxstd: 20, variant: debug, opt: off , cxxflags: -fsanitize=thread, ldflags: -fsanitize=thread , container: 'ubuntu:20.04' } + - { name: gcc, description: address and leak, cc: gcc-10, cxx: g++-10, cxxstd: 20, variant: release, opt: speed, cxxflags: -fopenmp -fsanitize=address -fno-omit-frame-pointer, ldflags: -fsanitize=address -fopenmp, container: 'ubuntu:20.04' } +# - { name: gcc, description: undefined behavior, cc: gcc-10, cxx: g++-10, cxxstd: 20, variant: release, opt: speed, cxxflags: -fopenmp -fsanitize=undefined, ldflags: -fsanitize=undefined -fopenmp, container: 'ubuntu:20.04' } +# - { name: gcc, description: thread, cc: gcc-10, cxx: g++-10, cxxstd: 20, variant: release, opt: speed, cxxflags: -fopenmp -fsanitize=thread, ldflags: -fsanitize=thread -fopenmp, container: 'ubuntu:20.04' } + steps: - - uses: actions/checkout@v2 - + - name: Setup container environment + if: matrix.config.container + run: | + apt-get update + apt-get -y install sudo python3 git g++ curl xz-utils + + - name: Install nodejs20glibc2.17 + if: ${{ startsWith( matrix.config.container, 'ubuntu:1' ) }} + run: | + curl -LO https://archives.boost.io/misc/node/node-v20.9.0-linux-x64-glibc-217.tar.xz + tar -xf node-v20.9.0-linux-x64-glibc-217.tar.xz --strip-components 1 -C /node20217 + ldd /__e/node20/bin/node + - name: Install Clang 11 run: sudo apt-get update && sudo apt-get install -y clang-11 clang-tools-11 - name: Install GCC 10 run: sudo apt-get update && sudo apt-get install -y g++-10 libomp-dev - + + - uses: actions/checkout@v4 + - name: Git Clone Boost.uBlas run: | cd ${GITHUB_WORKSPACE} cd .. - + git clone -b master --depth 1 https://github.com/boostorg/boost.git boost-root cd boost-root echo "BOOST_ROOT=${PWD}" >> ${GITHUB_ENV} echo $BOOST_ROOT - + git submodule update --init --depth=1 --jobs 8 tools/build git submodule update --init --depth=1 --jobs 8 libs/config git submodule update --init --depth=1 --jobs 8 tools/boostdep - + mkdir -p libs/numeric/ cp -rp ${GITHUB_WORKSPACE}/. libs/numeric/ublas - python tools/boostdep/depinst/depinst.py -g " --depth=1" -I benchmarks numeric/ublas + python3 tools/boostdep/depinst/depinst.py -g " --depth=1" -I benchmarks numeric/ublas - name: Bootstrap Boost and Compile Boost run: | @@ -65,19 +83,19 @@ jobs: echo "using ${{ matrix.config.name }} : : ${{ matrix.config.cxx }} ;" >> ~/user-config.jam; export ASAN_OPTIONS=symbolize=1 export ASAN_OPTIONS=detect_leaks=1 - + - name: Run Tensor Examples with "${{matrix.config.description}}" sanitizer - run: | - cd $BOOST_ROOT/libs/numeric/ublas + run: | + cd $BOOST_ROOT/libs/numeric/ublas ASAN_OPTIONS=detect_leaks=1 ASAN_OPTIONS=symbolize=1 $BOOST_ROOT/b2 -j8 examples/tensor toolset=${{matrix.config.name}} cxxstd=${{matrix.config.cxxstd}} variant=${{matrix.config.variant}} optimization=${{matrix.config.opt}} cxxflags="${{matrix.config.cxxflags}}" linkflags="${{matrix.config.ldflags}}" - - - name: Run Tensor Tests with "${{matrix.config.description}}" sanitizer + + - name: Run Tensor Tests with "${{matrix.config.description}}" sanitizer run: | cd $BOOST_ROOT/libs/numeric/ublas ASAN_OPTIONS=detect_leaks=1 ASAN_OPTIONS=symbolize=1 $BOOST_ROOT/b2 -j8 test/tensor toolset=${{matrix.config.name}} cxxstd=${{matrix.config.cxxstd}} variant=${{matrix.config.variant}} optimization=${{matrix.config.opt}} cxxflags="${{matrix.config.cxxflags}}" linkflags="${{matrix.config.ldflags}}" - - + + diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 3f761707e..72035b4f6 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -4,13 +4,13 @@ # (See accompanying file LICENSE_1_0.txt or copy at http://boost.org/LICENSE_1_0.txt) name: "Windows" -on: +on: push: - paths-ignore: + paths-ignore: - '**.md' - 'doc/**' pull_request: - paths-ignore: + paths-ignore: - '**.md' - 'doc/**' jobs: @@ -20,21 +20,22 @@ jobs: strategy: fail-fast: true matrix: - config: -# - {os: windows-2016, toolset: msvc, version: 14.16, cxxstd: 11} + 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-2019, toolset: msvc, version: 14.29, cxxstd: latest} # - {os: windows-2022, toolset: msvc, version: 14.30, cxxstd: latest} - + - {os: windows-2022, toolset: msvc, cxxstd: latest, toolsetver: 14.3 } + steps: - - uses: actions/checkout@v2 - + - uses: actions/checkout@v4 + - name: Enable Developer Command Prompt uses: ilammy/msvc-dev-cmd@v1 with: toolset: ${{matrix.config.version}} - + - name: Setup BOOST_ROOT shell: powershell run: | @@ -45,15 +46,15 @@ jobs: 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 - + echo "TOOLSET=${{matrix.config.toolset}}-${{matrix.config.toolsetver}}" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append + - name: Prepare BOOST_ROOT shell: powershell run: | @@ -63,33 +64,33 @@ jobs: import os regex toolset ; local toolset = [ regex.split [ os.environ TOOLSET ] "-" ] ; using $(toolset[1]) : $(toolset[2-]:J="-") : ; - '@ | sc "$env:USERPROFILE/user-config.jam" - + '@ | 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 - + diff --git a/benchmarks/Jamfile b/benchmarks/Jamfile index ab2f77e82..0ff838f85 100644 --- a/benchmarks/Jamfile +++ b/benchmarks/Jamfile @@ -4,8 +4,10 @@ # Boost Software License, Version 1.0. (See accompanying file # LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -project boost/ublas/benchmarks - : requirements /boost/program_options//boost_program_options +project + : requirements + /boost/ublas//boost_ublas + /boost/program_options//boost_program_options ; exe add : add.cpp ; diff --git a/benchmarks/opencl/Jamfile b/benchmarks/opencl/Jamfile index 282d00711..045c9cefb 100644 --- a/benchmarks/opencl/Jamfile +++ b/benchmarks/opencl/Jamfile @@ -13,7 +13,7 @@ import ../../clblas ; using opencl ; using clblas ; -project boost/ublas/benchmarks/opencl +project : requirements /boost/program_options//boost_program_options gcc:-Wno-ignored-attributes diff --git a/build.jam b/build.jam new file mode 100644 index 000000000..e2e3be8f7 --- /dev/null +++ b/build.jam @@ -0,0 +1,34 @@ +# Copyright René Ferdinand Rivera Morell 2023-2024 +# Distributed under the Boost Software License, Version 1.0. +# (See accompanying file LICENSE_1_0.txt or copy at +# http://www.boost.org/LICENSE_1_0.txt) + +require-b2 5.2 ; + +constant boost_dependencies : + /boost/compute//boost_compute + /boost/concept_check//boost_concept_check + /boost/config//boost_config + /boost/core//boost_core + /boost/interval//boost_interval + /boost/iterator//boost_iterator + /boost/mpl//boost_mpl + /boost/range//boost_range + /boost/serialization//boost_serialization + /boost/smart_ptr//boost_smart_ptr + /boost/static_assert//boost_static_assert + /boost/type_traits//boost_type_traits + /boost/typeof//boost_typeof ; + +project /boost/ublas + ; + +explicit + [ alias boost_ublas : : : + : include $(boost_dependencies) ] + [ alias all : boost_ublas benchmarks examples/tensor test ] + ; + +call-if : boost-library ublas + ; + diff --git a/examples/tensor/Jamfile b/examples/tensor/Jamfile index 101a8a4c9..0211d5416 100644 --- a/examples/tensor/Jamfile +++ b/examples/tensor/Jamfile @@ -6,20 +6,23 @@ # Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at # http://www.boost.org/LICENSE_1_0.txt) -import ../../../../config/checks/config : requires ; - +import-search /boost/config/checks ; +import config : requires ; + # Project settings -project boost-ublas-tensor-example +project : requirements + /boost/ublas//boost_ublas BOOST_UBLAS_NO_EXCEPTIONS vacpp:"BOOST_UBLAS_NO_ELEMENT_PROXIES" gcc:"-Wall -pedantic -Wextra -Wno-unknown-pragmas" clang:"-Wall -pedantic -Wextra -Wno-unknown-pragmas" msvc:"/W4" # == all [ requires cxx17_if_constexpr ] + 20 ; -exe access_tensor : access_tensor.cpp ; +exe access_tensor : access_tensor.cpp /boost/multiprecision//boost_multiprecision ; exe simple_expressions : simple_expressions.cpp ; exe multiply_tensors_product_function : multiply_tensors_product_function.cpp ; exe multiply_tensors_einstein_notation : multiply_tensors_einstein_notation.cpp ; diff --git a/test/Jamfile b/test/Jamfile index f6716e2c6..78a6bc132 100644 --- a/test/Jamfile +++ b/test/Jamfile @@ -26,29 +26,30 @@ UBLAS_TESTSET ?= # Sparse matrices: USE_MAPPED_MATRIX USE_COMPRESSED_MATRIX USE_COORDINATE_MATRIX USE_MAPPED_VECTOR_OF_MAPPED_VECTOR USE_GENERALIZED_VECTOR_OF_VECTOR UBLAS_TESTSET_SPARSE = [ modules.peek : UBLAS_TESTSET_SPARSE ] ; -UBLAS_TESTSET_SPARSE ?= +UBLAS_TESTSET_SPARSE ?= USE_DOUBLE USE_STD_COMPLEX # USE_RANGE USE_SLICE # Too complex for regression testing USE_UNBOUNDED_ARRAY USE_MAP_ARRAY USE_STD_MAP - USE_MAPPED_VECTOR USE_COMPRESSED_VECTOR - USE_MAPPED_MATRIX USE_COMPRESSED_MATRIX + USE_MAPPED_VECTOR USE_COMPRESSED_VECTOR + USE_MAPPED_MATRIX USE_COMPRESSED_MATRIX ; # Generalize VofV still failing # USE_GENERALIZED_VECTOR_OF_VECTOR UBLAS_TESTSET_SPARSE_COO = [ modules.peek : UBLAS_TESTSET_SPARSE_COO ] ; -UBLAS_TESTSET_SPARSE_COO ?= +UBLAS_TESTSET_SPARSE_COO ?= USE_DOUBLE USE_STD_COMPLEX USE_UNBOUNDED_ARRAY USE_COORDINATE_VECTOR - USE_COORDINATE_MATRIX + USE_COORDINATE_MATRIX ; # Project settings -project boost-ublas-test +project : requirements + /boost/ublas//boost_ublas BOOST_UBLAS_NO_EXCEPTIONS vacpp:"BOOST_UBLAS_NO_ELEMENT_PROXIES" gcc:"-Wall -Wno-unknown-pragmas" @@ -111,16 +112,17 @@ test-suite numeric/uBLAS test33.cpp : : : USE_FLOAT - USE_DOUBLE - USE_STD_COMPLEX + USE_DOUBLE + USE_STD_COMPLEX USE_STD_MAP - USE_MAPPED_VECTOR_OF_MAPPED_VECTOR - : test3_mvov + USE_MAPPED_VECTOR_OF_MAPPED_VECTOR + : test3_mvov : ] [ run test4.cpp test42.cpp test43.cpp + /boost/math//boost_math_tr1 : : : $(UBLAS_TESTSET) ] @@ -165,92 +167,93 @@ test-suite numeric/uBLAS ] [ run triangular_layout.cpp ] - [ run comp_mat_erase.cpp + [ run comp_mat_erase.cpp /boost/test//included : : : msvc:on ] - [ run sparse_view_test.cpp + [ run sparse_view_test.cpp /boost/test//included : : : msvc:on ] - [ run begin_end.cpp + [ run begin_end.cpp /boost/math//boost_math_tr1 ] - [ run num_columns.cpp + [ run num_columns.cpp /boost/math//boost_math_tr1 ] - [ run num_rows.cpp + [ run num_rows.cpp /boost/math//boost_math_tr1 ] - [ run size.cpp + [ run size.cpp /boost/math//boost_math_tr1 ] - [ run test_coordinate_matrix_sort.cpp + [ run test_coordinate_matrix_sort.cpp /boost/math//boost_math_tr1 ] - [ run test_coordinate_matrix_sort.cpp + [ run test_coordinate_matrix_sort.cpp /boost/math//boost_math_tr1 : : : BOOST_UBLAS_COO_ALWAYS_DO_FULL_SORT : test_coordinate_matrix_always_do_full_sort : ] - [ run test_complex_norms.cpp + [ run test_complex_norms.cpp /boost/math//boost_math_tr1 ] - [ run test_scaled_norm.cpp + [ run test_scaled_norm.cpp /boost/math//boost_math_tr1 : : : BOOST_UBLAS_SCALED_NORM ] - [ run test_assignment.cpp + [ run test_assignment.cpp /boost/timer//boost_timer /boost/math//boost_math_tr1 : : : BOOST_UBLAS_COO_ALWAYS_DO_FULL_SORT + BOOST_TIMER_ENABLE_DEPRECATED ] [ run test_triangular.cpp : : : /boost/timer//boost_timer ] - [ run test_ticket7296.cpp + [ run test_ticket7296.cpp /boost/math//boost_math_tr1 : : : msvc:/wd4127 # The program checks that test facilities work fine. The warning appears many times. : : ] - [ run test_inplace_solve.cpp - : - : + [ run test_inplace_solve.cpp /boost/math//boost_math_tr1 + : + : : $(UBLAS_TESTSET) : test_inplace_solve_basic : ] - [ run test_inplace_solve.cpp - : - : + [ run test_inplace_solve.cpp /boost/math//boost_math_tr1 + : + : : $(UBLAS_TESTSET_SPARSE) $(UBLAS_TESTSET_SPARSE_COO) : test_inplace_solve_sparse : ] - [ run test_inplace_solve.cpp - : - : + [ run test_inplace_solve.cpp /boost/math//boost_math_tr1 + : + : : USE_MAPPED_VECTOR_OF_MAPPED_VECTOR : test_inplace_solve_mvov : ] - [ run test_coordinate_vector_inplace_merge.cpp + [ run test_coordinate_vector_inplace_merge.cpp /boost/math//boost_math_tr1 ] - [ run test_coordinate_matrix_inplace_merge.cpp + [ run test_coordinate_matrix_inplace_merge.cpp /boost/math//boost_math_tr1 ] - [ run test_banded_storage_layout.cpp + [ run test_banded_storage_layout.cpp /boost/math//boost_math_tr1 : : : : : ] - [ run test_fixed_containers.cpp + [ run test_fixed_containers.cpp /boost/math//boost_math_tr1 : : : ] - [ run test_matrix_vector.cpp + [ run test_matrix_vector.cpp /boost/math//boost_math_tr1 ] [ compile minimal_allocator_test.cpp ] ; diff --git a/test/opencl/Jamfile b/test/opencl/Jamfile index cc8679223..9da1870ed 100644 --- a/test/opencl/Jamfile +++ b/test/opencl/Jamfile @@ -13,7 +13,7 @@ import ../../clblas ; using opencl ; using clblas ; -project boost/ublas/test/opencl +project : requirements gcc:-Wno-ignored-attributes clang:-Wno-ignored-attributes diff --git a/test/tensor/Jamfile b/test/tensor/Jamfile index 908e359ea..a76251163 100644 --- a/test/tensor/Jamfile +++ b/test/tensor/Jamfile @@ -11,7 +11,8 @@ # Google and Fraunhofer IOSB, Ettlingen, Germany # -import ../../../../config/checks/config : requires ; +import-search /boost/config/checks ; +import config : requires ; project boost/ublas/test/tensor : requirements @@ -22,7 +23,7 @@ project boost/ublas/test/tensor alias unit_test_framework : # sources - /boost//unit_test_framework + /boost/test//boost_unit_test_framework ; # make aliases explicit so the libraries will only be built when requested @@ -93,6 +94,6 @@ test-suite boost-ublas-tensor-test : : test_tensor : - # + # ] ;