2
0
mirror of https://github.com/boostorg/process.git synced 2026-01-20 04:42:24 +00:00

Compare commits

...

4 Commits

Author SHA1 Message Date
Jackarain
9561ebad1c Fix mingw cross-compile 2024-07-31 08:19:56 +08:00
Klemens Morgenstern
755a3ec78d fixed dll symbokl export on windows & clean up jamfile. 2024-07-24 10:12:10 +08:00
Klemens Morgenstern
5f80218655 added CLOSE_RANGE_UNSHARE defined for syscall of close_range. 2024-07-20 08:25:10 +08:00
Ruben Perez
3719df39cd Alpine-Linux CI 2024-07-20 08:25:10 +08:00
7 changed files with 51 additions and 11 deletions

View File

@@ -141,6 +141,43 @@ jobs:
cd ../boost-root
./b2 -j3 libs/$LIBRARY/test toolset=${{matrix.toolset}} cxxstd=${{matrix.cxxstd}} variant=debug,release
alpine-linux:
runs-on: ubuntu-latest
container:
image: alpine:3.20.1
steps:
- name: Install packages
run: apk add g++ git python3 linux-headers
- uses: actions/checkout@v4
- name: Setup Boost
run: |
echo GITHUB_REPOSITORY: $GITHUB_REPOSITORY
LIBRARY=${GITHUB_REPOSITORY#*/}
echo LIBRARY: $LIBRARY
echo "LIBRARY=$LIBRARY" >> $GITHUB_ENV
echo GITHUB_BASE_REF: $GITHUB_BASE_REF
echo GITHUB_REF: $GITHUB_REF
REF=${GITHUB_BASE_REF:-$GITHUB_REF}
REF=${REF#refs/heads/}
echo REF: $REF
BOOST_BRANCH=develop && [ "$REF" == "master" ] && BOOST_BRANCH=master || true
echo BOOST_BRANCH: $BOOST_BRANCH
cd ..
git clone -b $BOOST_BRANCH --depth 1 https://github.com/boostorg/boost.git boost-root
cd boost-root
cp -r $GITHUB_WORKSPACE/* libs/$LIBRARY
git submodule update --init tools/boostdep
python3 tools/boostdep/depinst/depinst.py --git_args "--jobs 3" $LIBRARY
./bootstrap.sh
./b2 -d0 headers
- name: Run tests
run: |
cd ../boost-root
./b2 -j3 libs/$LIBRARY/test toolset=gcc cxxstd=23 variant=debug,release
windows:
strategy:
fail-fast: false

View File

@@ -57,7 +57,7 @@ else()
endif()
if (WIN32)
target_link_libraries(boost_process PUBLIC ntdll shell32 Advapi32 user32)
target_link_libraries(boost_process PUBLIC ntdll shell32 advapi32 user32)
endif()
if(BUILD_SHARED_LIBS)

View File

@@ -43,9 +43,10 @@ alias process_sources
if [ os.name ] = NT
{
lib shell32 ;
lib Advapi32 ;
lib Ntdll ;
lib advapi32 ;
lib ntdll ;
lib user32 ;
explicit shell32 advapi32 ntdll user32 ;
}
lib boost_process
@@ -55,11 +56,10 @@ lib boost_process
<boost.process.fs>boost:<library>/boost//filesystem
<target-os>windows:<library>shell32
<target-os>windows:<library>user32
<target-os>windows:<library>Ntdll
<target-os>windows:<library>Advapi32
<target-os>windows:<library>ntdll
<target-os>windows:<library>advapi32
: usage-requirements
<link>shared:<define>BOOST_PROCESS_DYN_LINK=1
<boost.process.fs>boost:<library>/boost//filesystem
;
boost-install boost_process ;
boost-install boost_process ;

View File

@@ -63,7 +63,6 @@ doxygen reference_v2
\"BOOST_PROCESS_V2_END_NAMESPACE= } } }\" \\
BOOST_PROCESS_V2_NAMESPACE=boost::process::v2 \\
BOOST_PROCESS_V2_DECL \\
BOOST_PROCESS_V2_SOURCE \\
BOOST_PROCESS_V2_INITFN_AUTO_RESULT_TYPE(x,y)=deduced \\
BOOST_PROCESS_V2_COMPLETION_TOKEN_FOR(X)=Token \\
BOOST_PROCESS_V2_DEFAULT_COMPLETION_TOKEN_TYPE(E)=DEFAULT_TYPE \\

View File

@@ -154,8 +154,8 @@ namespace filesystem = boost::filesystem;
BOOST_PROCESS_V2_END_NAMESPACE
#if defined(BOOST_ALL_DYN_LINK) || defined(BOOST_PROCESS_V2_DYN_LINK)
#if defined(BOOST_PROCESS_V2_SOURCE)
#if defined(BOOST_ALL_DYN_LINK) || defined(BOOST_PROCESS_DYN_LINK)
#if defined(BOOST_PROCESS_SOURCE)
#define BOOST_PROCESS_V2_DECL BOOST_SYMBOL_EXPORT
#else
#define BOOST_PROCESS_V2_DECL BOOST_SYMBOL_IMPORT

View File

@@ -9,7 +9,7 @@
#include <boost/process/v2/error.hpp>
#if defined(BOOST_PROCESS_V2_WINDOWS)
#include <Windows.h>
#include <windows.h>
#endif
BOOST_PROCESS_V2_BEGIN_NAMESPACE

View File

@@ -60,6 +60,10 @@ int fdwalk(int (*func)(void *, int), void *cd);
#if defined(SYS_close_range)
#define BOOST_PROCESS_V2_HAS_CLOSE_RANGE 1
#if !defined(CLOSE_RANGE_UNSHARE)
#define CLOSE_RANGE_UNSHARE 2
#endif
int close_range(unsigned int first, unsigned int last, int flags)
{
return ::syscall(SYS_close_range, first, last, flags);