diff Resources/CMake/VisualStudioPrecompiledHeaders.cmake @ 2391:233d6eeef799

fix pch
author Sebastien Jodogne <s.jodogne@gmail.com>
date Wed, 30 Aug 2017 12:29:48 +0200
parents c9e0e709485b
children c6dab987f43a
line wrap: on
line diff
--- a/Resources/CMake/VisualStudioPrecompiledHeaders.cmake	Wed Aug 30 12:05:49 2017 +0200
+++ b/Resources/CMake/VisualStudioPrecompiledHeaders.cmake	Wed Aug 30 12:29:48 2017 +0200
@@ -1,4 +1,4 @@
-macro(ADD_VISUAL_STUDIO_PRECOMPILED_HEADERS PrecompiledHeaders PrecompiledSource Sources)
+macro(ADD_VISUAL_STUDIO_PRECOMPILED_HEADERS PrecompiledHeaders PrecompiledSource Sources Target)
   get_filename_component(PrecompiledBasename ${PrecompiledHeaders} NAME_WE)
   set(PrecompiledBinary "${PrecompiledBasename}_$(ConfigurationName).pch")
 
@@ -10,5 +10,5 @@
     PROPERTIES COMPILE_FLAGS "/Yu\"${PrecompiledHeaders}\" /FI\"${PrecompiledHeaders}\" /Fp\"${PrecompiledBinary}\""
     OBJECT_DEPENDS "${PrecompiledBinary}")
 
-  list(APPEND ${Sources} ${PrecompiledSource})
+  set(${Target} ${PrecompiledSource})
 endmacro()