• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1
2#          Copyright Oliver Kowalke 2014.
3# Distributed under the Boost Software License, Version 1.0.
4#    (See accompanying file LICENSE_1_0.txt or copy at
5#          http://www.boost.org/LICENSE_1_0.txt)
6
7import common ;
8import feature ;
9import indirect ;
10import modules ;
11import os ;
12import path ;
13import testing ;
14import toolset ;
15import ../../config/checks/config : requires ;
16
17project boost/coroutine2/test
18    : requirements
19      <library>../../test/build//boost_unit_test_framework
20      <library>/boost/context//boost_context
21      <target-os>linux,<toolset>gcc,<segmented-stacks>on:<cxxflags>-fsplit-stack
22      <target-os>linux,<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      <optimization>speed
28      <variant>release
29    ;
30
31rule native-impl ( properties * )
32{
33    local result  ;
34    if ( <target-os>darwin in $(properties) || <target-os>android in $(properties) )
35    {
36        result = <build>no ;
37    }
38    else if ( ! ( <target-os>windows in $(properties) ) )
39    {
40        result = <context-impl>ucontext ;
41    }
42    else
43    {
44        result = <context-impl>winfib ;
45    }
46    return $(result) ;
47}
48
49test-suite minimal :
50[ run test_coroutine.cpp :
51    : :
52    <context-impl>fcontext
53    [ requires cxx11_auto_declarations
54               cxx11_constexpr
55               cxx11_defaulted_functions
56               cxx11_final
57               cxx11_hdr_tuple
58               cxx11_lambdas
59               cxx11_noexcept
60               cxx11_nullptr
61               cxx11_rvalue_references
62               cxx11_template_aliases
63               cxx11_variadic_templates ]
64    : test_coroutine_asm ]
65
66[ run test_coroutine.cpp :
67    : :
68    <conditional>@native-impl
69    [ requires cxx11_auto_declarations
70               cxx11_constexpr
71               cxx11_defaulted_functions
72               cxx11_final
73               cxx11_hdr_tuple
74               cxx11_lambdas
75               cxx11_noexcept
76               cxx11_nullptr
77               cxx11_rvalue_references
78               cxx11_template_aliases
79               cxx11_variadic_templates ]
80    : test_coroutine_native ] ;
81
82test-suite full :
83    minimal ;
84
85test-suite extra ;
86
87explicit minimal ;
88explicit extra ;
89