Imported Upstream version 1.72.0
[platform/upstream/boost.git] / libs / context / test / Jamfile.v2
1 # Boost.Context Library Tests Jamfile
2
3 #          Copyright Oliver Kowalke 2009.
4 # Distributed under the Boost Software License, Version 1.0.
5 #    (See accompanying file LICENSE_1_0.txt or copy at
6 #          http://www.boost.org/LICENSE_1_0.txt)
7
8 import common ;
9 import feature ;
10 import indirect ;
11 import modules ;
12 import os ;
13 import testing ;
14 import toolset ;
15 import ../../config/checks/config : requires ;
16
17 project boost/context/test
18     : requirements
19       <library>../../test/build//boost_unit_test_framework
20       <library>/boost/context//boost_context
21       <toolset>gcc,<segmented-stacks>on:<cxxflags>-fsplit-stack
22       <toolset>gcc,<segmented-stacks>on:<cxxflags>-DBOOST_USE_SEGMENTED_STACKS
23       <toolset>clang,<segmented-stacks>on:<cxxflags>-fsplit-stack
24       <toolset>clang,<segmented-stacks>on:<cxxflags>-DBOOST_USE_SEGMENTED_STACKS
25       <link>static
26       <threading>multi
27       <variant>release
28     ;
29
30
31 rule native-impl ( properties * )
32 {
33     local result  ;
34     if ( <target-os>android in $(properties) ||
35          <target-os>darwin in $(properties) ||
36          <target-os>openbsd in $(properties) )
37     {
38         result = <build>no ;
39     }
40     else if ( ! ( <target-os>windows in $(properties) ) )
41     {
42         result = <context-impl>ucontext ;
43     }
44     else
45     {
46         result = <context-impl>winfib ;
47     }
48     return $(result) ;
49 }
50
51 rule segmented-stack ( properties * )
52 {
53     local result  ;
54     if ( <toolset>gcc in $(properties) )
55     {
56         result = <segmented-stacks>on ;
57     }
58     else
59     {
60         result = <build>no ;
61     }
62     return $(result) ;
63 }
64
65 test-suite minimal :
66 [ run test_invoke.cpp :
67     : :
68     [ requires cxx11_auto_declarations
69                cxx11_constexpr
70                cxx11_defaulted_functions
71                cxx11_final
72                cxx11_hdr_thread
73                cxx11_hdr_tuple
74                cxx11_lambdas
75                cxx11_noexcept
76                cxx11_nullptr
77                cxx11_rvalue_references
78                cxx11_template_aliases
79                cxx11_thread_local
80                cxx11_variadic_templates ] ]
81
82 [ run test_apply.cpp :
83     : :
84     [ requires cxx11_auto_declarations
85                cxx11_constexpr
86                cxx11_defaulted_functions
87                cxx11_final
88                cxx11_hdr_thread
89                cxx11_hdr_tuple
90                cxx11_lambdas
91                cxx11_noexcept
92                cxx11_nullptr
93                cxx11_rvalue_references
94                cxx11_template_aliases
95                cxx11_thread_local
96                cxx11_variadic_templates ] ]
97
98 [ run test_fiber.cpp :
99     : :
100     <context-impl>fcontext
101     [ requires cxx11_auto_declarations
102                cxx11_constexpr
103                cxx11_defaulted_functions
104                cxx11_final
105                cxx11_hdr_thread
106                cxx11_hdr_tuple
107                cxx11_lambdas
108                cxx11_noexcept
109                cxx11_nullptr
110                cxx11_rvalue_references
111                cxx11_template_aliases
112                cxx11_thread_local
113                cxx11_variadic_templates ]
114     : test_fiber_asm ]
115
116 [ run test_fiber.cpp :
117     : :
118     <conditional>@native-impl
119     [ requires cxx11_auto_declarations
120                cxx11_constexpr
121                cxx11_defaulted_functions
122                cxx11_final
123                cxx11_hdr_thread
124                cxx11_hdr_tuple
125                cxx11_lambdas
126                cxx11_noexcept
127                cxx11_nullptr
128                cxx11_rvalue_references
129                cxx11_template_aliases
130                cxx11_thread_local
131                cxx11_variadic_templates ]
132     : test_fiber_native ]
133
134 [ run test_fiber.cpp :
135     : :
136     <context-impl>ucontext
137     <conditional>@segmented-stack
138     [ requires cxx11_auto_declarations
139                cxx11_constexpr
140                cxx11_defaulted_functions
141                cxx11_final
142                cxx11_hdr_thread
143                cxx11_hdr_tuple
144                cxx11_lambdas
145                cxx11_noexcept
146                cxx11_nullptr
147                cxx11_rvalue_references
148                cxx11_template_aliases
149                cxx11_thread_local
150                cxx11_variadic_templates ]
151     : test_fiber_segmented ]
152
153 [ run test_callcc.cpp :
154     : :
155     <context-impl>fcontext
156     [ requires cxx11_auto_declarations
157                cxx11_constexpr
158                cxx11_defaulted_functions
159                cxx11_final
160                cxx11_hdr_thread
161                cxx11_hdr_tuple
162                cxx11_lambdas
163                cxx11_noexcept
164                cxx11_nullptr
165                cxx11_rvalue_references
166                cxx11_template_aliases
167                cxx11_thread_local
168                cxx11_variadic_templates ]
169     : test_callcc_asm ]
170
171 [ run test_callcc.cpp :
172     : :
173     <conditional>@native-impl
174     [ requires cxx11_auto_declarations
175                cxx11_constexpr
176                cxx11_defaulted_functions
177                cxx11_final
178                cxx11_hdr_thread
179                cxx11_hdr_tuple
180                cxx11_lambdas
181                cxx11_noexcept
182                cxx11_nullptr
183                cxx11_rvalue_references
184                cxx11_template_aliases
185                cxx11_thread_local
186                cxx11_variadic_templates ]
187     : test_callcc_native ]
188
189 [ run test_callcc.cpp :
190     : :
191     <context-impl>ucontext
192     <conditional>@segmented-stack
193     [ requires cxx11_auto_declarations
194                cxx11_constexpr
195                cxx11_defaulted_functions
196                cxx11_final
197                cxx11_hdr_thread
198                cxx11_hdr_tuple
199                cxx11_lambdas
200                cxx11_noexcept
201                cxx11_nullptr
202                cxx11_rvalue_references
203                cxx11_template_aliases
204                cxx11_thread_local
205                cxx11_variadic_templates ]
206     : test_callcc_segmented ] ;
207
208
209 test-suite full :
210     minimal ;
211
212 test-suite fc :
213 [ run test_fcontext.cpp :
214     : :
215     ] ;
216
217 explicit minimal ;
218 explicit fc ;