Skip to content

Commit

Permalink
Update boost-1.86.beta1
Browse files Browse the repository at this point in the history
  • Loading branch information
Jackarain committed Jul 29, 2024
1 parent 4ac1d2e commit afe40ec
Show file tree
Hide file tree
Showing 2,341 changed files with 141,193 additions and 47,243 deletions.
38 changes: 38 additions & 0 deletions third_party/boost/.circleci/autocancel.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
#!/bin/bash

# Auto-cancel preceding workflows
# https://discuss.circleci.com/t/workaround-auto-cancel-redundant-builds-on-the-default-branch/39468

set -x

## Get the name of the workflow and the related pipeline number
curl --header "Circle-Token: $PERS_API_TOKEN_BOOST_5" --request GET "https://circleci.com/api/v2/workflow/${CIRCLE_WORKFLOW_ID}" -o current_workflow.json
WF_NAME=$(jq -r '.name' current_workflow.json)
CURRENT_PIPELINE_NUM=$(jq -r '.pipeline_number' current_workflow.json)
CURRENT_PIPELINE_CREATED=$(jq -r '.created_at' current_workflow.json)
TIME_THRESHOLD=$(date --utc +'%Y-%m-%dT%TZ' -d "${CURRENT_PIPELINE_CREATED} -10 minutes")

## Get the IDs of pipelines created by the current user on the same branch. (Only consider pipelines that have a pipeline number inferior to the current pipeline)
PIPE_IDS=$(curl --header "Circle-Token: $PERS_API_TOKEN_BOOST_5" --request GET "https://circleci.com/api/v2/project/gh/$CIRCLE_PROJECT_USERNAME/$CIRCLE_PROJECT_REPONAME/pipeline?branch=$CIRCLE_BRANCH"|jq -r --argjson CURRENT_PIPELINE_NUM "$CURRENT_PIPELINE_NUM" --arg TIME_THRESHOLD "${TIME_THRESHOLD}" '.items[] | select(.state == "created") | select(.number < $CURRENT_PIPELINE_NUM) | select(.created_at > $TIME_THRESHOLD) | .id')

## Get the IDs of currently running/on_hold workflows that have the same name as the current workflow, in all previously created pipelines.
if [ ! -z "$PIPE_IDS" ]; then
for PIPE_ID in $PIPE_IDS
do
curl --header "Circle-Token: $PERS_API_TOKEN_BOOST_5" --request GET "https://circleci.com/api/v2/pipeline/${PIPE_ID}/workflow"|jq -r --arg WF_NAME "${WF_NAME}" '.items[]|select(.status == "on_hold" or .status == "running") | select(.name == $WF_NAME) | .id' >> WF_to_cancel.txt
done
fi

## Cancel any currently running/on_hold workflow with the same name
if [ -s WF_to_cancel.txt ]; then
echo "Cancelling the following workflow(s):"
cat WF_to_cancel.txt
while read WF_ID;
do
curl --header "Circle-Token: $PERS_API_TOKEN_BOOST_5" --request POST https://circleci.com/api/v2/workflow/$WF_ID/cancel
done < WF_to_cancel.txt
## Allowing some time to complete the cancellation
sleep 2
else
echo "Nothing to cancel"
fi
5 changes: 3 additions & 2 deletions third_party/boost/.circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
version: 2
version: 2.1
jobs:
build:
docker:
- image: cppalliance/boost_superproject_build:20.04-v4
- image: cppalliance/boost_superproject_build:22.04-v1
parallelism: 2
steps:
- checkout
- run: ./.circleci/autocancel.sh || true
- run: wget "https://raw.githubusercontent.com/boostorg/release-tools/master/ci_boost_common.py" -P ${HOME}
- run: wget "https://raw.githubusercontent.com/boostorg/release-tools/master/ci_boost_release.py" -P ${HOME}
- run: python3 ${HOME}/ci_boost_release.py checkout_post
Expand Down
8 changes: 4 additions & 4 deletions third_party/boost/.github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ jobs:
include:
- os: ubuntu-20.04
- os: ubuntu-22.04
- os: macos-11
- os: macos-12
- os: macos-13
- os: macos-14

runs-on: ${{matrix.os}}

Expand Down Expand Up @@ -88,9 +88,9 @@ jobs:
include:
- os: ubuntu-20.04
- os: ubuntu-22.04
- os: macos-11
- os: macos-12
- os: macos-13
- os: macos-14

runs-on: ${{matrix.os}}
timeout-minutes: 20
Expand Down Expand Up @@ -162,7 +162,7 @@ jobs:
- name: Configure Boost
run: |
mkdir __build__ && cd __build__
cmake -DBUILD_TESTING=ON -DBOOST_EXCLUDE_LIBRARIES="lockfree;outcome;process;static_string;url" ..
cmake -DBUILD_TESTING=ON -DBOOST_EXCLUDE_LIBRARIES="process;geometry" ..
- name: Build tests
run: |
Expand All @@ -181,9 +181,9 @@ jobs:
include:
- os: ubuntu-20.04
- os: ubuntu-22.04
- os: macos-11
- os: macos-12
- os: macos-13
- os: macos-14

runs-on: ${{matrix.os}}
timeout-minutes: 90
Expand Down
107 changes: 107 additions & 0 deletions third_party/boost/.github/workflows/commit-bot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,107 @@
name: Commit Bot

# To avoid infinite loops, don't trigger on "push"
on:
schedule:
- cron: "0,30 * * * *"

concurrency:
group: ${{format('commit-bot-{0}:{1}', github.repository, github.ref)}}
cancel-in-progress: true

jobs:
update-modules:
runs-on: ubuntu-latest
name: Commit Bot
if: github.repository == 'boostorg/boost'

steps:
- name: Check for module updates
id: branches
run: |
if [[ "${{ github.event_name }}" == "push" ]]; then
branches="${{ github.ref_name }}"
else
branches="master develop"
fi
echo "branches=$branches" >> $GITHUB_OUTPUT
- name: Checkout master repository
uses: actions/checkout@v4
if: contains(steps.branches.outputs.branches, 'master')
with:
ref: master
path: master
persist-credentials: false

- name: Checkout develop repository
uses: actions/checkout@v4
if: contains(steps.branches.outputs.branches, 'develop')
with:
ref: develop
path: develop
persist-credentials: false

- name: Check for module updates
run: |
branches="${{ steps.branches.outputs.branches }}"
# Set up Git
git config --global user.name "boost-commitbot"
git config --global user.email "[email protected]"
# Update each branch
for branch in $branches; do
cd $branch
module_paths=$(git config --file .gitmodules --get-regexp '^submodule\..*\.path$')
while IFS=' ' read -r key path; do
submodule_name=$(echo "$key" | awk -F '.' '{print $2}')
submodule_path=$(echo "$path")
url=$(git config --file .gitmodules --get-regexp "^submodule\.$submodule_name\.url$" | awk '{print $2}')
if [[ ! "$url" =~ ^https:// ]]; then
basicreponame=$(basename $url)
url=${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY_OWNER}/${basicreponame}
fi
hash=$(git ls-remote "$url" "refs/heads/$branch" | cut -f 1)
hash="${hash#"${hash%%[![:space:]]*}"}"
hash="${hash%"${hash##*[![:space:]]}"}"
commit_id="${hash:0:8}"
previous_hash=$(git ls-tree HEAD "$submodule_path" | awk '{print $3}')
previous_hash="${previous_hash#"${previous_hash%%[![:space:]]*}"}"
previous_hash="${previous_hash%"${previous_hash##*[![:space:]]}"}"
previous_commit_id="${previous_hash:0:8}"
if [ "$hash" == "$previous_hash" ]; then
echo "$submodule_name ($commit_id): OK"
else
echo "$submodule_name: $previous_commit_id -> $commit_id"
set -x
set +e
git submodule update --init "$submodule_path"
git submodule update --remote "$submodule_path"
git add "$submodule_path"
git commit -m "Update $submodule_name from $branch"
set -e
set +x
fi
done <<< "$module_paths"
cd ..
done
- name: Push changes from master
uses: ad-m/[email protected]
if: contains(steps.branches.outputs.branches, 'master')
with:
# github_token: ${{ secrets.GITHUB_TOKEN }}
github_token: ${{ secrets.CI_PAT }}
branch: master
directory: master

- name: Push changes from develop
uses: ad-m/[email protected]
if: contains(steps.branches.outputs.branches, 'develop')
with:
# github_token: ${{ secrets.GITHUB_TOKEN }}
github_token: ${{ secrets.CI_PAT }}
branch: develop
directory: develop

30 changes: 24 additions & 6 deletions third_party/boost/.github/workflows/release-cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,17 @@ jobs:
- name: Create archives
run: |
tar -czf ${{ github.ref_name }}-cmake.tar.gz ${{ github.ref_name }}
sha256sum ${{ github.ref_name }}-cmake.tar.gz > ${{ github.ref_name }}-cmake.tar.gz.txt
tar -cJf ${{ github.ref_name }}-cmake.tar.xz ${{ github.ref_name }}
sha256sum ${{ github.ref_name }}-cmake.tar.xz > ${{ github.ref_name }}-cmake.tar.xz.txt
- uses: softprops/action-gh-release@v1
- uses: softprops/action-gh-release@v2
with:
files: |
${{ github.ref_name }}-cmake.tar.gz
${{ github.ref_name }}-cmake.tar.gz.txt
${{ github.ref_name }}-cmake.tar.xz
${{ github.ref_name }}-cmake.tar.xz.txt
release-windows-cmake:
runs-on: windows-latest
Expand All @@ -51,13 +55,17 @@ jobs:
shell: cmd
run: |
7z a ${{ github.ref_name }}-cmake.zip ${{ github.ref_name }}
sha256sum ${{ github.ref_name }}-cmake.zip > ${{ github.ref_name }}-cmake.zip.txt
7z a ${{ github.ref_name }}-cmake.7z ${{ github.ref_name }}
sha256sum ${{ github.ref_name }}-cmake.7z > ${{ github.ref_name }}-cmake.7z.txt
- uses: softprops/action-gh-release@v1
- uses: softprops/action-gh-release@v2
with:
files: |
${{ github.ref_name }}-cmake.zip
${{ github.ref_name }}-cmake.zip.txt
${{ github.ref_name }}-cmake.7z
${{ github.ref_name }}-cmake.7z.txt
release-posix-b2-nodocs:
runs-on: ubuntu-latest
Expand All @@ -75,24 +83,29 @@ jobs:
run: |
find ${{ github.ref_name }} -name ".git" -prune -exec rm -rf {} +
- name: Move headers
- name: Move headers, remove docs
shell: bash
run: |
cd ${{ github.ref_name }}
cp -r libs/*/include/boost libs/numeric/*/include/boost .
rm -rf libs/*/include libs/numeric/*/include
rm -rf libs/*/doc libs/numeric/*/doc
rm -f CMakeLists.txt
- name: Create archives
run: |
tar -czf ${{ github.ref_name }}-b2-nodocs.tar.gz ${{ github.ref_name }}
sha256sum ${{ github.ref_name }}-b2-nodocs.tar.gz > ${{ github.ref_name }}-b2-nodocs.tar.gz.txt
tar -cJf ${{ github.ref_name }}-b2-nodocs.tar.xz ${{ github.ref_name }}
sha256sum ${{ github.ref_name }}-b2-nodocs.tar.xz > ${{ github.ref_name }}-b2-nodocs.tar.xz.txt
- uses: softprops/action-gh-release@v1
- uses: softprops/action-gh-release@v2
with:
files: |
${{ github.ref_name }}-b2-nodocs.tar.gz
${{ github.ref_name }}-b2-nodocs.tar.gz.txt
${{ github.ref_name }}-b2-nodocs.tar.xz
${{ github.ref_name }}-b2-nodocs.tar.xz.txt
release-windows-b2-nodocs:
runs-on: windows-latest
Expand All @@ -110,22 +123,27 @@ jobs:
run: |
find ${{ github.ref_name }} -name ".git" -prune -exec rm -rf {} +
- name: Move headers
- name: Move headers, remove docs
shell: bash
run: |
cd ${{ github.ref_name }}
cp -r libs/*/include/boost libs/numeric/*/include/boost .
rm -rf libs/*/include libs/numeric/*/include
rm -rf libs/*/doc libs/numeric/*/doc
rm -f CMakeLists.txt
- name: Create archives
shell: cmd
run: |
7z a ${{ github.ref_name }}-b2-nodocs.zip ${{ github.ref_name }}
sha256sum ${{ github.ref_name }}-b2-nodocs.zip > ${{ github.ref_name }}-b2-nodocs.zip.txt
7z a ${{ github.ref_name }}-b2-nodocs.7z ${{ github.ref_name }}
sha256sum ${{ github.ref_name }}-b2-nodocs.7z > ${{ github.ref_name }}-b2-nodocs.7z.txt
- uses: softprops/action-gh-release@v1
- uses: softprops/action-gh-release@v2
with:
files: |
${{ github.ref_name }}-b2-nodocs.zip
${{ github.ref_name }}-b2-nodocs.zip.txt
${{ github.ref_name }}-b2-nodocs.7z
${{ github.ref_name }}-b2-nodocs.7z.txt
2 changes: 1 addition & 1 deletion third_party/boost/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ if(CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR AND NOT CMAKE_BUILD_TYPE A
set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS "Debug" "Release" "MinSizeRel" "RelWithDebInfo")
endif()

project(Boost VERSION 1.85.0 LANGUAGES CXX)
project(Boost VERSION 1.86.0 LANGUAGES CXX)

set(BOOST_SUPERPROJECT_VERSION ${PROJECT_VERSION})
set(BOOST_SUPERPROJECT_SOURCE_DIR ${PROJECT_SOURCE_DIR})
Expand Down
Loading

0 comments on commit afe40ec

Please sign in to comment.