Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace deprecated find_package for python #393

Merged
merged 5 commits into from
Apr 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/cov.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
cov:
runs-on: macos-11
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Fetch Boost superproject
run: |
cd ..
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/fast.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:
os: [ubuntu-latest, windows-latest, macos-latest]
fail-fast: true
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: prepare build
run: |
mkdir build
Expand Down
18 changes: 10 additions & 8 deletions .github/workflows/slow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
appleclang:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Fetch Boost superproject
run: |
cd ..
Expand All @@ -46,40 +46,42 @@ jobs:
cd libs/histogram
../../b2 $B2_OPTS cxxstd=17 test//all

gcc5:
runs-on: ubuntu-18.04
gcc7:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- uses: egor-tensin/setup-gcc@v1
with:
version: 5
version: 7
- name: Fetch Boost superproject
run: |
cd ..
git clone -b $GITHUB_BASE_REF --depth 5 https://github.com/boostorg/boost.git
cd boost
mv -f $GITHUB_WORKSPACE/* libs/histogram
git submodule update --init --depth 5 tools/build tools/boostdep
git submodule update --init --depth 5 libs/format
python tools/boostdep/depinst/depinst.py --git_args "--depth 5 --jobs 3" histogram
mv -f * $GITHUB_WORKSPACE
- name: Prepare b2
run: ./bootstrap.sh
- name: Test cxxstd=14 (warnings ignored)
run: |
cd libs/histogram
../../b2 -q -j2 toolset=gcc-5 cxxstd=14 test//all examples
../../b2 -q -j2 toolset=gcc-7 cxxstd=14 test//all examples

gcc10:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Fetch Boost superproject
run: |
cd ..
git clone -b $GITHUB_BASE_REF --depth 5 https://github.com/boostorg/boost.git
cd boost
mv -f $GITHUB_WORKSPACE/* libs/histogram
git submodule update --init --depth 5 tools/build tools/boostdep
git submodule update --init --depth 5 libs/format
python tools/boostdep/depinst/depinst.py --git_args "--depth 5 --jobs 3" histogram
mv -f * $GITHUB_WORKSPACE
- name: Prepare b2
Expand All @@ -92,7 +94,7 @@ jobs:
clang14:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Fetch Boost superproject
run: |
cd ..
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/superproject_cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
build:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Fetch Boost superproject
run: |
cd ..
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,4 @@ tools/codecov
coverage-report
.cache
venv
.pytest_cache
4 changes: 2 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
# 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

# We support CMake 3.5, but prefer 3.16 policies and behavior
cmake_minimum_required(VERSION 3.5...3.16)
# We support CMake 3.12, but prefer 3.27 policies and behavior
cmake_minimum_required(VERSION 3.12...3.27)

project(boost_histogram VERSION "${BOOST_SUPERPROJECT_VERSION}" LANGUAGES CXX)

Expand Down
4 changes: 2 additions & 2 deletions test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# 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

find_package(PythonInterp)
find_package(Python3)
if (PYTHONINTERP_FOUND)
HDembinski marked this conversation as resolved.
Show resolved Hide resolved
# checks that b2 and cmake are in sync
add_test(NAME runpy-${PROJECT_NAME}_check_build_system COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/check_build_system.py)
HDembinski marked this conversation as resolved.
Show resolved Hide resolved
Expand Down Expand Up @@ -152,4 +152,4 @@ if (NOT(CMAKE_CXX_COMPILER_ID STREQUAL "GNU" AND CMAKE_CXX_COMPILER_VERSION VERS

endif()

endif()
endif()
Loading