Skip to content

Commit 333c304

Browse files
authored
Add support for modular build structure. (#36)
* Make the library modular usable. * Switch to library requirements instead of source. As source puts extra source in install targets. * Add requires-b2 check to top-level build file. * Bump B2 require to 5.2 * Change all <source> references to <library>. * Update copyright dates. * Move inter-lib dependencies to a project variable and into the build targets. * Switch to /boost/test//included target for header only mode of Boost.Test. * Update build deps. * Add GHA CI with simpler working one based on alandefreitas/cpp-actions utilities. * Move project global include to target local include. * Only msvc gets minor version tests. * Remove GHA CI to undo move to cpp-actions.
1 parent 0c5348b commit 333c304

File tree

2 files changed

+34
-2
lines changed

2 files changed

+34
-2
lines changed

build.jam

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
# Copyright René Ferdinand Rivera Morell 2023-2024
2+
# Distributed under the Boost Software License, Version 1.0.
3+
# (See accompanying file LICENSE_1_0.txt or copy at
4+
# http://www.boost.org/LICENSE_1_0.txt)
5+
6+
require-b2 5.2 ;
7+
8+
constant boost_dependencies :
9+
/boost/array//boost_array
10+
/boost/assert//boost_assert
11+
/boost/concept_check//boost_concept_check
12+
/boost/config//boost_config
13+
/boost/core//boost_core
14+
/boost/functional//boost_functional
15+
/boost/iterator//boost_iterator
16+
/boost/mpl//boost_mpl
17+
/boost/static_assert//boost_static_assert
18+
/boost/type_traits//boost_type_traits ;
19+
20+
project /boost/multi_array
21+
;
22+
23+
explicit
24+
[ alias boost_multi_array : : :
25+
: <include>include <library>$(boost_dependencies) ]
26+
[ alias all : boost_multi_array test ]
27+
;
28+
29+
call-if : boost-library multi_array
30+
;

test/Jamfile.v2

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@
66

77
import testing ;
88

9+
project : requirements <library>/boost/multi_array//boost_multi_array ;
10+
911
compile-fail fail_cbracket.cpp ;
1012
compile-fail fail_cdata.cpp ;
1113
compile-fail fail_citerator.cpp ;
@@ -15,7 +17,7 @@ compile-fail fail_csubarray.cpp ;
1517
compile-fail fail_csubarray2.cpp ;
1618
compile-fail fail_csubarray3.cpp ;
1719
compile-fail fail_cview.cpp ;
18-
compile-fail fail_cview2.cpp ;
20+
compile-fail fail_cview2.cpp : <library>/boost/test//included ;
1921
compile-fail fail_cview3.cpp ;
2022
compile-fail fail_ref_cbracket.cpp ;
2123
compile-fail fail_ref_cdata.cpp ;
@@ -28,7 +30,7 @@ compile-fail fail_ref_csubarray3.cpp ;
2830
compile-fail fail_ref_cview.cpp ;
2931
compile-fail fail_ref_cview2.cpp ;
3032
compile-fail fail_ref_cview3.cpp ;
31-
33+
3234
run constructors.cpp ;
3335
run access.cpp ;
3436
run compare.cpp ;

0 commit comments

Comments
 (0)