Fix Windows build, ostensibly after r194424.
authorachristensen@apple.com <achristensen@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 29 Dec 2015 05:15:56 +0000 (05:15 +0000)
committerachristensen@apple.com <achristensen@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 29 Dec 2015 05:15:56 +0000 (05:15 +0000)
* CMakeLists.txt:
* PlatformWin.cmake:
ml.exe was given too many unneeded parameters (/Idir1 /Idir2 etc.), and it was failing sometimes with long directories.
Instead of compiling makesafeseh.asm as a normal source file, we now put only the parameters that are needed to assemble
the object file, then link with the object file.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@194434 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/CMakeLists.txt
Source/WebCore/ChangeLog
Source/WebCore/PlatformWin.cmake

index d24293c..b7b142d 100644 (file)
@@ -3730,10 +3730,6 @@ include_directories(SYSTEM ${WebCore_SYSTEM_INCLUDE_DIRECTORIES})
 
 if (MSVC)
     ADD_PRECOMPILED_HEADER("WebCorePrefix.h" "WebCorePrefix.cpp" WebCore_SOURCES)
-    if (CMAKE_SIZEOF_VOID_P EQUAL 4)
-        list(APPEND WebCore_SOURCES platform/win/makesafeseh.asm)
-        set_source_files_properties(platform/win/makesafeseh.asm PROPERTIES COMPILE_FLAGS "/safeseh")
-    endif ()
 endif ()
 
 add_library(WebCore ${WebCore_LIBRARY_TYPE} ${WebCore_SOURCES})
index 010a2a0..e5f95f7 100644 (file)
@@ -1,3 +1,13 @@
+2015-12-28  Alex Christensen  <achristensen@webkit.org>
+
+        Fix Windows build, ostensibly after r194424.
+
+        * CMakeLists.txt:
+        * PlatformWin.cmake:
+        ml.exe was given too many unneeded parameters (/Idir1 /Idir2 etc.), and it was failing sometimes with long directories.
+        Instead of compiling makesafeseh.asm as a normal source file, we now put only the parameters that are needed to assemble
+        the object file, then link with the object file.
+
 2015-12-28  Brady Eidson  <beidson@apple.com>
 
         Modern IDB: Rename IDBServerOperation to ServerOpenDBRequest.
index c713fba..ee45a8e 100644 (file)
@@ -40,7 +40,6 @@ list(APPEND WebCore_INCLUDE_DIRECTORIES
     "${THIRDPARTY_DIR}/ANGLE/include/egl"
 )
 
-enable_language(ASM_MASM)
 list(APPEND WebCore_SOURCES
     accessibility/win/AXObjectCacheWin.cpp
     accessibility/win/AccessibilityObjectWin.cpp
@@ -246,6 +245,15 @@ set(WebCore_FORWARDING_HEADERS_DIRECTORIES
     svg/graphics/filters
 )
 
+if (CMAKE_SIZEOF_VOID_P EQUAL 4)
+    list(APPEND WebCore_SOURCES ${DERIVED_SOURCES_WEBCORE_DIR}/makesafeseh.obj)
+    add_custom_command(
+        OUTPUT ${DERIVED_SOURCES_WEBCORE_DIR}/makesafeseh.obj
+        DEPENDS ${WEBCORE_DIR}/platform/win/makesafeseh.asm
+        COMMAND ml /safeseh /c /Fo ${DERIVED_SOURCES_WEBCORE_DIR}/makesafeseh.obj ${WEBCORE_DIR}/platform/win/makesafeseh.asm
+        VERBATIM)
+endif ()
+
 if (${WTF_PLATFORM_WIN_CAIRO})
     include(PlatformWinCairo.cmake)
 else ()