Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for modular build structure. #434

Open
wants to merge 13 commits into
base: develop
Choose a base branch
from
32 changes: 32 additions & 0 deletions build.jam
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# 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/align//boost_align
/boost/assert//boost_assert
/boost/config//boost_config
/boost/context//boost_context
/boost/coroutine//boost_coroutine
/boost/date_time//boost_date_time
/boost/system//boost_system
/boost/throw_exception//boost_throw_exception ;

project /boost/asio
: common-requirements
<include>include
;

local examples = [ glob-tree-ex example : Jamfile.v2 ] ;

explicit
[ alias boost_asio : : : : <library>$(boost_dependencies) ]
[ alias all : boost_asio test $(examples:D) ]
;

call-if : boost-library asio
;

11 changes: 11 additions & 0 deletions example/cpp11/build.jam
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# 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)

project
: requirements
<library>/boost/asio//boost_asio
<cxxstd>11
;
6 changes: 3 additions & 3 deletions example/cpp11/files/Jamfile.v2
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
# file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
#

lib uring ; # LINUX
lib ws2_32 ; # NT
lib mswsock ; # NT
searched-lib uring ; # LINUX
searched-lib ws2_32 ; # NT
searched-lib mswsock ; # NT

project
: requirements
Expand Down
15 changes: 3 additions & 12 deletions example/cpp11/ssl/Jamfile.v2
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,7 @@ lib mswsock ; # NT
lib ipv6 ; # HPUX
lib network ; # HAIKU

if [ os.name ] = NT
{
lib ssl : : <name>ssleay32 ;
lib crypto : : <name>libeay32 ;
}
else
{
lib ssl ;
lib crypto ;
}
using openssl ;

project
: requirements
Expand All @@ -40,8 +31,8 @@ project
<target-os>hpux,<toolset>gcc:<define>_XOPEN_SOURCE_EXTENDED
<target-os>hpux:<library>ipv6
<target-os>haiku:<library>network
<library>ssl
<library>crypto
<library>/openssl//ssl
<library>/openssl//crypto
;

exe client : client.cpp ;
Expand Down
2 changes: 2 additions & 0 deletions example/cpp11/windows/Jamfile.v2
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ exe transmit_file
/boost/chrono//boost_chrono
: <define>BOOST_ALL_NO_LIB=1
<threading>multi
<build>no
<target-os>windows:<build>yes
<target-os>solaris:<library>socket
<target-os>solaris:<library>nsl
<target-os>windows:<define>_WIN32_WINNT=0x0501
Expand Down
11 changes: 11 additions & 0 deletions example/cpp14/build.jam
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# 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)

project
: requirements
<library>/boost/asio//boost_asio
<cxxstd>14
;
1 change: 1 addition & 0 deletions example/cpp14/parallel_group/Jamfile.v2
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ project
: requirements
<library>/boost/system//boost_system
<library>/boost/chrono//boost_chrono
<library>/boost/thread//boost_thread
<define>BOOST_ALL_NO_LIB=1
<threading>multi
<target-os>solaris:<library>socket
Expand Down
11 changes: 11 additions & 0 deletions example/cpp17/build.jam
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# 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)

project
: requirements
<library>/boost/asio//boost_asio
<cxxstd>17
;
11 changes: 11 additions & 0 deletions example/cpp20/build.jam
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# 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)

project
: requirements
<library>/boost/asio//boost_asio
<cxxstd>20
;
3 changes: 1 addition & 2 deletions test/Jamfile.v2
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,7 @@ local USE_SELECT =

project
: requirements
<library>/boost/date_time//boost_date_time
<library>/boost/system//boost_system
<library>/boost/asio//boost_asio
<library>/boost/chrono//boost_chrono
<library>/boost/regex//boost_regex
<define>BOOST_ALL_NO_LIB=1
Expand Down