Speed up JIT builds
authorBruce Forstall <brucefo@microsoft.com>
Wed, 22 Feb 2017 23:43:18 +0000 (15:43 -0800)
committerBruce Forstall <brucefo@microsoft.com>
Wed, 22 Feb 2017 23:43:18 +0000 (15:43 -0800)
We don't need to build the static lib and crossgen static lib
versions of the JIT unless FEATURE_MERGE_JIT_AND_ENGINE is set.
And, since we currently don't set it, this means doing two
fewer JIT builds.

Commit migrated from https://github.com/dotnet/coreclr/commit/91681810db13a23fa7fc0437340946bf8cfe140b

src/coreclr/src/jit/CMakeLists.txt

index db6e597..ea2bf27 100644 (file)
@@ -200,8 +200,12 @@ endif()
 
 add_custom_target(jit_exports DEPENDS ${JIT_EXPORTS_FILE})
 
-add_subdirectory(dll)
-add_subdirectory(crossgen)
+if (FEATURE_MERGE_JIT_AND_ENGINE)
+  # Despite the directory being named "dll", it creates a static library "clrjit_static" to link into the VM.
+  add_subdirectory(dll)
+  add_subdirectory(crossgen)
+endif (FEATURE_MERGE_JIT_AND_ENGINE)
+
 add_subdirectory(standalone)
 
 if (CLR_CMAKE_PLATFORM_ARCH_ARM)