diff --git a/test/Jamfile.v2 b/test/Jamfile.v2 index 16d69566..06fc7499 100644 --- a/test/Jamfile.v2 +++ b/test/Jamfile.v2 @@ -6,6 +6,9 @@ import testing ; lib boost_unit_test_framework ; +compile check/has_opencl.cpp : : has_opencl ; +explicit has_opencl ; + project : source-location . : requirements @@ -19,6 +22,8 @@ project msvc:/wd4800 # Warning C4800: 'uint32_t' : forcing value to bool 'true' or 'false' (performance warning) msvc:/wd4838 # Warning C4838: conversion from 'double' to 'float' requires a narrowing conversion /boost/test//boost_unit_test_framework + + [ check-target-builds has_opencl "OpenCL" : : no ] ; rule test_all diff --git a/test/check/has_opencl.cpp b/test/check/has_opencl.cpp new file mode 100644 index 00000000..10769d2b --- /dev/null +++ b/test/check/has_opencl.cpp @@ -0,0 +1,11 @@ +//---------------------------------------------------------------------------// +// Copyright (c) 2017 Kohei Takahashi +// +// 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 +// +// See http://boostorg.github.com/compute for more information. +//---------------------------------------------------------------------------// + +#include