summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/PrecompileHeaders/PchIncludedAllLanguages.cmake
blob: eef189ae63a972fedc4e92b2889538ebb10adf4b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
enable_language(C)
enable_language(CXX)

if(CMAKE_CXX_COMPILE_OPTIONS_USE_PCH)
  add_definitions(-DHAVE_PCH_SUPPORT)
endif()

add_executable(main
  main.cpp
  pch-included.c
  pch-included.cpp
)
target_precompile_headers(main PRIVATE pch.h)

enable_testing()
add_test(NAME main COMMAND main)