Imported Upstream version 1.57.0
[platform/upstream/boost.git] / libs / config / test / Jamfile.v2
index df61352..05d27df 100644 (file)
@@ -1,14 +1,21 @@
 #
 # Copyright John Maddock 2008.
-# Use, modification and distribution are subject to the 
-# Boost Software License, Version 1.0. (See accompanying file 
+# Use, modification and distribution are subject to 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)
 #
 # If you need to alter build preferences then set them in
 # the template defined in options_v2.jam.
 #
 
+project
+    : requirements
+      <toolset>gcc:<cxxflags>-Wno-deprecated-declarations
+;
+
+
 import modules ;
+import ../checks/config : requires ;
 
 local is_unix = [ modules.peek : UNIX ] ;
 
@@ -24,26 +31,48 @@ if $(is_unix)
 }
 
 test-suite config
-  : 
+  :
     [ compile config_test_c.c ]
-    [ run config_test.cpp 
+    [ run config_test.cpp
           : #args
           : #input-files
           : #requirements
           <threading>multi
           : config_test_threaded
     ]
-    [ run config_test.cpp 
+    [ run config_test.cpp
+          : #args
+          : #input-files
+          : #requirements
+          <threading>single <toolset>msvc:<runtime-link>static <toolset>msvc:<link>static
+          <target-os>linux:<linkflags>-lpthread
+          <target-os>linux:<linkflags>-lrt
+          <toolset>gcc:<linkflags>$(OTHERFLAGS)
+    ]
+    [ run config_test.cpp
           : #args
           : #input-files
           : #requirements
-          <threading>single <toolset>msvc:<runtime-link>static <toolset>msvc:<link>static 
+          <rtti>off
           <target-os>linux:<linkflags>-lpthread
           <target-os>linux:<linkflags>-lrt
           <toolset>gcc:<linkflags>$(OTHERFLAGS)
+          : config_test_no_rtti
+    ]
+    [ run config_test.cpp
+          : #args
+          : #input-files
+          : #requirements
+          <exception-handling>off
+          <target-os>linux:<linkflags>-lpthread
+          <target-os>linux:<linkflags>-lrt
+          <toolset>gcc:<linkflags>$(OTHERFLAGS)
+          : config_test_no_except
     ]
      [ run config_info.cpp : : : <test-info>always_show_run_output <threading>single <toolset>msvc:<runtime-link>static <toolset>msvc:<link>static ]
      [ run config_info.cpp : : : <test-info>always_show_run_output <threading>multi : config_info_threaded ]
+     [ run config_info.cpp : : : <test-info>always_show_run_output <rtti>off : config_info_no_rtti ]
+     [ run config_info.cpp : : : <test-info>always_show_run_output <exception-handling>off : config_info_no_except ]
      [ run math_info.cpp : : : <test-info>always_show_run_output <toolset>borland:<runtime-link>static <toolset>borland:<link>static ]
      [ run abi/abi_test.cpp abi/main.cpp ]
      [ run limits_test.cpp ../../test/build//boost_test_exec_monitor ]
@@ -59,4 +88,16 @@ test-suite config
     ]
     [ compile-fail threads/test_thread_fail1.cpp ]
     [ compile-fail threads/test_thread_fail2.cpp ]
+    [ compile boost_fallthrough_test.cpp : [ check-target-builds has_clang_implicit_fallthrough "Clang implicit fallthrough" : <toolset>clang:<cxxflags>"-std=c++11 -Wimplicit-fallthrough" <warnings-as-errors>on <warnings>all ] ]
+    [ compile helper_macro_test.cpp ]
+    [ run cstdint_test.cpp : : : <warnings>all <toolset>gcc:<cxxflags>"-Wno-long-long -Wextra" <toolset>darwin:<cxxflags>-Wno-long-long ]
+    [ run cstdint_test2.cpp : : : <warnings>all <toolset>gcc:<cxxflags>"-Wno-long-long -Wextra" <toolset>darwin:<cxxflags>-Wno-long-long ]
+    [ compile cstdint_include_test.cpp : <warnings>all <toolset>gcc:<cxxflags>-Wextra ]
+    [ run config_build_check.cpp : : : [ requires int128 cxx11_constexpr cxx11_user_defined_literals ] ]
   ;
+
+obj has_clang_implicit_fallthrough : cmd_line_check.cpp :
+               <toolset>clang:<cxxflags>"-std=c++11 -Wimplicit-fallthrough" <warnings-as-errors>on <warnings>all ;
+
+explicit has_clang_implicit_fallthrough ;
+