summaryrefslogtreecommitdiffstats
path: root/Tests/ISPC/SystemIncludes
diff options
context:
space:
mode:
authorRobert Maynard <robert.maynard@kitware.com>2020-12-10 21:08:24 (GMT)
committerBrad King <brad.king@kitware.com>2020-12-14 18:13:09 (GMT)
commitc9a50f35565dcc1df8bd82126ecced95e60c29e4 (patch)
treeede35e80def43d76af7378632f05115c0b43bea7 /Tests/ISPC/SystemIncludes
parent6aff058ab4a2d54a316dbaa536572ad71efb8b51 (diff)
downloadCMake-c9a50f35565dcc1df8bd82126ecced95e60c29e4.zip
CMake-c9a50f35565dcc1df8bd82126ecced95e60c29e4.tar.gz
CMake-c9a50f35565dcc1df8bd82126ecced95e60c29e4.tar.bz2
ISPC: Generated Headers suffix configurable with a better default
The target property `ISPC_HEADER_SUFFIX` and associated global variable now can control the suffix used when generating the C/C++ interoperability ISPC headers. In addition the default suffix is now "_ispc.h" which matches the common convention that the ISPC compiler team uses and recommends.
Diffstat (limited to 'Tests/ISPC/SystemIncludes')
-rw-r--r--Tests/ISPC/SystemIncludes/CMakeLists.txt2
1 files changed, 2 insertions, 0 deletions
diff --git a/Tests/ISPC/SystemIncludes/CMakeLists.txt b/Tests/ISPC/SystemIncludes/CMakeLists.txt
index 95959b2..d94e75e 100644
--- a/Tests/ISPC/SystemIncludes/CMakeLists.txt
+++ b/Tests/ISPC/SystemIncludes/CMakeLists.txt
@@ -4,8 +4,10 @@ project(ispc_spaces_in_path ISPC CXX)
add_executable(ISPCSystemIncludes main.cxx simple.ispc)
set_target_properties(ISPCSystemIncludes PROPERTIES POSITION_INDEPENDENT_CODE ON)
+set_target_properties(ISPCSystemIncludes PROPERTIES ISPC_HEADER_SUFFIX ".ispc.h")
target_include_directories(ISPCSystemIncludes SYSTEM PRIVATE "${CMAKE_CURRENT_BINARY_DIR}")
+
target_compile_options(ISPCSystemIncludes PRIVATE "$<$<COMPILE_LANGUAGE:ISPC>:--target=sse2-i32x4>")
if(CMAKE_SIZEOF_VOID_P EQUAL 4)
target_compile_options(ISPCSystemIncludes PRIVATE "$<$<COMPILE_LANGUAGE:ISPC>:--arch=x86>")