mirror of
https://github.com/boostorg/thread.git
synced 2026-02-03 09:42:16 +00:00
Compare commits
18 Commits
boost-1.84
...
develop
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a1f89c9518 | ||
|
|
28d58852bb | ||
|
|
4e0a88853a | ||
|
|
5d68c9c42c | ||
|
|
b3183638cb | ||
|
|
48482ff696 | ||
|
|
76411e5918 | ||
|
|
49ccf9c30a | ||
|
|
814ed9f341 | ||
|
|
82aa252a9e | ||
|
|
b1ff784e51 | ||
|
|
e6e4e53807 | ||
|
|
0fc00ec05c | ||
|
|
435a623e48 | ||
|
|
ca4b54f96c | ||
|
|
43bfe9cbd2 | ||
|
|
691b64d5aa | ||
|
|
e2de571359 |
55
.github/workflows/ci.yml
vendored
55
.github/workflows/ci.yml
vendored
@@ -18,52 +18,71 @@ jobs:
|
||||
matrix:
|
||||
include:
|
||||
- toolset: gcc-4.8
|
||||
os: ubuntu-latest
|
||||
container: ubuntu:18.04
|
||||
cxxstd: 11
|
||||
container: ubuntu:18.04
|
||||
os: ubuntu-latest
|
||||
install: g++-4.8
|
||||
- toolset: gcc-5
|
||||
cxxstd: 11
|
||||
os: ubuntu-latest
|
||||
container: ubuntu:18.04
|
||||
os: ubuntu-latest
|
||||
install: g++-5
|
||||
- toolset: gcc-7
|
||||
os: ubuntu-20.04
|
||||
install: g++-7
|
||||
container: ubuntu:18.04
|
||||
os: ubuntu-latest
|
||||
- toolset: gcc-9
|
||||
os: ubuntu-20.04
|
||||
container: ubuntu:20.04
|
||||
os: ubuntu-latest
|
||||
- toolset: gcc-11
|
||||
os: ubuntu-22.04
|
||||
- toolset: gcc-13
|
||||
os: ubuntu-24.04
|
||||
- toolset: clang
|
||||
container: ubuntu:20.04
|
||||
os: ubuntu-latest
|
||||
install: clang
|
||||
- toolset: clang
|
||||
compiler: clang++-15
|
||||
cxxstd: 20
|
||||
os: ubuntu-22.04
|
||||
install: clang-15
|
||||
- toolset: clang
|
||||
os: macos-11
|
||||
cxxstd: 11
|
||||
- toolset: clang
|
||||
os: macos-12
|
||||
cxxstd: 14
|
||||
cxxstd: 20
|
||||
os: ubuntu-24.04
|
||||
- toolset: clang
|
||||
os: macos-13
|
||||
cxxstd: 11
|
||||
- toolset: clang
|
||||
os: macos-14
|
||||
cxxstd: 14
|
||||
- toolset: clang
|
||||
os: macos-15
|
||||
cxxstd: 17
|
||||
|
||||
runs-on: ${{matrix.os}}
|
||||
container: ${{matrix.container}}
|
||||
|
||||
container:
|
||||
image: ${{matrix.container}}
|
||||
volumes:
|
||||
- /node20217:/node20217:rw,rshared
|
||||
- ${{ startsWith(matrix.container, 'ubuntu:1') && '/node20217:/__e/node20:ro,rshared' || ' ' }}
|
||||
|
||||
defaults:
|
||||
run:
|
||||
shell: bash
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- name: Setup container environment
|
||||
if: matrix.container
|
||||
run: |
|
||||
apt-get update
|
||||
apt-get -y install sudo python3 git g++
|
||||
apt-get -y install sudo python3 git g++ curl xz-utils
|
||||
|
||||
- name: Install nodejs20glibc2.17
|
||||
if: ${{ startsWith( matrix.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
|
||||
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Install packages
|
||||
if: matrix.install
|
||||
|
||||
46
build.jam
Normal file
46
build.jam
Normal file
@@ -0,0 +1,46 @@
|
||||
# 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/assert//boost_assert
|
||||
/boost/atomic//boost_atomic
|
||||
/boost/bind//boost_bind
|
||||
/boost/chrono//boost_chrono
|
||||
/boost/concept_check//boost_concept_check
|
||||
/boost/config//boost_config
|
||||
/boost/container//boost_container
|
||||
/boost/container_hash//boost_container_hash
|
||||
/boost/core//boost_core
|
||||
/boost/date_time//boost_date_time
|
||||
/boost/exception//boost_exception
|
||||
/boost/function//boost_function
|
||||
/boost/io//boost_io
|
||||
/boost/move//boost_move
|
||||
/boost/optional//boost_optional
|
||||
/boost/predef//boost_predef
|
||||
/boost/preprocessor//boost_preprocessor
|
||||
/boost/smart_ptr//boost_smart_ptr
|
||||
/boost/static_assert//boost_static_assert
|
||||
/boost/system//boost_system
|
||||
/boost/throw_exception//boost_throw_exception
|
||||
/boost/tuple//boost_tuple
|
||||
/boost/type_traits//boost_type_traits
|
||||
/boost/utility//boost_utility
|
||||
/boost/winapi//boost_winapi ;
|
||||
|
||||
project /boost/thread
|
||||
;
|
||||
|
||||
explicit
|
||||
[ alias boost_thread : build//boost_thread ]
|
||||
[ alias all : boost_thread example test ]
|
||||
;
|
||||
|
||||
call-if : boost-library thread
|
||||
: install boost_thread
|
||||
;
|
||||
|
||||
@@ -35,18 +35,22 @@
|
||||
import os ;
|
||||
import indirect ;
|
||||
import path ;
|
||||
import configure ;
|
||||
import configure ;
|
||||
import threadapi-feature ;
|
||||
|
||||
exe has_atomic_flag_lockfree : ../build/has_atomic_flag_lockfree_test.cpp ;
|
||||
|
||||
project boost/thread
|
||||
project
|
||||
: source-location ../src
|
||||
: common-requirements
|
||||
<library>$(boost_dependencies)
|
||||
<include>../include
|
||||
: requirements <threading>multi
|
||||
#<link>static:<define>BOOST_THREAD_STATIC_LINK=1
|
||||
#<link>shared:<define>BOOST_THREAD_DYN_LINK=1
|
||||
<link>static:<define>BOOST_THREAD_BUILD_LIB=1
|
||||
<link>shared:<define>BOOST_THREAD_BUILD_DLL=1
|
||||
-<tag>@%boostcpp.tag
|
||||
-<tag>@$(BOOST_JAMROOT_MODULE)%$(BOOST_JAMROOT_MODULE).tag
|
||||
<tag>@$(__name__).tag
|
||||
<toolset>gcc:<cxxflags>-Wno-long-long
|
||||
@@ -139,6 +143,7 @@ project boost/thread
|
||||
#<define>BOOST_THREAD_THROW_IF_PRECONDITION_NOT_SATISFIED
|
||||
#<define>BOOST_SYSTEM_NO_DEPRECATED
|
||||
#<define>BOOST_THREAD_DONT_PROVIDE_INTERRUPTIONS
|
||||
<define>BOOST_THREAD_NO_LIB=1
|
||||
;
|
||||
|
||||
rule tag ( name : type ? : property-set )
|
||||
@@ -156,8 +161,15 @@ rule tag ( name : type ? : property-set )
|
||||
}
|
||||
|
||||
# forward to the boost tagging rule
|
||||
return [ indirect.call $(BOOST_JAMROOT_MODULE)%$(BOOST_JAMROOT_MODULE).tag
|
||||
$(result) : $(type) : $(property-set) ] ;
|
||||
if $(BOOST_JAMROOT_MODULE)
|
||||
{
|
||||
return [ indirect.call $(BOOST_JAMROOT_MODULE)%$(BOOST_JAMROOT_MODULE).tag
|
||||
$(result) : $(type) : $(property-set) ] ;
|
||||
}
|
||||
else
|
||||
{
|
||||
return $(result) ;
|
||||
}
|
||||
}
|
||||
|
||||
rule win32_pthread_paths ( properties * )
|
||||
@@ -269,10 +281,10 @@ rule requirements ( properties * )
|
||||
}
|
||||
}
|
||||
result += <define>BOOST_THREAD_DONT_USE_CHRONO ;
|
||||
if ! [ configure.builds has_atomic_flag_lockfree
|
||||
: $(properties) : "lockfree boost::atomic_flag" ] {
|
||||
result += <library>/boost/atomic//boost_atomic ;
|
||||
}
|
||||
if ! [ configure.builds has_atomic_flag_lockfree
|
||||
: $(properties) : "lockfree boost::atomic_flag" ] {
|
||||
result += <library>/boost/atomic//boost_atomic ;
|
||||
}
|
||||
} else {
|
||||
if <threadapi>win32 in $(properties)
|
||||
{
|
||||
@@ -315,5 +327,3 @@ lib boost_thread
|
||||
<link>static:<define>BOOST_THREAD_USE_LIB=1
|
||||
<conditional>@usage-requirements
|
||||
;
|
||||
|
||||
boost-install boost_thread ;
|
||||
@@ -4,7 +4,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)
|
||||
|
||||
project boost/thread/example
|
||||
project
|
||||
: requirements <library>../build//boost_thread <threading>multi
|
||||
;
|
||||
|
||||
|
||||
@@ -4668,7 +4668,7 @@ namespace detail
|
||||
}
|
||||
run_it& operator=(BOOST_THREAD_RV_REF(run_it) x) BOOST_NOEXCEPT {
|
||||
if (this != &x) {
|
||||
that_=x.that;
|
||||
that_=x.that_;
|
||||
x.that_.reset();
|
||||
}
|
||||
return *this;
|
||||
|
||||
@@ -268,16 +268,15 @@ rule generate_self_contained_header_tests
|
||||
|
||||
if ! [ os.environ BOOST_THREAD_TEST_WITHOUT_SELF_CONTAINED_HEADER_TESTS ]
|
||||
{
|
||||
local headers_path = [ path.make $(BOOST_ROOT)/libs/thread/include/boost/thread ] ;
|
||||
for file in [ path.glob-tree $(headers_path) : *.hpp : detail pthread win32 ]
|
||||
for file in [ glob-tree-ex ../include/boost/thread : *.hpp : detail pthread win32 ]
|
||||
{
|
||||
local rel_file = [ path.relative-to $(headers_path) $(file) ] ;
|
||||
local rel_file = [ path.relative-to ../include/boost/thread $(file) ] ;
|
||||
# Note: The test name starts with '~' in order to group these tests in the test report table, preferably at the end.
|
||||
# All '/' are replaced with '-' because apparently test scripts have a problem with test names containing slashes.
|
||||
local test_name = [ regex.replace ~hdr/$(rel_file) "/" "-" ] ;
|
||||
#ECHO $(rel_file) ;
|
||||
all_rules += [ compile self_contained_header.cpp : <define>"BOOST_THREAD_TEST_HEADER=$(rel_file)" <dependency>$(file) : $(test_name) ] ;
|
||||
all_rules += [ compile self_contained_header.cpp : <define>"BOOST_THREAD_TEST_HEADER=$(rel_file)" <define>"BOOST_THREAD_TEST_POST_WINDOWS_H" <dependency>$(file) <conditional>@windows-cygwin-specific : $(test_name)-post_winh ] ;
|
||||
all_rules += [ compile self_contained_header.cpp : <define>"BOOST_THREAD_TEST_HEADER=$(rel_file)" <dependency>$(file) <use>../build//boost_thread : $(test_name) ] ;
|
||||
all_rules += [ compile self_contained_header.cpp : <define>"BOOST_THREAD_TEST_HEADER=$(rel_file)" <define>"BOOST_THREAD_TEST_POST_WINDOWS_H" <dependency>$(file) <conditional>@windows-cygwin-specific <use>../build//boost_thread : $(test_name)-post_winh ] ;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1012,7 +1011,7 @@ rule generate_self_contained_header_tests
|
||||
#[ thread-run test_10128.cpp ]
|
||||
#[ thread-run test_10340.cpp ]
|
||||
;
|
||||
|
||||
|
||||
explicit ts_more_cpp11 ;
|
||||
test-suite ts_more_cpp11
|
||||
:
|
||||
@@ -1033,13 +1032,13 @@ rule generate_self_contained_header_tests
|
||||
:
|
||||
[ thread-run2-noit ./experimental/parallel/v1/exception_list_pass.cpp : exception_list_p ]
|
||||
;
|
||||
|
||||
|
||||
#explicit ts_task_region ;
|
||||
test-suite ts_task_region
|
||||
:
|
||||
[ thread-run2-noit ./experimental/parallel/v2/task_region_pass.cpp : task_region_p ]
|
||||
;
|
||||
|
||||
|
||||
explicit ts_other ;
|
||||
test-suite ts_other
|
||||
:
|
||||
@@ -1050,7 +1049,7 @@ rule generate_self_contained_header_tests
|
||||
explicit ts_ ;
|
||||
test-suite ts_
|
||||
:
|
||||
#[ thread-run test_11256.cpp ]
|
||||
#[ thread-run test_11256.cpp ]
|
||||
#[ thread-run test_11256.cpp ]
|
||||
#[ thread-run test_11499.cpp ]
|
||||
#[ thread-run test_11611.cpp ]
|
||||
@@ -1060,7 +1059,7 @@ rule generate_self_contained_header_tests
|
||||
#[ thread-run test_12949.cpp ]
|
||||
#[ thread-run test_13480b.cpp ]
|
||||
[ thread-run test_13561.cpp ]
|
||||
|
||||
|
||||
;
|
||||
|
||||
explicit test_time_jumps_1_obj ;
|
||||
|
||||
Reference in New Issue
Block a user