diff options
author | Jan Vorlicek <janvorli@microsoft.com> | 2016-01-19 19:24:23 +0100 |
---|---|---|
committer | Rama Krishnan Raghupathy <ramarag@microsoft.com> | 2016-01-21 14:39:01 -0800 |
commit | 2c25d6ca44e3129ace57f6383260a42023a6d646 (patch) | |
tree | a6132b98d4c43b788eb8bdf34794e97d84bd724a /src/CMakeLists.txt | |
parent | aae412433d6235b0a1c5f8f0301b2cc066857cc6 (diff) | |
download | coreclr-2c25d6ca44e3129ace57f6383260a42023a6d646.tar.gz coreclr-2c25d6ca44e3129ace57f6383260a42023a6d646.tar.bz2 coreclr-2c25d6ca44e3129ace57f6383260a42023a6d646.zip |
FIx the incremental build for Windows
Conflicts:
build.cmd
src/dlls/clretwrc/CMakeLists.txt
Cleanup
Diffstat (limited to 'src/CMakeLists.txt')
-rw-r--r-- | src/CMakeLists.txt | 37 |
1 files changed, 36 insertions, 1 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 5815ca1532..9231dc9a79 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -1,4 +1,3 @@ -include_directories($ENV{__GeneratedIntermediatesDir}/inc) include_directories("inc") include_directories("strongname/inc") include_directories("inc/winrt") @@ -9,6 +8,42 @@ include_directories("md/inc") include_directories("classlibnative/bcltype") include_directories("classlibnative/cryptography") include_directories("classlibnative/inc") +include_directories("${GENERATED_INCLUDE_DIR}") + +if(WIN32) + add_custom_command( + COMMENT "Generating Eventing Files" + OUTPUT ${GENERATED_INCLUDE_DIR}/ClrEtwAll.h + OUTPUT ${GENERATED_INCLUDE_DIR}/clretwallmain.h + OUTPUT ${GENERATED_INCLUDE_DIR}/etmdummy.h + COMMAND ${MC} -h ${GENERATED_INCLUDE_DIR} -r ${GENERATED_INCLUDE_DIR} -b -co -um -p FireEtw "${VM_DIR}/ClrEtwAll.man" + COMMAND ${PYTHON} -B -Wall -Werror "${CLR_DIR}/src/scripts/genWinEtw.py" --man "${VM_DIR}/ClrEtwAll.man" --exc "${VM_DIR}/ClrEtwAllMeta.lst" --eventheader "${GENERATED_INCLUDE_DIR}/ClrEtwAll.h" --macroheader "${GENERATED_INCLUDE_DIR}/clretwallmain.h" --dummy "${GENERATED_INCLUDE_DIR}/etmdummy.h" + DEPENDS "${CLR_DIR}/src/scripts/genWinEtw.py" "${VM_DIR}/ClrEtwAll.man" "${VM_DIR}/ClrEtwAllMeta.lst" + ) +elseif(CLR_CMAKE_PLATFORM_LINUX) + add_custom_command( + COMMENT "Generating Eventing Files" + OUTPUT ${GENERATED_INCLUDE_DIR}/ClrEtwAll.h + OUTPUT ${GENERATED_INCLUDE_DIR}/clretwallmain.h + OUTPUT ${GENERATED_INCLUDE_DIR}/etmdummy.h + COMMAND ${PYTHON} -B -Wall -Werror "${CLR_DIR}/src/scripts/genXplatEventing.py" --man "${VM_DIR}/ClrEtwAll.man" --exc "${VM_DIR}/ClrEtwAllMeta.lst" --eventheader "${GENERATED_INCLUDE_DIR}/ClrEtwAll.h" --macroheader "${GENERATED_INCLUDE_DIR}/clretwallmain.h" --dummy "${GENERATED_INCLUDE_DIR}/etmdummy.h" + DEPENDS "${CLR_DIR}/src/scripts/genWinEtw.py" "${VM_DIR}/ClrEtwAll.man" "${VM_DIR}/ClrEtwAllMeta.lst" + ) +endif() + +add_custom_target( + GeneratedEventingFiles + DEPENDS ${GENERATED_INCLUDE_DIR}/clretwallmain.h ${GENERATED_INCLUDE_DIR}/etmdummy.h ${GENERATED_INCLUDE_DIR}/ClrEtwAll.h) + +function(add_library_clr) + add_library(${ARGV}) + add_dependencies(${ARGV0} GeneratedEventingFiles) +endfunction() + +function(add_executable_clr) + add_executable(${ARGV}) + add_dependencies(${ARGV0} GeneratedEventingFiles) +endfunction() if(CLR_CMAKE_PLATFORM_UNIX) add_subdirectory(ToolBox/SOS/Strike) |