mirror of
https://github.com/boostorg/process.git
synced 2026-01-19 04:22:15 +00:00
Added BOOST_PROCESS_V2_POSIX_FORCE_DISABLE_CLOSE_RANGE
Implements #378.
This commit is contained in:
@@ -8,6 +8,7 @@ require-b2 5.2 ;
|
||||
import feature : feature ;
|
||||
|
||||
feature boost.process.fs : boost std : optional propagated ;
|
||||
feature boost.process.disable-close-range : on off : optional ;
|
||||
|
||||
constant boost_dependencies :
|
||||
/boost/algorithm//boost_algorithm
|
||||
|
||||
@@ -52,6 +52,7 @@ lib boost_process
|
||||
: requirements <define>BOOST_PROCESS_SOURCE=1
|
||||
<link>shared:<define>BOOST_PROCESS_DYN_LINK=1
|
||||
<boost.process.fs>boost:<library>/boost/filesystem//boost_filesystem
|
||||
<boost.process.disable-close-range>on:<define>BOOST_PROCESS_V2_POSIX_FORCE_DISABLE_CLOSE_RANGE=1
|
||||
<target-os>windows:<library>shell32
|
||||
<target-os>windows:<library>user32
|
||||
<target-os>windows:<library>ntdll
|
||||
|
||||
@@ -44,7 +44,8 @@ int fdwalk(int (*func)(void *, int), void *cd);
|
||||
|
||||
#include <linux/version.h>
|
||||
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,11,0) // kernel has close_range
|
||||
// kernel has close_range
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,9,0) && !defined(BOOST_PROCESS_V2_POSIX_FORCE_DISABLE_CLOSE_RANGE)
|
||||
|
||||
// version is included by stdlib.h #include <gnu/libc-version.h>
|
||||
#if (__GLIBC__ >= 2 && __GLIBC_MINOR__ >= 34) // glibc is compiled with close_range support
|
||||
|
||||
Reference in New Issue
Block a user