mirror of
https://github.com/boostorg/beast.git
synced 2025-06-25 03:51:36 +02:00
193 lines
5.5 KiB
Plaintext
193 lines
5.5 KiB
Plaintext
#
|
|
# Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com)
|
|
#
|
|
# 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)
|
|
#
|
|
# Official repository: https://github.com/boostorg/beast
|
|
#
|
|
|
|
import ac ;
|
|
import-search /boost/config/checks ;
|
|
import config : requires ;
|
|
import os ;
|
|
import testing ;
|
|
|
|
using openssl ;
|
|
|
|
explicit
|
|
[ searched-lib socket ] # SOLARIS, QNXNTO
|
|
[ searched-lib nsl ] # SOLARIS
|
|
[ searched-lib ws2_32 : : <target-os>windows ] # NT
|
|
[ searched-lib mswsock : : <target-os>windows ] # NT
|
|
[ searched-lib ipv6 ] # HPUX
|
|
[ searched-lib network ] # HAIKU
|
|
;
|
|
|
|
local requirements =
|
|
<library>$(boost_dependencies)
|
|
[ requires
|
|
cxx11_constexpr
|
|
cxx11_decltype
|
|
cxx11_hdr_tuple
|
|
cxx11_template_aliases
|
|
cxx11_variadic_templates
|
|
]
|
|
<define>BOOST_ALL_NO_LIB=1
|
|
<define>BOOST_ASIO_SEPARATE_COMPILATION
|
|
<define>BOOST_ASIO_NO_DEPRECATED=1
|
|
<define>BOOST_ASIO_DISABLE_BOOST_ARRAY=1
|
|
<define>BOOST_ASIO_DISABLE_BOOST_BIND=1
|
|
<define>BOOST_ASIO_DISABLE_BOOST_DATE_TIME=1
|
|
<define>BOOST_ASIO_DISABLE_BOOST_REGEX=1
|
|
<define>BOOST_COROUTINES_NO_DEPRECATION_WARNING=1
|
|
<toolset>msvc:<cxxflags>"/bigobj"
|
|
<toolset>msvc-14.1:<cxxflags>"/permissive-"
|
|
<toolset>msvc-14.2:<cxxflags>"/permissive-"
|
|
<toolset>msvc:<define>_SCL_SECURE_NO_WARNINGS=1
|
|
<toolset>msvc:<define>_CRT_SECURE_NO_WARNINGS=1
|
|
<toolset>msvc:<define>_SILENCE_CXX17_ALLOCATOR_VOID_DEPRECATION_WARNING
|
|
<toolset>msvc:<define>_SILENCE_CXX17_ADAPTOR_TYPEDEFS_DEPRECATION_WARNING
|
|
<toolset>msvc,<variant>release:<cxxflags>"/Ob2 /Oi /Ot"
|
|
<target-os>linux:<define>_XOPEN_SOURCE=600
|
|
<target-os>linux:<define>_GNU_SOURCE=1
|
|
<target-os>solaris:<define>_XOPEN_SOURCE=500
|
|
<target-os>solaris:<define>__EXTENSIONS__
|
|
<target-os>solaris:<library>socket
|
|
<target-os>solaris:<library>nsl
|
|
<target-os>windows:<define>_WIN32_WINNT=0x0601
|
|
<target-os>windows,<toolset>gcc:<library>ws2_32
|
|
<target-os>windows,<toolset>gcc:<library>mswsock
|
|
<target-os>windows,<toolset>gcc-cygwin:<define>__USE_W32_SOCKETS
|
|
<target-os>hpux,<toolset>gcc:<define>_XOPEN_SOURCE_EXTENDED
|
|
<target-os>hpux:<library>ipv6
|
|
<target-os>qnxnto:<library>socket
|
|
<target-os>haiku:<library>network
|
|
<boost.beast.valgrind>on:<define>BOOST_USE_VALGRIND
|
|
<boost.beast.allow-deprecated>on:<define>BOOST_BEAST_ALLOW_DEPRECATED
|
|
<boost.beast.separate-compilation>on:<define>BOOST_BEAST_SEPARATE_COMPILATION
|
|
;
|
|
|
|
lib lib-asio
|
|
: lib_asio.cpp
|
|
: requirements
|
|
$(requirements)
|
|
<link>static
|
|
: usage-requirements
|
|
$(requirements)
|
|
;
|
|
|
|
lib lib-asio-ssl
|
|
: lib_asio_ssl.cpp
|
|
: requirements
|
|
$(requirements)
|
|
<link>static
|
|
[ ac.check-library /openssl//ssl : <library>/openssl//ssl/<link>shared : <build>no ]
|
|
[ ac.check-library /openssl//crypto : <library>/openssl//crypto/<link>shared : <build>no ]
|
|
: usage-requirements
|
|
$(requirements)
|
|
[ ac.check-library /openssl//ssl : <library>/openssl//ssl/<link>shared : <build>no ]
|
|
[ ac.check-library /openssl//crypto : <library>/openssl//crypto/<link>shared : <build>no ]
|
|
;
|
|
|
|
lib lib-beast
|
|
: lib_beast.cpp
|
|
: requirements
|
|
$(requirements)
|
|
<link>static
|
|
: usage-requirements
|
|
$(requirements)
|
|
;
|
|
|
|
variant beast_coverage
|
|
: debug
|
|
: <cxxflags>"-msse4.2 --coverage"
|
|
<linkflags>"--coverage"
|
|
;
|
|
|
|
variant beast_valgrind
|
|
: release
|
|
: <boost.beast.valgrind>on
|
|
;
|
|
|
|
variant beast_ubasan
|
|
: release
|
|
: <cxxflags>"-msse4.2 -funsigned-char -fno-omit-frame-pointer -fsanitize=address,undefined -fno-sanitize-recover=address,undefined -fsanitize-blacklist=libs/beast/tools/blacklist.supp"
|
|
<linkflags>"-fsanitize=address,undefined"
|
|
<define>BOOST_USE_ASAN=1
|
|
;
|
|
|
|
project /boost/beast/test
|
|
: default-build
|
|
<warnings>extra
|
|
: requirements
|
|
[ requires
|
|
cxx11_constexpr
|
|
cxx11_decltype
|
|
cxx11_hdr_tuple
|
|
#cxx11_sfinae_expr # Every MSVC fails this
|
|
cxx11_template_aliases
|
|
cxx11_variadic_templates
|
|
]
|
|
<define>BOOST_BEAST_TESTS
|
|
<threading>multi
|
|
<target-os>darwin:<define>Z_HAVE_UNISTD_H=1
|
|
<library>/boost/beast/test//lib-asio/<link>static
|
|
<boost.beast.separate-compilation>on:<library>/boost/beast/test//lib-beast/<link>static
|
|
<library>/boost/filesystem//boost_filesystem/<link>static
|
|
<library>/boost/context//boost_context/<link>static
|
|
<address-sanitizer>norecover:<context-impl>ucontext
|
|
<address-sanitizer>norecover:<define>BOOST_USE_ASAN=1
|
|
<include>..
|
|
;
|
|
|
|
lib lib-test
|
|
: lib_test.cpp
|
|
: requirements
|
|
<link>static
|
|
: usage-requirements
|
|
<include>extras/include
|
|
;
|
|
|
|
lib lib-zlib :
|
|
extern/zlib-1.2.12/adler32.c
|
|
extern/zlib-1.2.12/compress.c
|
|
extern/zlib-1.2.12/crc32.c
|
|
extern/zlib-1.2.12/deflate.c
|
|
extern/zlib-1.2.12/infback.c
|
|
extern/zlib-1.2.12/inffast.c
|
|
extern/zlib-1.2.12/inflate.c
|
|
extern/zlib-1.2.12/inftrees.c
|
|
extern/zlib-1.2.12/trees.c
|
|
extern/zlib-1.2.12/uncompr.c
|
|
extern/zlib-1.2.12/zutil.c
|
|
: requirements
|
|
<warnings>off
|
|
<link>static
|
|
: usage-requirements
|
|
<include>./extern
|
|
;
|
|
|
|
alias run-tests :
|
|
beast//run-tests
|
|
bench//run-tests
|
|
doc//run-tests
|
|
example//run-tests
|
|
;
|
|
|
|
alias fat-tests :
|
|
beast//fat-tests
|
|
doc//fat-tests
|
|
example//fat-tests
|
|
;
|
|
|
|
explicit fat-tests ;
|
|
|
|
alias run-fat-tests :
|
|
beast//run-fat-tests
|
|
doc//run-fat-tests
|
|
example//run-fat-tests
|
|
;
|
|
|
|
explicit run-fat-tests ;
|