Diff
Copied: trunk/Source/WTF/AVFoundationSupport.py (from rev 219599, trunk/Source/WebCore/AVFoundationSupport.py) (0 => 219600)
--- trunk/Source/WTF/AVFoundationSupport.py (rev 0)
+++ trunk/Source/WTF/AVFoundationSupport.py 2017-07-18 04:06:55 UTC (rev 219600)
@@ -0,0 +1,64 @@
+#!/usr/bin/python
+
+# Copyright (C) 2015 Apple Inc. All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the above copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+# 3. Neither the name of Apple puter, Inc. ("Apple") nor the names of
+# its contributors may be used to endorse or promote products derived
+# from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND ANY
+# EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL APPLE OR ITS CONTRIBUTORS BE LIABLE FOR ANY
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+import re
+import sys
+import os
+
+
+def lookFor(relativePath):
+ return os.path.isfile(sys.argv[1] + relativePath)
+
+
+def fileContains(relativePath, regexp):
+ with open(sys.argv[1] + relativePath) as file:
+ for line in file:
+ if regexp.search(line):
+ return True
+ return False
+
+
+print "/* Identifying AVFoundation Support */"
+if lookFor("/include/AVFoundationCF/AVCFBase.h"):
+ print "#define HAVE_AVCF 1"
+if lookFor("/include/AVFoundationCF/AVCFPlayerItemLegibleOutput.h"):
+ print "#define HAVE_AVCF_LEGIBLE_OUTPUT 1"
+if lookFor("/include/AVFoundationCF/AVCFAssetResourceLoader.h"):
+ print "#define HAVE_AVFOUNDATION_LOADER_DELEGATE 1"
+if lookFor("/include/AVFoundationCF/AVCFAsset.h"):
+ regexp = re.compile("AVCFURLAssetIsPlayableExtendedMIMEType")
+ if fileContains("/include/AVFoundationCF/AVCFAsset.h", regexp):
+ print "#define HAVE_AVCFURL_PLAYABLE_MIMETYPE 1"
+if lookFor("/include/QuartzCore/CACFLayer.h"):
+ regexp = re.compile("CACFLayerSetContentsScale")
+ if fileContains("/include/QuartzCore/CACFLayer.h", regexp):
+ print "#define HAVE_CACFLAYER_SETCONTENTSSCALE 1"
+if lookFor("/include/AVFoundationCF/AVCFPlayerItemLegibleOutput.h"):
+ regexp = re.compile("kAVCFPlayerItemLegibleOutput_CallbacksVersion_2")
+ if fileContains("/include/AVFoundationCF/AVCFPlayerItemLegibleOutput.h", regexp):
+ print "#define HAVE_AVCFPLAYERITEM_CALLBACK_VERSION_2 1"
Modified: trunk/Source/WTF/ChangeLog (219599 => 219600)
--- trunk/Source/WTF/ChangeLog 2017-07-18 03:52:23 UTC (rev 219599)
+++ trunk/Source/WTF/ChangeLog 2017-07-18 04:06:55 UTC (rev 219600)
@@ -1,3 +1,19 @@
+2017-07-17 Yoshiaki Jitsukawa <yoshiaki.jitsuk...@sony.com>
+
+ Move USE_AVFOUNDATION definition on Windows to wtf/Platform.h
+ https://bugs.webkit.org/show_bug.cgi?id=174356
+
+ Reviewed by Brent Fulgham.
+
+ Move the definition of USE_AVFOUNDATION on Windows to wtf/platform.h
+
+ Add a custom command to generate AVFoundationHeaderDetection.h, which
+ is renamed from WebCoreHeaderDetection.h
+
+ * AVFoundationSupport.py: Moved from Source/WebCore/AVFoundationSupport.py.
+ * wtf/Platform.h:
+ * wtf/PlatformWin.cmake:
+
2017-07-17 Darin Adler <da...@apple.com>
Improve use of NeverDestroyed
Modified: trunk/Source/WTF/wtf/Platform.h (219599 => 219600)
--- trunk/Source/WTF/wtf/Platform.h 2017-07-18 03:52:23 UTC (rev 219599)
+++ trunk/Source/WTF/wtf/Platform.h 2017-07-18 04:06:55 UTC (rev 219600)
@@ -1057,6 +1057,21 @@
#define USE_AVFOUNDATION 1
#endif
+#if PLATFORM(WIN) && !USE(WINGDI)
+#include <wtf/AVFoundationHeaderDetection.h>
+#endif
+
+#if PLATFORM(WIN) && USE(CG) && HAVE(AVCF)
+#define USE_AVFOUNDATION 1
+
+#if HAVE(AVCF_LEGIBLE_OUTPUT)
+#define HAVE_AVFOUNDATION_MEDIA_SELECTION_GROUP 1
+#define HAVE_AVFOUNDATION_LEGIBLE_OUTPUT_SUPPORT 1
+#define HAVE_MEDIA_ACCESSIBILITY_FRAMEWORK 1
+#endif
+
+#endif
+
#if !defined(ENABLE_TREE_DEBUGGING)
#if !defined(NDEBUG)
#define ENABLE_TREE_DEBUGGING 1
Modified: trunk/Source/WTF/wtf/PlatformWin.cmake (219599 => 219600)
--- trunk/Source/WTF/wtf/PlatformWin.cmake 2017-07-18 03:52:23 UTC (rev 219599)
+++ trunk/Source/WTF/wtf/PlatformWin.cmake 2017-07-18 04:06:55 UTC (rev 219600)
@@ -16,6 +16,10 @@
win/WorkQueueWin.cpp
)
+list(APPEND WTF_HEADERS
+ "${DERIVED_SOURCES_WTF_DIR}/AVFoundationHeaderDetection.h"
+)
+
if (${WTF_PLATFORM_WIN_CAIRO})
list(APPEND WTF_LIBRARIES
cflite
@@ -26,6 +30,12 @@
)
endif ()
+add_custom_command(
+ OUTPUT "${DERIVED_SOURCES_WTF_DIR}/AVFoundationHeaderDetection.h"
+ WORKING_DIRECTORY "${DERIVED_SOURCES_WTF_DIR}"
+ COMMAND ${PYTHON_EXECUTABLE} ${WTF_DIR}/AVFoundationSupport.py ${WEBKIT_LIBRARIES_DIR} > AVFoundationHeaderDetection.h
+ VERBATIM)
+
set(WTF_PRE_BUILD_COMMAND "${CMAKE_BINARY_DIR}/DerivedSources/WTF/preBuild.cmd")
file(WRITE "${WTF_PRE_BUILD_COMMAND}" "@xcopy /y /s /d /f \"${WTF_DIR}/wtf/*.h\" \"${DERIVED_SOURCES_DIR}/ForwardingHeaders/WTF\" >nul 2>nul\n@xcopy /y /s /d /f \"${DERIVED_SOURCES_DIR}/WTF/*.h\" \"${DERIVED_SOURCES_DIR}/ForwardingHeaders/WTF\" >nul 2>nul\n")
file(MAKE_DIRECTORY ${DERIVED_SOURCES_DIR}/ForwardingHeaders/WTF)
Deleted: trunk/Source/WebCore/AVFoundationSupport.py (219599 => 219600)
--- trunk/Source/WebCore/AVFoundationSupport.py 2017-07-18 03:52:23 UTC (rev 219599)
+++ trunk/Source/WebCore/AVFoundationSupport.py 2017-07-18 04:06:55 UTC (rev 219600)
@@ -1,63 +0,0 @@
-#!/usr/bin/python
-
-# Copyright (C) 2015 Apple Inc. All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without
-# modification, are permitted provided that the following conditions
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright
-# notice, this list of conditions and the following disclaimer.
-# 2. Redistributions in binary form must reproduce the above copyright
-# notice, this list of conditions and the following disclaimer in the
-# documentation and/or other materials provided with the distribution.
-# 3. Neither the name of Apple puter, Inc. ("Apple") nor the names of
-# its contributors may be used to endorse or promote products derived
-# from this software without specific prior written permission.
-#
-# THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND ANY
-# EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
-# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
-# DISCLAIMED. IN NO EVENT SHALL APPLE OR ITS CONTRIBUTORS BE LIABLE FOR ANY
-# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
-# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
-# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
-# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
-# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-import re
-import sys
-import os
-
-def lookFor(relativePath):
- return os.path.isfile(sys.argv[1] + relativePath)
-
-
-def fileContains(relativePath, regexp):
- with open(sys.argv[1] + relativePath) as file:
- for line in file:
- if regexp.search(line):
- return True
- return False
-
-
-print "/* Identifying AVFoundation Support */"
-if lookFor("/include/AVFoundationCF/AVCFBase.h"):
- print "#define HAVE_AVCF 1"
-if lookFor("/include/AVFoundationCF/AVCFPlayerItemLegibleOutput.h"):
- print "#define HAVE_AVCF_LEGIBLE_OUTPUT 1"
-if lookFor("/include/AVFoundationCF/AVCFAssetResourceLoader.h"):
- print "#define HAVE_AVFOUNDATION_LOADER_DELEGATE 1"
-if lookFor("/include/AVFoundationCF/AVCFAsset.h"):
- regexp = re.compile("AVCFURLAssetIsPlayableExtendedMIMEType")
- if fileContains("/include/AVFoundationCF/AVCFAsset.h", regexp):
- print "#define HAVE_AVCFURL_PLAYABLE_MIMETYPE 1"
-if lookFor("/include/QuartzCore/CACFLayer.h"):
- regexp = re.compile("CACFLayerSetContentsScale")
- if fileContains("/include/QuartzCore/CACFLayer.h", regexp):
- print "#define HAVE_CACFLAYER_SETCONTENTSSCALE 1"
-if lookFor("/include/AVFoundationCF/AVCFPlayerItemLegibleOutput.h"):
- regexp = re.compile("kAVCFPlayerItemLegibleOutput_CallbacksVersion_2")
- if fileContains("/include/AVFoundationCF/AVCFPlayerItemLegibleOutput.h", regexp):
- print "#define HAVE_AVCFPLAYERITEM_CALLBACK_VERSION_2 1"
Modified: trunk/Source/WebCore/ChangeLog (219599 => 219600)
--- trunk/Source/WebCore/ChangeLog 2017-07-18 03:52:23 UTC (rev 219599)
+++ trunk/Source/WebCore/ChangeLog 2017-07-18 04:06:55 UTC (rev 219600)
@@ -1,3 +1,21 @@
+2017-07-17 Yoshiaki Jitsukawa <yoshiaki.jitsuk...@sony.com>
+
+ Move USE_AVFOUNDATION definition on Windows to wtf/Platform.h
+ https://bugs.webkit.org/show_bug.cgi?id=174356
+
+ Reviewed by Brent Fulgham.
+
+ Move the definition of USE_AVFOUNDATION on Windows to wtf/platform.h
+
+ Rename WebCoreHeaderDetection.h to AVFoundationHeaderDetection.h
+
+ * AVFoundationSupport.py: Moved to Source/WTF/AVFoundationSupport.py.
+ * DerivedSources.make:
+ * PlatformWin.cmake:
+ * config.h:
+ * platform/graphics/ca/win/PlatformCALayerWin.cpp:
+ * platform/graphics/ca/win/PlatformCALayerWinInternal.cpp:
+
2017-07-17 Sam Weinig <s...@webkit.org>
[WebIDL] Remove custom bindings that require non-caching JS strings
Modified: trunk/Source/WebCore/DerivedSources.make (219599 => 219600)
--- trunk/Source/WebCore/DerivedSources.make 2017-07-18 03:52:23 UTC (rev 219599)
+++ trunk/Source/WebCore/DerivedSources.make 2017-07-18 04:06:55 UTC (rev 219600)
@@ -1476,15 +1476,3 @@
endif # MACOS
-# ------------------------
-
-# Header detection
-
-ifeq ($(OS),Windows_NT)
-
-all : WebCoreHeaderDetection.h
-
-WebCoreHeaderDetection.h : $(WebCore)/AVFoundationSupport.py DerivedSources.make
- $(PYTHON) $(WebCore)/AVFoundationSupport.py $(WEBKIT_LIBRARIES) > $@
-
-endif # Windows_NT
Modified: trunk/Source/WebCore/PlatformWin.cmake (219599 => 219600)
--- trunk/Source/WebCore/PlatformWin.cmake 2017-07-18 03:52:23 UTC (rev 219599)
+++ trunk/Source/WebCore/PlatformWin.cmake 2017-07-18 04:06:55 UTC (rev 219600)
@@ -154,10 +154,6 @@
${WEBCORE_DIR}/css/themeWinQuirks.css
)
-list(APPEND WebCore_DERIVED_SOURCES
- "${DERIVED_SOURCES_WEBCORE_DIR}/WebCoreHeaderDetection.h"
-)
-
set(WebCore_FORWARDING_HEADERS_DIRECTORIES
.
accessibility
@@ -273,12 +269,6 @@
include(PlatformAppleWin.cmake)
endif ()
-add_custom_command(
- OUTPUT "${DERIVED_SOURCES_WEBCORE_DIR}/WebCoreHeaderDetection.h"
- WORKING_DIRECTORY "${DERIVED_SOURCES_WEBCORE_DIR}"
- COMMAND ${PYTHON_EXECUTABLE} ${WEBCORE_DIR}/AVFoundationSupport.py ${WEBKIT_LIBRARIES_DIR} > WebCoreHeaderDetection.h
- VERBATIM)
-
make_directory(${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/WebKit.resources/en.lproj)
file(COPY
"${WEBCORE_DIR}/English.lproj/Localizable.strings"
Modified: trunk/Source/WebCore/config.h (219599 => 219600)
--- trunk/Source/WebCore/config.h 2017-07-18 03:52:23 UTC (rev 219599)
+++ trunk/Source/WebCore/config.h 2017-07-18 04:06:55 UTC (rev 219600)
@@ -29,10 +29,6 @@
#define USE_FILE_LOCK 1
#endif
-#if PLATFORM(WIN) && !USE(WINGDI)
-#include "WebCoreHeaderDetection.h"
-#endif
-
#include "PlatformExportMacros.h"
#include <pal/ExportMacros.h>
#include <runtime/JSExportMacros.h>
@@ -108,17 +104,3 @@
#define CGFLOAT_DEFINED 1
#endif
#endif /* USE(CG) */
-
-// FIXME: Move this to _javascript_Core/wtf/Platform.h, which is where we define USE_AVFOUNDATION on the Mac.
-// https://bugs.webkit.org/show_bug.cgi?id=67334
-#if PLATFORM(WIN) && USE(CG) && HAVE(AVCF)
-#define USE_AVFOUNDATION 1
-
-#if HAVE(AVCF_LEGIBLE_OUTPUT)
-#define USE_AVFOUNDATION 1
-#define HAVE_AVFOUNDATION_MEDIA_SELECTION_GROUP 1
-#define HAVE_AVFOUNDATION_LEGIBLE_OUTPUT_SUPPORT 1
-#define HAVE_MEDIA_ACCESSIBILITY_FRAMEWORK 1
-#endif
-
-#endif
Modified: trunk/Source/WebCore/platform/graphics/ca/win/PlatformCALayerWin.cpp (219599 => 219600)
--- trunk/Source/WebCore/platform/graphics/ca/win/PlatformCALayerWin.cpp 2017-07-18 03:52:23 UTC (rev 219599)
+++ trunk/Source/WebCore/platform/graphics/ca/win/PlatformCALayerWin.cpp 2017-07-18 04:06:55 UTC (rev 219600)
@@ -37,10 +37,10 @@
#include "PlatformCALayerWinInternal.h"
#include "TextRun.h"
#include "TileController.h"
-#include "WebCoreHeaderDetection.h"
#include "WebTiledBackingLayerWin.h"
#include <QuartzCore/CoreAnimationCF.h>
#include <WebKitSystemInterface/WebKitSystemInterface.h>
+#include <wtf/AVFoundationHeaderDetection.h>
#include <wtf/CurrentTime.h>
#include <wtf/text/CString.h>
#include <wtf/text/StringBuilder.h>
Modified: trunk/Source/WebCore/platform/graphics/ca/win/PlatformCALayerWinInternal.cpp (219599 => 219600)
--- trunk/Source/WebCore/platform/graphics/ca/win/PlatformCALayerWinInternal.cpp 2017-07-18 03:52:23 UTC (rev 219599)
+++ trunk/Source/WebCore/platform/graphics/ca/win/PlatformCALayerWinInternal.cpp 2017-07-18 04:06:55 UTC (rev 219600)
@@ -34,8 +34,8 @@
#include "PlatformCALayer.h"
#include "TileController.h"
#include "TiledBacking.h"
-#include "WebCoreHeaderDetection.h"
#include <QuartzCore/CACFLayer.h>
+#include <wtf/AVFoundationHeaderDetection.h>
#include <wtf/MainThread.h>
using namespace std;