Title: [172754] trunk/Source/_javascript_Core
Revision
172754
Author
[email protected]
Date
2014-08-19 10:36:54 -0700 (Tue, 19 Aug 2014)

Log Message

[CMake] Generate LLInt assembly correctly on Windows.
https://bugs.webkit.org/show_bug.cgi?id=135888

Patch by Alex Christensen <[email protected]> on 2014-08-19
Reviewed by Oliver Hunt.

* CMakeLists.txt:
Generate LowLevelInterpreterWin.asm instead of LLIntAssembly.h on Windows like the existing build system.
* PlatformWin.cmake:
Don't build JSGlobalObjectInspectorController.cpp on Windows.
* offlineasm/x86.rb:
Detect non-cygwin ruby installations correctly.

Modified Paths

Diff

Modified: trunk/Source/_javascript_Core/CMakeLists.txt (172753 => 172754)


--- trunk/Source/_javascript_Core/CMakeLists.txt	2014-08-19 17:04:45 UTC (rev 172753)
+++ trunk/Source/_javascript_Core/CMakeLists.txt	2014-08-19 17:36:54 UTC (rev 172754)
@@ -669,21 +669,40 @@
 # LLIntOffsetsExtractor matches, no output is generated. To make this target consistent and avoid
 # running this command for every build, we artificially update LLIntAssembly.h's mtime (using touch)
 # after every asm.rb run.
+if (MSVC)
+    set(LLIntOutput LowLevelInterpreterWin.asm)
+else ()
+    set(LLIntOutput LLIntAssembly.h)
+endif ()
+
 add_custom_command(
-    OUTPUT ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LLIntAssembly.h
+    OUTPUT ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/${LLIntOutput}
     MAIN_DEPENDENCY ${_javascript_CORE_DIR}/offlineasm/asm.rb
     DEPENDS LLIntOffsetsExtractor ${LLINT_ASM} ${OFFLINE_ASM} ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/InitBytecodes.asm
-    COMMAND ${RUBY_EXECUTABLE} ${_javascript_CORE_DIR}/offlineasm/asm.rb -I${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/ ${_javascript_CORE_DIR}/llint/LowLevelInterpreter.asm $<TARGET_FILE:LLIntOffsetsExtractor> ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LLIntAssembly.h
-    COMMAND ${CMAKE_COMMAND} -E touch_nocreate ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LLIntAssembly.h
+    COMMAND ${RUBY_EXECUTABLE} ${_javascript_CORE_DIR}/offlineasm/asm.rb -I${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/ ${_javascript_CORE_DIR}/llint/LowLevelInterpreter.asm $<TARGET_FILE:LLIntOffsetsExtractor> ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/${LLIntOutput}
+    COMMAND ${CMAKE_COMMAND} -E touch_nocreate ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/${LLIntOutput}
     VERBATIM)
 
 # The explanation for not making LLIntAssembly.h part of the OBJECT_DEPENDS property of some of
 # the .cpp files below is similar to the one in the previous comment. However, since these .cpp
 # files are used to build _javascript_Core itself, we can just add LLIntAssembly.h to JSC_HEADERS
 # since it is used in the add_library() call at the end of this file.
-list(APPEND _javascript_Core_HEADERS
-    ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LLIntAssembly.h
-)
+if (MSVC)
+    list(APPEND _javascript_Core_SOURCES
+        ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LowLevelInterpreterWin.asm
+    )
+    # Win32 needs /safeseh with assembly, but Win64 does not.
+    if (CMAKE_SIZEOF_VOID_P EQUAL 4)
+        set_source_files_properties(${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LowLevelInterpreterWin.asm
+            PROPERTIES COMPILE_FLAGS  "/safeseh"
+        )
+    endif ()
+else ()
+    list(APPEND _javascript_Core_HEADERS
+        ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/LLIntAssembly.h
+    )
+endif ()
+
 list(APPEND _javascript_Core_SOURCES
     llint/LLIntCLoop.cpp
     llint/LLIntData.cpp

Modified: trunk/Source/_javascript_Core/ChangeLog (172753 => 172754)


--- trunk/Source/_javascript_Core/ChangeLog	2014-08-19 17:04:45 UTC (rev 172753)
+++ trunk/Source/_javascript_Core/ChangeLog	2014-08-19 17:36:54 UTC (rev 172754)
@@ -1,3 +1,17 @@
+2014-08-19  Alex Christensen  <[email protected]>
+
+        [CMake] Generate LLInt assembly correctly on Windows.
+        https://bugs.webkit.org/show_bug.cgi?id=135888
+
+        Reviewed by Oliver Hunt.
+
+        * CMakeLists.txt:
+        Generate LowLevelInterpreterWin.asm instead of LLIntAssembly.h on Windows like the existing build system.
+        * PlatformWin.cmake:
+        Don't build JSGlobalObjectInspectorController.cpp on Windows.
+        * offlineasm/x86.rb:
+        Detect non-cygwin ruby installations correctly.
+
 2014-08-19  Michael Saboff  <[email protected]>
 
         REGRESSION(r163179): It broke the build on ARM Thumb2 with GCC

Modified: trunk/Source/_javascript_Core/PlatformWin.cmake (172753 => 172754)


--- trunk/Source/_javascript_Core/PlatformWin.cmake	2014-08-19 17:04:45 UTC (rev 172753)
+++ trunk/Source/_javascript_Core/PlatformWin.cmake	2014-08-19 17:36:54 UTC (rev 172754)
@@ -22,4 +22,8 @@
         COMMAND ${PYTHON_EXECUTABLE} ${TOOLS_DIR}/Scripts/generate-win32-export-forwards ${WTF_LIBRARY_LOCATION} ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/forwarded-exports.cpp
         VERBATIM)
     list(APPEND _javascript_Core_SOURCES ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/forwarded-exports.cpp)
-endif ()
\ No newline at end of file
+endif ()
+
+list(REMOVE_ITEM _javascript_Core_SOURCES
+    inspector/JSGlobalObjectInspectorController.cpp
+)

Modified: trunk/Source/_javascript_Core/offlineasm/x86.rb (172753 => 172754)


--- trunk/Source/_javascript_Core/offlineasm/x86.rb	2014-08-19 17:04:45 UTC (rev 172753)
+++ trunk/Source/_javascript_Core/offlineasm/x86.rb	2014-08-19 17:36:54 UTC (rev 172754)
@@ -55,7 +55,7 @@
 end
 
 def isWindows
-    RUBY_PLATFORM =~ /cygwin/i
+    ENV['OS'] == 'Windows_NT'
 end
 
 def isGCC
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to