Introducing the Platform Abstraction Layer (PAL)
authormmaxfield@apple.com <mmaxfield@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 22 Jan 2017 17:24:51 +0000 (17:24 +0000)
committermmaxfield@apple.com <mmaxfield@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 22 Jan 2017 17:24:51 +0000 (17:24 +0000)
https://bugs.webkit.org/show_bug.cgi?id=143358

Reviewed by Alex Christensen.

.:

* CMakeLists.txt:
* Source/CMakeLists.txt:
* Source/cmake/WebKitFS.cmake:

Source/WebCore:

In order to enforce layering and promote testability, WebCore/platform files
should be compiled in their own project. This new project can enforce layering
and can be tested with unit tests in addition to layout tests.

The name of this new project is the Platform Abstraction Layer, or "PAL."
This comprises of a new directory in WebCore which will be the destination
for files migrated from WebCore/platform. This new folder, and its associated
project, will maintain layering invariants. These invariants are enforced at
build-time by setting the #include path for PAL to not include the rest of
WebCore (which is the same layering enforcement mechanism for WTF). Files will
be migrated into this new target/directory piece-by-piece, and the migration
of a file will be performed as soon as it can be migrated without violating
layering.

Within WebCore, files should include PAL files using the convention
#include <pal/foo.h>. Symbols within PAL are placed within a new top-level
namespace, "PAL," and therefore when used should be referred to as PAL::Foo.

The first set of files to move into the new platform is the crypto/ subdirectory
because it is both simple but also includes platform-dependent files.

No new tests because there is no behavior change.

* CMakeLists.txt:
* Configurations/WebCore.xcconfig: Add PAL to the include path
* PAL/Configurations/Base.xcconfig: Added.
* PAL/Configurations/DebugRelease.xcconfig: Added.
* PAL/Configurations/PAL.xcconfig: Added. Sets up some PAL-specific
variables.
* PAL/Configurations/FeatureDefines.xcconfig: Added.
* PAL/Configurations/Version.xcconfig: Added.
* PAL/PAL.xcodeproj/project.pbxproj: Added. New project file.
* PAL/config.h: Added. Simplified from WebCore/config.h.
* PAL/pal/CMakeLists.txt: Added.
* PAL/pal/PlatformEfl.cmake: Added.
* PAL/pal/PlatformGTK.cmake: Added.
* PAL/pal/PlatformMac.cmake: Added.
* PAL/pal/PlatformWin.cmake: Added.
* PAL/pal/crypto/CryptoDigest.h: Renamed from Source/WebCore/platform/crypto/CryptoDigest.h.
* PAL/pal/crypto/commoncrypto/CryptoDigestCommonCrypto.cpp: Renamed from Source/WebCore/platform/crypto/commoncrypto/CryptoDigestCommonCrypto.cpp.
* PAL/pal/crypto/gcrypt/CryptoDigestGCrypt.cpp: Renamed from Source/WebCore/platform/crypto/gcrypt/CryptoDigestGCrypt.cpp.
* PAL/pal/crypto/gnutls/CryptoDigestGnuTLS.cpp: Renamed from Source/WebCore/platform/crypto/gnutls/CryptoDigestGnuTLS.cpp.
* PAL/pal/crypto/win/CryptoDigestWin.cpp: Renamed from Source/WebCore/platform/crypto/win/CryptoDigestWin.cpp.
* PlatformEfl.cmake:
* PlatformGTK.cmake:
* PlatformMac.cmake:
* PlatformWin.cmake:
* WebCore.xcodeproj/project.pbxproj: Create a project link so WebCore
knows that it needs to build PAL as a dependency.
* crypto/algorithms/CryptoAlgorithmSHA1.cpp:
(WebCore::CryptoAlgorithmSHA1::digest): Update #include and namespace.
* crypto/algorithms/CryptoAlgorithmSHA224.cpp:
(WebCore::CryptoAlgorithmSHA224::digest): Ditto.
* crypto/algorithms/CryptoAlgorithmSHA256.cpp:
(WebCore::CryptoAlgorithmSHA256::digest): Ditto.
* crypto/algorithms/CryptoAlgorithmSHA384.cpp:
(WebCore::CryptoAlgorithmSHA384::digest): Ditto.
* crypto/algorithms/CryptoAlgorithmSHA512.cpp:
(WebCore::CryptoAlgorithmSHA512::digest): Ditto.
* crypto/mac/CryptoAlgorithmRSASSA_PKCS1_v1_5Mac.cpp:
(WebCore::cryptoDigestAlgorithm): Ditto.
(WebCore::signRSASSA_PKCS1_v1_5): Ditto.
(WebCore::verifyRSASSA_PKCS1_v1_5): Ditto.
* inspector/InspectorDOMAgent.cpp:
(WebCore::computeContentSecurityPolicySHA256Hash): Ditto.
* page/csp/ContentSecurityPolicy.cpp:
(WebCore::toCryptoDigestAlgorithm): Ditto.
(WebCore::ContentSecurityPolicy::findHashOfContentInPolicies): Ditto.
* platform/network/soup/SoupNetworkSession.cpp:
(WebCore::HostTLSCertificateSet::computeCertificateHash): Ditto.

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

46 files changed:
CMakeLists.txt
ChangeLog
Source/CMakeLists.txt
Source/JavaScriptCore/Configurations/FeatureDefines.xcconfig
Source/WebCore/CMakeLists.txt
Source/WebCore/ChangeLog
Source/WebCore/Configurations/FeatureDefines.xcconfig
Source/WebCore/Configurations/WebCore.xcconfig
Source/WebCore/PAL/Configurations/Base.xcconfig [new file with mode: 0644]
Source/WebCore/PAL/Configurations/DebugRelease.xcconfig [new file with mode: 0644]
Source/WebCore/PAL/Configurations/FeatureDefines.xcconfig [new file with mode: 0644]
Source/WebCore/PAL/Configurations/PAL.xcconfig [new file with mode: 0644]
Source/WebCore/PAL/Configurations/Version.xcconfig [new file with mode: 0644]
Source/WebCore/PAL/PAL.xcodeproj/project.pbxproj [new file with mode: 0644]
Source/WebCore/PAL/config.h [new file with mode: 0644]
Source/WebCore/PAL/pal/CMakeLists.txt [new file with mode: 0644]
Source/WebCore/PAL/pal/PlatformEfl.cmake [new file with mode: 0644]
Source/WebCore/PAL/pal/PlatformGTK.cmake [new file with mode: 0644]
Source/WebCore/PAL/pal/PlatformMac.cmake [new file with mode: 0644]
Source/WebCore/PAL/pal/PlatformWin.cmake [new file with mode: 0644]
Source/WebCore/PAL/pal/crypto/CryptoDigest.h [moved from Source/WebCore/platform/crypto/CryptoDigest.h with 94% similarity]
Source/WebCore/PAL/pal/crypto/commoncrypto/CryptoDigestCommonCrypto.cpp [moved from Source/WebCore/platform/crypto/commoncrypto/CryptoDigestCommonCrypto.cpp with 99% similarity]
Source/WebCore/PAL/pal/crypto/gcrypt/CryptoDigestGCrypt.cpp [moved from Source/WebCore/platform/crypto/gcrypt/CryptoDigestGCrypt.cpp with 98% similarity]
Source/WebCore/PAL/pal/crypto/gnutls/CryptoDigestGnuTLS.cpp [moved from Source/WebCore/platform/crypto/gnutls/CryptoDigestGnuTLS.cpp with 98% similarity]
Source/WebCore/PAL/pal/crypto/win/CryptoDigestWin.cpp [moved from Source/WebCore/platform/crypto/win/CryptoDigestWin.cpp with 98% similarity]
Source/WebCore/PlatformEfl.cmake
Source/WebCore/PlatformGTK.cmake
Source/WebCore/PlatformMac.cmake
Source/WebCore/PlatformWin.cmake
Source/WebCore/WebCore.xcodeproj/project.pbxproj
Source/WebCore/crypto/algorithms/CryptoAlgorithmSHA1.cpp
Source/WebCore/crypto/algorithms/CryptoAlgorithmSHA224.cpp
Source/WebCore/crypto/algorithms/CryptoAlgorithmSHA256.cpp
Source/WebCore/crypto/algorithms/CryptoAlgorithmSHA384.cpp
Source/WebCore/crypto/algorithms/CryptoAlgorithmSHA512.cpp
Source/WebCore/crypto/mac/CryptoAlgorithmRSASSA_PKCS1_v1_5Mac.cpp
Source/WebCore/inspector/InspectorDOMAgent.cpp
Source/WebCore/page/csp/ContentSecurityPolicy.cpp
Source/WebCore/platform/network/soup/SoupNetworkSession.cpp
Source/WebKit/CMakeLists.txt
Source/WebKit/mac/Configurations/FeatureDefines.xcconfig
Source/WebKit2/Configurations/FeatureDefines.xcconfig
Source/cmake/OptionsWin.cmake
Source/cmake/WebKitFS.cmake
Tools/Scripts/webkitpy/style/checkers/featuredefines.py
Tools/TestWebKitAPI/Configurations/FeatureDefines.xcconfig

index bf3c4ef..bb3318c 100644 (file)
@@ -114,6 +114,7 @@ else ()
 endif ()
 
 set(JavaScriptCore_LIBRARY_TYPE SHARED)
+set(PAL_LIBRARY_TYPE STATIC)
 set(WebKit_LIBRARY_TYPE SHARED)
 set(WebKit2_LIBRARY_TYPE SHARED)
 set(WebCoreTestSupport_LIBRARY_TYPE STATIC)
index c88999d..80555a0 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,14 @@
+2017-01-22  Don Olmstead <don.olmstead@am.sony.com> and Myles C. Maxfield <mmaxfield@apple.com>
+
+        Introducing the Platform Abstraction Layer (PAL)
+        https://bugs.webkit.org/show_bug.cgi?id=143358
+
+        Reviewed by Alex Christensen.
+
+        * CMakeLists.txt:
+        * Source/CMakeLists.txt:
+        * Source/cmake/WebKitFS.cmake:
+
 2017-01-20  Joseph Pecoraro  <pecoraro@apple.com>
 
         Remove outdated ENABLE(CSP_NEXT) build flag
index 1b8a2dc..15fdf22 100644 (file)
@@ -46,6 +46,7 @@ WEBKIT_SET_EXTRA_COMPILER_FLAGS(WTF ${ADDITIONAL_COMPILER_FLAGS})
 WEBKIT_SET_EXTRA_COMPILER_FLAGS(JavaScriptCore ${ADDITIONAL_COMPILER_FLAGS})
 
 if (ENABLE_WEBCORE)
+    WEBKIT_SET_EXTRA_COMPILER_FLAGS(PAL ${ADDITIONAL_COMPILER_FLAGS})
     WEBKIT_SET_EXTRA_COMPILER_FLAGS(WebCoreTestSupport ${ADDITIONAL_COMPILER_FLAGS})
     WEBKIT_SET_EXTRA_COMPILER_FLAGS(WebCore ${ADDITIONAL_COMPILER_FLAGS})
     WEBKIT_SET_EXTRA_COMPILER_FLAGS(WebCoreDerivedSources ${ADDITIONAL_COMPILER_FLAGS})
index 2d043a0..9a58f9d 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2009, 2010, 2014, 2015, 2016 Apple Inc. All rights reserved.
+// Copyright (C) 2009, 2010, 2014, 2015, 2016, 2017 Apple Inc. All rights reserved.
 // Copyright (C) 2009 Google Inc. All rights reserved.
 //
 // Redistribution and use in source and binary forms, with or without
index b5043c5..68a5973 100644 (file)
@@ -1,6 +1,7 @@
 cmake_minimum_required(VERSION 2.8.12)
 include(WebKitCommon)
 set_property(DIRECTORY . PROPERTY FOLDER "WebCore")
+add_subdirectory(PAL/pal)
 
 set(WebCore_INCLUDE_DIRECTORIES
     "${CMAKE_BINARY_DIR}"
@@ -2945,6 +2946,7 @@ set(WebCore_PLUG_INS_RESOURCES
 set(WebCore_LIBRARIES
     ${ICU_LIBRARIES}
     JavaScriptCore${DEBUG_SUFFIX}
+    PAL${DEBUG_SUFFIX}
 )
 
 if (ENABLE_LEGACY_ENCRYPTED_MEDIA)
index 6f49453..bcf2dcf 100644 (file)
@@ -1,3 +1,81 @@
+2017-01-22  Don Olmstead <don.olmstead@am.sony.com> and Myles C. Maxfield <mmaxfield@apple.com>
+
+        Introducing the Platform Abstraction Layer (PAL)
+        https://bugs.webkit.org/show_bug.cgi?id=143358
+
+        Reviewed by Alex Christensen.
+
+        In order to enforce layering and promote testability, WebCore/platform files
+        should be compiled in their own project. This new project can enforce layering
+        and can be tested with unit tests in addition to layout tests.
+
+        The name of this new project is the Platform Abstraction Layer, or "PAL."
+        This comprises of a new directory in WebCore which will be the destination
+        for files migrated from WebCore/platform. This new folder, and its associated
+        project, will maintain layering invariants. These invariants are enforced at
+        build-time by setting the #include path for PAL to not include the rest of
+        WebCore (which is the same layering enforcement mechanism for WTF). Files will
+        be migrated into this new target/directory piece-by-piece, and the migration
+        of a file will be performed as soon as it can be migrated without violating
+        layering.
+
+        Within WebCore, files should include PAL files using the convention
+        #include <pal/foo.h>. Symbols within PAL are placed within a new top-level
+        namespace, "PAL," and therefore when used should be referred to as PAL::Foo.
+
+        The first set of files to move into the new platform is the crypto/ subdirectory
+        because it is both simple but also includes platform-dependent files.
+
+        No new tests because there is no behavior change.
+
+        * CMakeLists.txt:
+        * Configurations/WebCore.xcconfig: Add PAL to the include path
+        * PAL/Configurations/Base.xcconfig: Added.
+        * PAL/Configurations/DebugRelease.xcconfig: Added.
+        * PAL/Configurations/PAL.xcconfig: Added. Sets up some PAL-specific
+        variables.
+        * PAL/Configurations/FeatureDefines.xcconfig: Added.
+        * PAL/Configurations/Version.xcconfig: Added.
+        * PAL/PAL.xcodeproj/project.pbxproj: Added. New project file.
+        * PAL/config.h: Added. Simplified from WebCore/config.h.
+        * PAL/pal/CMakeLists.txt: Added.
+        * PAL/pal/PlatformEfl.cmake: Added.
+        * PAL/pal/PlatformGTK.cmake: Added.
+        * PAL/pal/PlatformMac.cmake: Added.
+        * PAL/pal/PlatformWin.cmake: Added.
+        * PAL/pal/crypto/CryptoDigest.h: Renamed from Source/WebCore/platform/crypto/CryptoDigest.h.
+        * PAL/pal/crypto/commoncrypto/CryptoDigestCommonCrypto.cpp: Renamed from Source/WebCore/platform/crypto/commoncrypto/CryptoDigestCommonCrypto.cpp.
+        * PAL/pal/crypto/gcrypt/CryptoDigestGCrypt.cpp: Renamed from Source/WebCore/platform/crypto/gcrypt/CryptoDigestGCrypt.cpp.
+        * PAL/pal/crypto/gnutls/CryptoDigestGnuTLS.cpp: Renamed from Source/WebCore/platform/crypto/gnutls/CryptoDigestGnuTLS.cpp.
+        * PAL/pal/crypto/win/CryptoDigestWin.cpp: Renamed from Source/WebCore/platform/crypto/win/CryptoDigestWin.cpp.
+        * PlatformEfl.cmake:
+        * PlatformGTK.cmake:
+        * PlatformMac.cmake:
+        * PlatformWin.cmake:
+        * WebCore.xcodeproj/project.pbxproj: Create a project link so WebCore
+        knows that it needs to build PAL as a dependency.
+        * crypto/algorithms/CryptoAlgorithmSHA1.cpp:
+        (WebCore::CryptoAlgorithmSHA1::digest): Update #include and namespace.
+        * crypto/algorithms/CryptoAlgorithmSHA224.cpp:
+        (WebCore::CryptoAlgorithmSHA224::digest): Ditto.
+        * crypto/algorithms/CryptoAlgorithmSHA256.cpp:
+        (WebCore::CryptoAlgorithmSHA256::digest): Ditto.
+        * crypto/algorithms/CryptoAlgorithmSHA384.cpp:
+        (WebCore::CryptoAlgorithmSHA384::digest): Ditto.
+        * crypto/algorithms/CryptoAlgorithmSHA512.cpp:
+        (WebCore::CryptoAlgorithmSHA512::digest): Ditto.
+        * crypto/mac/CryptoAlgorithmRSASSA_PKCS1_v1_5Mac.cpp:
+        (WebCore::cryptoDigestAlgorithm): Ditto.
+        (WebCore::signRSASSA_PKCS1_v1_5): Ditto.
+        (WebCore::verifyRSASSA_PKCS1_v1_5): Ditto.
+        * inspector/InspectorDOMAgent.cpp:
+        (WebCore::computeContentSecurityPolicySHA256Hash): Ditto.
+        * page/csp/ContentSecurityPolicy.cpp:
+        (WebCore::toCryptoDigestAlgorithm): Ditto.
+        (WebCore::ContentSecurityPolicy::findHashOfContentInPolicies): Ditto.
+        * platform/network/soup/SoupNetworkSession.cpp:
+        (WebCore::HostTLSCertificateSet::computeCertificateHash): Ditto.
+
 2017-01-22  Zan Dobersek  <zdobersek@igalia.com>
 
         [GStreamer] Clear out m_appsinkCaps in AppendPipeline::appsinkCapsChanged() before using outPtr()
index 2d043a0..9a58f9d 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2009, 2010, 2014, 2015, 2016 Apple Inc. All rights reserved.
+// Copyright (C) 2009, 2010, 2014, 2015, 2016, 2017 Apple Inc. All rights reserved.
 // Copyright (C) 2009 Google Inc. All rights reserved.
 //
 // Redistribution and use in source and binary forms, with or without
index 6b19acf..d5bf298 100644 (file)
@@ -46,7 +46,7 @@ OTHER_CPLUSPLUSFLAGS = $(OTHER_CFLAGS);
 
 WEBKITADDITIONS_HEADER_SEARCH_PATHS = $(BUILT_PRODUCTS_DIR)/usr/local/include/WebKitAdditions $(SDKROOT)/usr/local/include/WebKitAdditions;
 
-HEADER_SEARCH_PATHS = ForwardingHeaders icu /usr/include/libxslt /usr/include/libxml2 "$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore" "$(BUILT_PRODUCTS_DIR)/usr/local/include" $(WEBKITADDITIONS_HEADER_SEARCH_PATHS) $(HEADER_SEARCH_PATHS);
+HEADER_SEARCH_PATHS = PAL ForwardingHeaders icu /usr/include/libxslt /usr/include/libxml2 "$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore" "$(BUILT_PRODUCTS_DIR)/usr/local/include" $(WEBKITADDITIONS_HEADER_SEARCH_PATHS) $(HEADER_SEARCH_PATHS);
 INFOPLIST_FILE = Info.plist;
 INSTALL_PATH = $(SYSTEM_LIBRARY_DIR)/PrivateFrameworks;
 INSTALL_PATH[sdk=macosx*] = $(WEBCORE_FRAMEWORKS_DIR);
diff --git a/Source/WebCore/PAL/Configurations/Base.xcconfig b/Source/WebCore/PAL/Configurations/Base.xcconfig
new file mode 100644 (file)
index 0000000..dd7baa8
--- /dev/null
@@ -0,0 +1,121 @@
+// Copyright (C) 2017 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.
+//
+// THIS SOFTWARE IS PROVIDED BY APPLE INC. ``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 INC. OR
+// 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. 
+
+#include "../../../../../Internal/Configurations/HaveInternalSDK.xcconfig"
+
+USE_INTERNAL_SDK = $(USE_INTERNAL_SDK_$(CONFIGURATION));
+USE_INTERNAL_SDK_Production = YES;
+USE_INTERNAL_SDK_Debug = $(HAVE_INTERNAL_SDK);
+USE_INTERNAL_SDK_Release = $(HAVE_INTERNAL_SDK);
+
+CLANG_CXX_LANGUAGE_STANDARD = gnu++14;
+CLANG_CXX_LIBRARY = libc++;
+CLANG_WARN_BOOL_CONVERSION = YES;
+CLANG_WARN_CONSTANT_CONVERSION = YES;
+CLANG_WARN_CXX0X_EXTENSIONS = NO;
+CLANG_WARN_EMPTY_BODY = YES;
+CLANG_WARN_ENUM_CONVERSION = YES;
+CLANG_WARN_INFINITE_RECURSION = YES;
+CLANG_WARN_INT_CONVERSION = YES;
+CLANG_WARN_SUSPICIOUS_MOVE = YES;
+CLANG_WARN_UNREACHABLE_CODE = YES;
+CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
+GCC_WARN_UNDECLARED_SELECTOR = YES;
+COMBINE_HIDPI_IMAGES = NO;
+DEBUG_INFORMATION_FORMAT = dwarf-with-dsym;
+ENABLE_STRICT_OBJC_MSGSEND = YES;
+GCC_C_LANGUAGE_STANDARD = gnu99;
+GCC_DEBUGGING_SYMBOLS = default;
+GCC_DYNAMIC_NO_PIC = NO;
+GCC_ENABLE_CPP_EXCEPTIONS = NO;
+GCC_ENABLE_CPP_RTTI = NO;
+GCC_ENABLE_OBJC_EXCEPTIONS = YES;
+GCC_ENABLE_SYMBOL_SEPARATION = NO;
+GCC_FAST_OBJC_DISPATCH = YES;
+GCC_GENERATE_DEBUGGING_SYMBOLS = YES;
+GCC_NO_COMMON_BLOCKS = YES;
+GCC_OBJC_CALL_CXX_CDTORS = YES;
+GCC_PRECOMPILE_PREFIX_HEADER = YES;
+GCC_SYMBOLS_PRIVATE_EXTERN = YES;
+GCC_THREADSAFE_STATICS = NO;
+GCC_TREAT_WARNINGS_AS_ERRORS = YES;
+GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
+// FIXME: <http://webkit.org/b/109846> WebCore should build with -Wshorten-64-to-32
+GCC_WARN_64_TO_32_BIT_CONVERSION = $(GCC_WARN_64_TO_32_BIT_CONVERSION_$(CURRENT_ARCH));
+GCC_WARN_64_TO_32_BIT_CONVERSION_ = YES;
+GCC_WARN_64_TO_32_BIT_CONVERSION_armv7 = YES;
+GCC_WARN_64_TO_32_BIT_CONVERSION_armv7k = YES;
+GCC_WARN_64_TO_32_BIT_CONVERSION_armv7s = YES;
+GCC_WARN_64_TO_32_BIT_CONVERSION_arm64 = NO;
+GCC_WARN_64_TO_32_BIT_CONVERSION_i386 = YES;
+GCC_WARN_64_TO_32_BIT_CONVERSION_x86_64 = NO;
+GCC_WARN_ABOUT_DEPRECATED_FUNCTIONS = NO;
+GCC_WARN_ABOUT_MISSING_NEWLINE = YES;
+GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
+GCC_WARN_ABOUT_RETURN_TYPE = YES;
+GCC_WARN_NON_VIRTUAL_DESTRUCTOR = YES;
+GCC_WARN_SIGN_COMPARE = YES;
+GCC_WARN_UNINITIALIZED_AUTOS = YES;
+GCC_WARN_UNUSED_FUNCTION = YES;
+GCC_WARN_UNUSED_VARIABLE = YES;
+PREBINDING = NO;
+WARNING_CFLAGS = -Wall -Wextra -Wcast-qual -Wchar-subscripts -Wextra-tokens -Wformat=2 -Winit-self -Wmissing-format-attribute -Wmissing-noreturn -Wpacked -Wpointer-arith -Wredundant-decls -Wundef -Wwrite-strings -Wexit-time-destructors -Wglobal-constructors -Wtautological-compare -Wimplicit-fallthrough -Wno-unknown-warning-option;
+
+TARGET_MAC_OS_X_VERSION_MAJOR = $(TARGET_MAC_OS_X_VERSION_MAJOR$(MACOSX_DEPLOYMENT_TARGET:suffix:identifier));
+TARGET_MAC_OS_X_VERSION_MAJOR_10 = 101000;
+TARGET_MAC_OS_X_VERSION_MAJOR_11 = 101100;
+TARGET_MAC_OS_X_VERSION_MAJOR_12 = 101200;
+TARGET_MAC_OS_X_VERSION_MAJOR_13 = 101300;
+
+WK_TARGET_IOS_VERSION_MAJOR = $(IPHONEOS_DEPLOYMENT_TARGET:base); // iOS 9.3 => 9
+
+SUPPORTED_PLATFORMS = iphoneos iphonesimulator macosx appletvos appletvsimulator watchos watchsimulator;
+
+// DEBUG_DEFINES, GCC_OPTIMIZATION_LEVEL, STRIP_INSTALLED_PRODUCT and DEAD_CODE_STRIPPING vary between the debug and normal variants.
+// We set up the values for each variant here, and have the Debug configuration in the Xcode project use the _debug variant.
+DEBUG_DEFINES_debug = ;
+DEBUG_DEFINES_normal = NDEBUG;
+DEBUG_DEFINES = $(DEBUG_DEFINES_$(CURRENT_VARIANT));
+
+GCC_OPTIMIZATION_LEVEL = $(GCC_OPTIMIZATION_LEVEL_$(CURRENT_VARIANT));
+GCC_OPTIMIZATION_LEVEL_normal[sdk=iphone*] = 3;
+GCC_OPTIMIZATION_LEVEL_normal[sdk=macosx*] = 2;
+GCC_OPTIMIZATION_LEVEL_debug = 0;
+
+STRIP_INSTALLED_PRODUCT = $(STRIP_INSTALLED_PRODUCT_$(CURRENT_VARIANT));
+STRIP_INSTALLED_PRODUCT_normal = YES;
+STRIP_INSTALLED_PRODUCT_debug = NO;
+
+DEAD_CODE_STRIPPING_debug = NO;
+DEAD_CODE_STRIPPING_normal = YES;
+DEAD_CODE_STRIPPING = $(DEAD_CODE_STRIPPING_$(CURRENT_VARIANT));
+
+GCC_GENERATE_DEBUGGING_SYMBOLS = YES;
+CLANG_DEBUG_INFORMATION_LEVEL[sdk=macosx10.8*] = line-tables-only;
+CLANG_DEBUG_INFORMATION_LEVEL[sdk=macosx10.9*] = line-tables-only;
+
+SDKROOT = macosx.internal;
+
+OTHER_CFLAGS = $(ASAN_OTHER_CFLAGS);
+OTHER_CPLUSPLUSFLAGS = $(ASAN_OTHER_CPLUSPLUSFLAGS);
+OTHER_LDFLAGS = $(ASAN_OTHER_LDFLAGS);
diff --git a/Source/WebCore/PAL/Configurations/DebugRelease.xcconfig b/Source/WebCore/PAL/Configurations/DebugRelease.xcconfig
new file mode 100644 (file)
index 0000000..b9daa58
--- /dev/null
@@ -0,0 +1,46 @@
+// Copyright (C) 2017 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.
+//
+// THIS SOFTWARE IS PROVIDED BY APPLE INC. ``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 INC. OR
+// 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.
+
+#include "Base.xcconfig"
+
+ARCHS = $(ARCHS_STANDARD_32_64_BIT);
+
+ONLY_ACTIVE_ARCH = YES;
+
+TARGET_MAC_OS_X_VERSION_MAJOR = $(MAC_OS_X_VERSION_MAJOR);
+
+MACOSX_DEPLOYMENT_TARGET = $(MACOSX_DEPLOYMENT_TARGET_$(PLATFORM_NAME)_$(TARGET_MAC_OS_X_VERSION_MAJOR));
+MACOSX_DEPLOYMENT_TARGET_macosx_101000 = 10.10;
+MACOSX_DEPLOYMENT_TARGET_macosx_101100 = 10.11;
+MACOSX_DEPLOYMENT_TARGET_macosx_101200 = 10.12;
+MACOSX_DEPLOYMENT_TARGET_macosx_101300 = 10.13;
+
+GCC_WARN_ABOUT_DEPRECATED_FUNCTIONS = YES;
+DEBUG_INFORMATION_FORMAT = dwarf;
+
+CLANG_DEBUG_INFORMATION_LEVEL[sdk=macosx10.8*] = default;
+CLANG_DEBUG_INFORMATION_LEVEL[sdk=macosx10.9*] = default;
+
+SDKROOT = $(SDKROOT_$(USE_INTERNAL_SDK));
+SDKROOT_ = macosx;
+SDKROOT_YES = macosx.internal;
diff --git a/Source/WebCore/PAL/Configurations/FeatureDefines.xcconfig b/Source/WebCore/PAL/Configurations/FeatureDefines.xcconfig
new file mode 100644 (file)
index 0000000..9a58f9d
--- /dev/null
@@ -0,0 +1,219 @@
+// Copyright (C) 2009, 2010, 2014, 2015, 2016, 2017 Apple Inc. All rights reserved.
+// Copyright (C) 2009 Google 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.
+//
+// THIS SOFTWARE IS PROVIDED BY APPLE INC. ``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 INC. OR
+// 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.
+
+// The contents of this file must be kept in sync with FeatureDefines.xcconfig in JavaScriptCore,
+// WebCore, WebKit and WebKit2.  Also the default values of the ENABLE_FEATURE_NAME macros in
+// build-webkit should match the values below, but they do not need to be in the same order.
+
+// Keep this list of features (not enabled/disabled state) in sync with FeatureDefines.vsprops
+// and FeatureDefinesCairo.vsprops in WebKitLibraries/win/tools/vsprops.
+
+// Set any ENABLE_FEATURE_NAME macro to an empty string to disable that feature.
+
+TARGET_MAC_OS_X_VERSION_LESS_THAN_1012000 = $(TARGET_MAC_OS_X_VERSION_LESS_THAN_1012000_$(TARGET_MAC_OS_X_VERSION_MAJOR));
+TARGET_MAC_OS_X_VERSION_LESS_THAN_1012000_101000 = YES;
+TARGET_MAC_OS_X_VERSION_LESS_THAN_1012000_101100 = YES;
+
+ENABLE_3D_TRANSFORMS = ENABLE_3D_TRANSFORMS;
+ENABLE_ACCELERATED_2D_CANVAS = ;
+ENABLE_ACCELERATED_OVERFLOW_SCROLLING[sdk=iphone*] = ENABLE_ACCELERATED_OVERFLOW_SCROLLING;
+
+ENABLE_APPLE_PAY[sdk=iphone*] = $(ENABLE_APPLE_PAY_$(PLATFORM_NAME));
+ENABLE_APPLE_PAY_iphoneos = ENABLE_APPLE_PAY;
+ENABLE_APPLE_PAY_iphonesimulator = ENABLE_APPLE_PAY;
+ENABLE_APPLE_PAY[sdk=iphoneos9*] = ;
+ENABLE_APPLE_PAY[sdk=iphonesimulator9*] = ;
+
+DISABLE_APPLE_PAY_macosx = $(TARGET_MAC_OS_X_VERSION_LESS_THAN_1012000);
+ENABLE_APPLE_PAY[sdk=macosx*] = $(ENABLE_APPLE_PAY_IF_NOT_$(DISABLE_APPLE_PAY_macosx));
+ENABLE_APPLE_PAY_IF_NOT_ = $(ENABLE_APPLE_PAY_IF_NOT_NO);
+ENABLE_APPLE_PAY_IF_NOT_NO = ENABLE_APPLE_PAY;
+ENABLE_APPLE_PAY_IF_NOT_YES = ;
+
+ENABLE_ATTACHMENT_ELEMENT = ENABLE_ATTACHMENT_ELEMENT;
+ENABLE_AVF_CAPTIONS = ENABLE_AVF_CAPTIONS;
+ENABLE_CACHE_PARTITIONING = ENABLE_CACHE_PARTITIONING;
+ENABLE_CANVAS_PATH = ENABLE_CANVAS_PATH;
+ENABLE_CANVAS_PROXY = ;
+ENABLE_CHANNEL_MESSAGING = ENABLE_CHANNEL_MESSAGING;
+ENABLE_ENCRYPTED_MEDIA = ;
+ENABLE_CONTENT_FILTERING[sdk=appletv*] = ;
+ENABLE_CONTENT_FILTERING[sdk=iphone*] = ENABLE_CONTENT_FILTERING;
+ENABLE_CONTENT_FILTERING[sdk=macosx*] = ENABLE_CONTENT_FILTERING;
+ENABLE_CSS_ANIMATIONS_LEVEL_2 = ENABLE_CSS_ANIMATIONS_LEVEL_2;
+ENABLE_CSS_BOX_DECORATION_BREAK = ENABLE_CSS_BOX_DECORATION_BREAK;
+ENABLE_CSS_COMPOSITING = ENABLE_CSS_COMPOSITING;
+ENABLE_CSS_DEVICE_ADAPTATION = ;
+ENABLE_CSS_GRID_LAYOUT = ENABLE_CSS_GRID_LAYOUT;
+ENABLE_CSS_IMAGE_ORIENTATION = ;
+ENABLE_CSS_IMAGE_RESOLUTION = ;
+ENABLE_CSS_REGIONS = ENABLE_CSS_REGIONS;
+ENABLE_CSS_SELECTORS_LEVEL4 = ENABLE_CSS_SELECTORS_LEVEL4;
+ENABLE_CSS3_TEXT = ;
+ENABLE_CURSOR_VISIBILITY = ENABLE_CURSOR_VISIBILITY;
+ENABLE_CUSTOM_SCHEME_HANDLER = ;
+ENABLE_DASHBOARD_SUPPORT[sdk=macosx*] = ENABLE_DASHBOARD_SUPPORT;
+ENABLE_DATALIST_ELEMENT = ;
+ENABLE_DATA_TRANSFER_ITEMS = ;
+ENABLE_DEVICE_ORIENTATION[sdk=iphone*] = ENABLE_DEVICE_ORIENTATION;
+ENABLE_FETCH_API = ENABLE_FETCH_API;
+ENABLE_FILTERS_LEVEL_2 = ENABLE_FILTERS_LEVEL_2;
+ENABLE_FONT_LOAD_EVENTS = ;
+ENABLE_FULLSCREEN_API[sdk=macosx*] = ENABLE_FULLSCREEN_API;
+ENABLE_GAMEPAD = ENABLE_GAMEPAD;
+ENABLE_GAMEPAD[sdk=watch*] = ;
+ENABLE_GAMEPAD_DEPRECATED = ;
+ENABLE_GEOLOCATION = ENABLE_GEOLOCATION;
+ENABLE_ICONDATABASE[sdk=macosx*] = ENABLE_ICONDATABASE;
+ENABLE_INTERSECTION_OBSERVER = ENABLE_INTERSECTION_OBSERVER;
+ENABLE_SERVICE_CONTROLS[sdk=macosx*] = ENABLE_SERVICE_CONTROLS;
+ENABLE_INDEXED_DATABASE = ENABLE_INDEXED_DATABASE;
+ENABLE_INDEXED_DATABASE_IN_WORKERS = ENABLE_INDEXED_DATABASE_IN_WORKERS;
+ENABLE_INPUT_TYPE_COLOR[sdk=macosx*] = ENABLE_INPUT_TYPE_COLOR;
+ENABLE_INPUT_TYPE_COLOR_POPOVER[sdk=macosx*] = ENABLE_INPUT_TYPE_COLOR_POPOVER;
+ENABLE_INPUT_TYPE_DATE[sdk=iphone*] = ENABLE_INPUT_TYPE_DATE;
+ENABLE_INPUT_TYPE_DATETIME_INCOMPLETE = ;
+ENABLE_INPUT_TYPE_DATETIMELOCAL[sdk=iphone*] = ENABLE_INPUT_TYPE_DATETIMELOCAL;
+ENABLE_INPUT_TYPE_MONTH[sdk=iphone*] = ENABLE_INPUT_TYPE_MONTH;
+ENABLE_INPUT_TYPE_TIME[sdk=iphone*] = ENABLE_INPUT_TYPE_TIME;
+ENABLE_INPUT_TYPE_WEEK[sdk=iphone*] = ENABLE_INPUT_TYPE_WEEK;
+
+ENABLE_INSPECTOR_ALTERNATE_DISPATCHERS = ENABLE_INSPECTOR_ALTERNATE_DISPATCHERS;
+
+ENABLE_WIRELESS_PLAYBACK_TARGET[sdk=iphone*] = ENABLE_WIRELESS_PLAYBACK_TARGET;
+ENABLE_WIRELESS_PLAYBACK_TARGET[sdk=macosx*] = $(ENABLE_WIRELESS_PLAYBACK_TARGET_macosx_$(TARGET_MAC_OS_X_VERSION_MAJOR))
+ENABLE_WIRELESS_PLAYBACK_TARGET_macosx_101000 = ;
+ENABLE_WIRELESS_PLAYBACK_TARGET_macosx_101100 = ENABLE_WIRELESS_PLAYBACK_TARGET;
+ENABLE_WIRELESS_PLAYBACK_TARGET_macosx_101200 = ENABLE_WIRELESS_PLAYBACK_TARGET;
+ENABLE_WIRELESS_PLAYBACK_TARGET_macosx_101300 = ENABLE_WIRELESS_PLAYBACK_TARGET;
+
+ENABLE_INTL = ENABLE_INTL;
+
+ENABLE_IOS_GESTURE_EVENTS = ;
+ENABLE_IOS_GESTURE_EVENTS[sdk=iphone*] = $(ENABLE_IOS_GESTURE_EVENTS_ios_WITH_INTERNAL_SDK_$(USE_INTERNAL_SDK));
+ENABLE_IOS_GESTURE_EVENTS_ios_WITH_INTERNAL_SDK_YES = ENABLE_IOS_GESTURE_EVENTS;
+
+ENABLE_MAC_GESTURE_EVENTS = ;
+ENABLE_MAC_GESTURE_EVENTS[sdk=macosx*] = $(ENABLE_MAC_GESTURE_EVENTS_macosx_WITH_INTERNAL_SDK_$(USE_INTERNAL_SDK));
+ENABLE_MAC_GESTURE_EVENTS_macosx_WITH_INTERNAL_SDK_YES = ENABLE_MAC_GESTURE_EVENTS;
+
+ENABLE_TEXT_AUTOSIZING = ENABLE_TEXT_AUTOSIZING;
+ENABLE_DATA_DETECTION = ENABLE_DATA_DETECTION;
+
+ENABLE_IOS_TOUCH_EVENTS[sdk=iphone*] = $(ENABLE_IOS_TOUCH_EVENTS_ios_WITH_INTERNAL_SDK_$(USE_INTERNAL_SDK));
+ENABLE_IOS_TOUCH_EVENTS_ios_WITH_INTERNAL_SDK_YES = ENABLE_IOS_TOUCH_EVENTS;
+
+ENABLE_KEYBOARD_KEY_ATTRIBUTE = ENABLE_KEYBOARD_KEY_ATTRIBUTE;
+ENABLE_KEYBOARD_CODE_ATTRIBUTE = ENABLE_KEYBOARD_CODE_ATTRIBUTE;
+ENABLE_LEGACY_CSS_VENDOR_PREFIXES = ENABLE_LEGACY_CSS_VENDOR_PREFIXES;
+ENABLE_LEGACY_ENCRYPTED_MEDIA[sdk=macosx*] = ENABLE_LEGACY_ENCRYPTED_MEDIA;
+ENABLE_LEGACY_NOTIFICATIONS[sdk=macosx*] = ENABLE_LEGACY_NOTIFICATIONS;
+ENABLE_LEGACY_VENDOR_PREFIXES = ENABLE_LEGACY_VENDOR_PREFIXES;
+ENABLE_LETTERPRESS[sdk=iphone*] = ENABLE_LETTERPRESS;
+ENABLE_LINK_PREFETCH = ;
+ENABLE_MATHML = ENABLE_MATHML;
+ENABLE_MEDIA_CAPTURE[sdk=iphone*] = ENABLE_MEDIA_CAPTURE;
+ENABLE_MEDIA_CONTROLS_SCRIPT = ENABLE_MEDIA_CONTROLS_SCRIPT;
+ENABLE_MEDIA_SESSION = ;
+
+ENABLE_MEDIA_SOURCE[sdk=macosx*] = ENABLE_MEDIA_SOURCE;
+
+ENABLE_MEDIA_STATISTICS = ;
+ENABLE_MEDIA_STREAM = ENABLE_MEDIA_STREAM;
+ENABLE_METER_ELEMENT = ENABLE_METER_ELEMENT;
+ENABLE_MHTML = ;
+ENABLE_MOUSE_CURSOR_SCALE[sdk=macosx*] = ENABLE_MOUSE_CURSOR_SCALE;
+ENABLE_NAVIGATOR_CONTENT_UTILS = ;
+ENABLE_NAVIGATOR_HWCONCURRENCY = ENABLE_NAVIGATOR_HWCONCURRENCY;
+ENABLE_NOSNIFF = ;
+ENABLE_NOTIFICATIONS[sdk=macosx*] = ENABLE_NOTIFICATIONS;
+ENABLE_PDFKIT_PLUGIN[sdk=macosx*] = ENABLE_PDFKIT_PLUGIN;
+ENABLE_POINTER_LOCK[sdk=macosx*] = ENABLE_POINTER_LOCK;
+ENABLE_PROXIMITY_EVENTS = ;
+ENABLE_PUBLIC_SUFFIX_LIST = ENABLE_PUBLIC_SUFFIX_LIST;
+ENABLE_QUOTA = ;
+ENABLE_READABLE_STREAM_API = ENABLE_READABLE_STREAM_API;
+ENABLE_READABLE_BYTE_STREAM_API = ENABLE_READABLE_BYTE_STREAM_API;
+ENABLE_REQUEST_AUTOCOMPLETE = ;
+ENABLE_REMOTE_INSPECTOR = ENABLE_REMOTE_INSPECTOR;
+ENABLE_RESOLUTION_MEDIA_QUERY = ;
+ENABLE_RESOURCE_USAGE = ENABLE_RESOURCE_USAGE;
+ENABLE_RUBBER_BANDING[sdk=macosx*] = ENABLE_RUBBER_BANDING;
+ENABLE_CSS_SCROLL_SNAP = ENABLE_CSS_SCROLL_SNAP;
+ENABLE_SPEECH_SYNTHESIS = ENABLE_SPEECH_SYNTHESIS;
+ENABLE_SUBTLE_CRYPTO = ENABLE_SUBTLE_CRYPTO;
+ENABLE_SVG_FONTS = ENABLE_SVG_FONTS;
+ENABLE_WEB_RTC = ENABLE_WEB_RTC;
+ENABLE_WRITABLE_STREAM_API = ENABLE_WRITABLE_STREAM_API;
+
+ENABLE_TELEPHONE_NUMBER_DETECTION = ENABLE_TELEPHONE_NUMBER_DETECTION;
+
+ENABLE_CSS_TRAILING_WORD = ENABLE_CSS_TRAILING_WORD;
+
+// FIXME: Remove the USE_INTERNAL_SDK condition once we support touch events when building for iOS with
+// the public SDK. We will also need to update FeatureDefines.h.
+ENABLE_TOUCH_EVENTS[sdk=iphone*] = $(ENABLE_TOUCH_EVENTS_ios_WITH_INTERNAL_SDK_$(USE_INTERNAL_SDK));
+ENABLE_TOUCH_EVENTS_ios_WITH_INTERNAL_SDK_YES = ENABLE_TOUCH_EVENTS;
+
+ENABLE_TOUCH_ICON_LOADING = ;
+ENABLE_USERSELECT_ALL = ENABLE_USERSELECT_ALL;
+ENABLE_VIDEO = ENABLE_VIDEO;
+ENABLE_VIDEO_PRESENTATION_MODE[sdk=iphone*] = ENABLE_VIDEO_PRESENTATION_MODE;
+ENABLE_VIDEO_PRESENTATION_MODE[sdk=macosx*] = $(ENABLE_VIDEO_PRESENTATION_MODE_macosx_$(TARGET_MAC_OS_X_VERSION_MAJOR))
+ENABLE_VIDEO_PRESENTATION_MODE_macosx_101200 = ENABLE_VIDEO_PRESENTATION_MODE;
+ENABLE_VIDEO_PRESENTATION_MODE_macosx_101300 = ENABLE_VIDEO_PRESENTATION_MODE;
+ENABLE_VIDEO_TRACK = ENABLE_VIDEO_TRACK;
+ENABLE_DATACUE_VALUE = ENABLE_DATACUE_VALUE;
+ENABLE_VIEW_MODE_CSS_MEDIA = ;
+ENABLE_WEBASSEMBLY = ;
+ENABLE_WEBGL = ENABLE_WEBGL;
+ENABLE_WEBGL2 = ENABLE_WEBGL2;
+ENABLE_WEB_ANIMATIONS = ENABLE_WEB_ANIMATIONS;
+ENABLE_WEB_AUDIO = ENABLE_WEB_AUDIO;
+ENABLE_WEB_REPLAY = $(ENABLE_WEB_REPLAY_$(PLATFORM_NAME)_$(CONFIGURATION));
+ENABLE_WEB_REPLAY_macosx_Debug = ENABLE_WEB_REPLAY;
+ENABLE_WEB_REPLAY_macosx_Release = ENABLE_WEB_REPLAY;
+ENABLE_WEB_SOCKETS = ENABLE_WEB_SOCKETS;
+
+ENABLE_WEB_TIMING = ENABLE_WEB_TIMING;
+ENABLE_USER_TIMING = ;
+
+ENABLE_XSLT = ENABLE_XSLT;
+
+ENABLE_FTL_JIT[sdk=macosx*] = ENABLE_FTL_JIT;
+ENABLE_FTL_JIT[sdk=iphoneos*] = ENABLE_FTL_JIT;
+
+ENABLE_VARIATION_FONTS[sdk=iphone*] = $(ENABLE_VARIATION_FONTS_$(PLATFORM_NAME));
+ENABLE_VARIATION_FONTS_iphoneos = ENABLE_VARIATION_FONTS;
+ENABLE_VARIATION_FONTS_iphonesimulator = ENABLE_VARIATION_FONTS;
+ENABLE_VARIATION_FONTS[sdk=iphoneos9*] = ;
+ENABLE_VARIATION_FONTS[sdk=iphonesimulator9*] = ;
+
+DISABLE_VARIATION_FONTS_macosx = $(TARGET_MAC_OS_X_VERSION_LESS_THAN_1012000);
+ENABLE_VARIATION_FONTS[sdk=macosx*] = $(ENABLE_VARIATION_FONTS_IF_NOT_$(DISABLE_VARIATION_FONTS_macosx));
+ENABLE_VARIATION_FONTS_IF_NOT_ = $(ENABLE_VARIATION_FONTS_IF_NOT_NO);
+ENABLE_VARIATION_FONTS_IF_NOT_NO = ENABLE_VARIATION_FONTS;
+ENABLE_VARIATION_FONTS_IF_NOT_YES = ;
+
+FEATURE_DEFINES = $(ENABLE_3D_TRANSFORMS) $(ENABLE_ACCELERATED_2D_CANVAS) $(ENABLE_ACCELERATED_OVERFLOW_SCROLLING) $(ENABLE_APPLE_PAY) $(ENABLE_ATTACHMENT_ELEMENT) $(ENABLE_AVF_CAPTIONS) $(ENABLE_CACHE_PARTITIONING) $(ENABLE_CANVAS_PATH) $(ENABLE_CANVAS_PROXY) $(ENABLE_CHANNEL_MESSAGING) $(ENABLE_CONTENT_FILTERING) $(ENABLE_CSS_ANIMATIONS_LEVEL_2) $(ENABLE_CSS_BOX_DECORATION_BREAK) $(ENABLE_CSS_COMPOSITING) $(ENABLE_CSS_DEVICE_ADAPTATION) $(ENABLE_CSS_GRID_LAYOUT) $(ENABLE_CSS_IMAGE_ORIENTATION) $(ENABLE_CSS_IMAGE_RESOLUTION) $(ENABLE_CSS_REGIONS) $(ENABLE_CSS_SCROLL_SNAP) $(ENABLE_CSS_SELECTORS_LEVEL4) $(ENABLE_CSS_TRAILING_WORD) $(ENABLE_CSS3_TEXT) $(ENABLE_CURSOR_VISIBILITY) $(ENABLE_CUSTOM_SCHEME_HANDLER) $(ENABLE_DASHBOARD_SUPPORT) $(ENABLE_DATA_TRANSFER_ITEMS) $(ENABLE_DATACUE_VALUE) $(ENABLE_DATALIST_ELEMENT) $(ENABLE_DEVICE_ORIENTATION) $(ENABLE_ENCRYPTED_MEDIA) $(ENABLE_FETCH_API) $(ENABLE_FILTERS_LEVEL_2) $(ENABLE_FONT_LOAD_EVENTS) $(ENABLE_FTL_JIT) $(ENABLE_FULLSCREEN_API) $(ENABLE_GAMEPAD_DEPRECATED) $(ENABLE_GAMEPAD) $(ENABLE_GEOLOCATION) $(ENABLE_ICONDATABASE) $(ENABLE_INDEXED_DATABASE_IN_WORKERS) $(ENABLE_INDEXED_DATABASE) $(ENABLE_INPUT_TYPE_COLOR_POPOVER) $(ENABLE_INPUT_TYPE_COLOR) $(ENABLE_INPUT_TYPE_DATE) $(ENABLE_INPUT_TYPE_DATETIME_INCOMPLETE) $(ENABLE_INPUT_TYPE_DATETIMELOCAL) $(ENABLE_INPUT_TYPE_MONTH) $(ENABLE_INPUT_TYPE_TIME) $(ENABLE_INPUT_TYPE_WEEK) $(ENABLE_INTERSECTION_OBSERVER) $(ENABLE_INTL) $(ENABLE_IOS_GESTURE_EVENTS) $(ENABLE_IOS_TOUCH_EVENTS) $(ENABLE_JIT) $(ENABLE_KEYBOARD_KEY_ATTRIBUTE) $(ENABLE_KEYBOARD_CODE_ATTRIBUTE) $(ENABLE_LEGACY_CSS_VENDOR_PREFIXES) $(ENABLE_LEGACY_ENCRYPTED_MEDIA) $(ENABLE_LEGACY_NOTIFICATIONS) $(ENABLE_LEGACY_VENDOR_PREFIXES) $(ENABLE_LETTERPRESS) $(ENABLE_LINK_PREFETCH) $(ENABLE_MAC_GESTURE_EVENTS) $(ENABLE_MATHML) $(ENABLE_MEDIA_CAPTURE) $(ENABLE_MEDIA_CONTROLS_SCRIPT) $(ENABLE_MEDIA_SESSION) $(ENABLE_MEDIA_SOURCE) $(ENABLE_MEDIA_STATISTICS) $(ENABLE_MEDIA_STREAM) $(ENABLE_METER_ELEMENT) $(ENABLE_MHTML) $(ENABLE_MOUSE_CURSOR_SCALE) $(ENABLE_NAVIGATOR_CONTENT_UTILS) $(ENABLE_NAVIGATOR_HWCONCURRENCY) $(ENABLE_NOTIFICATIONS) $(ENABLE_PDFKIT_PLUGIN) $(ENABLE_POINTER_LOCK) $(ENABLE_PROXIMITY_EVENTS) $(ENABLE_PUBLIC_SUFFIX_LIST) $(ENABLE_QUOTA) $(ENABLE_READABLE_STREAM_API) $(ENABLE_READABLE_BYTE_STREAM_API) $(ENABLE_REMOTE_INSPECTOR) $(ENABLE_REQUEST_AUTOCOMPLETE) $(ENABLE_RESOLUTION_MEDIA_QUERY) $(ENABLE_RESOURCE_USAGE) $(ENABLE_RUBBER_BANDING) $(ENABLE_SERVICE_CONTROLS) $(ENABLE_SPEECH_SYNTHESIS) $(ENABLE_SUBTLE_CRYPTO) $(ENABLE_SVG_FONTS) $(ENABLE_TELEPHONE_NUMBER_DETECTION) $(ENABLE_TEXT_AUTOSIZING) $(ENABLE_TOUCH_EVENTS) $(ENABLE_TOUCH_ICON_LOADING) $(ENABLE_USERSELECT_ALL) $(ENABLE_VARIATION_FONTS) $(ENABLE_VIDEO_PRESENTATION_MODE) $(ENABLE_VIDEO_TRACK) $(ENABLE_VIDEO) $(ENABLE_VIEW_MODE_CSS_MEDIA) $(ENABLE_WEB_ANIMATIONS) $(ENABLE_WEB_AUDIO) $(ENABLE_WEB_REPLAY) $(ENABLE_WEB_RTC) $(ENABLE_WEB_SOCKETS) $(ENABLE_WEB_TIMING) $(ENABLE_USER_TIMING) $(ENABLE_WEBASSEMBLY) $(ENABLE_WEBGL) $(ENABLE_WEBGL2) $(ENABLE_WIRELESS_PLAYBACK_TARGET) $(ENABLE_WRITABLE_STREAM_API) $(ENABLE_XSLT);
diff --git a/Source/WebCore/PAL/Configurations/PAL.xcconfig b/Source/WebCore/PAL/Configurations/PAL.xcconfig
new file mode 100644 (file)
index 0000000..4d5cd14
--- /dev/null
@@ -0,0 +1,84 @@
+// Copyright (C) 2017 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.
+//
+// THIS SOFTWARE IS PROVIDED BY APPLE INC. ``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 INC. OR
+// 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. 
+
+#include "FeatureDefines.xcconfig"
+#include "Version.xcconfig"
+
+GCC_PREPROCESSOR_DEFINITIONS = $(DEBUG_DEFINES) $(FEATURE_DEFINES) $(inherited);
+
+WK_XCODE_SUPPORTS_TEXT_BASED_STUBS = $(WK_NOT_$(WK_EMPTY_$(TAPI_VERIFY_MODE)));
+WK_PRIVATE_FRAMEWORKS_DIR = $(WK_PRIVATE_FRAMEWORKS_DIR_$(USE_INTERNAL_SDK));
+WK_PRIVATE_FRAMEWORKS_DIR_YES = $(PRODUCTION_FRAMEWORKS_DIR);
+WK_PRIVATE_FRAMEWORKS_DIR_[sdk=iphonesimulator*] = $(PRODUCTION_FRAMEWORKS_DIR);
+WK_PRIVATE_FRAMEWORKS_DIR_[sdk=iphoneos*] = $(WK_PRIVATE_FRAMEWORKS_DIR_iphoneos_$(WK_XCODE_SUPPORTS_TEXT_BASED_STUBS));
+WK_PRIVATE_FRAMEWORKS_DIR_iphoneos_YES = $(SRCROOT)/../../WebKitLibraries/WebKitPrivateFrameworkStubs/iOS/$(WK_TARGET_IOS_VERSION_MAJOR);
+WK_PRIVATE_FRAMEWORKS_DIR_iphoneos_NO = $(PRODUCTION_FRAMEWORKS_DIR);
+
+FRAMEWORK_SEARCH_PATHS[sdk=iphone*] = $(FRAMEWORK_SEARCH_PATHS_ios_$(CONFIGURATION));
+FRAMEWORK_SEARCH_PATHS_ios_Debug = $(BUILT_PRODUCTS_DIR) $(WK_PRIVATE_FRAMEWORKS_DIR);
+FRAMEWORK_SEARCH_PATHS_ios_Release = $(FRAMEWORK_SEARCH_PATHS_ios_Debug);
+FRAMEWORK_SEARCH_PATHS_ios_Production = $(PRODUCTION_FRAMEWORKS_DIR);
+FRAMEWORK_SEARCH_PATHS[sdk=macosx*] = $(WK_QUOTED_OVERRIDE_FRAMEWORKS_DIR) $(inherited) $(SDKROOT)$(SYSTEM_LIBRARY_DIR)/PrivateFrameworks;
+
+OTHER_CFLAGS = $(inherited) -iframework $(SDKROOT)$(SYSTEM_LIBRARY_DIR)/Frameworks/Carbon.framework/Frameworks -iframework $(SDKROOT)$(SYSTEM_LIBRARY_DIR)/Frameworks/ApplicationServices.framework/Frameworks -iframework $(SDKROOT)$(SYSTEM_LIBRARY_DIR)/Frameworks/CoreServices.framework/Frameworks -iframework $(SDKROOT)$(SYSTEM_LIBRARY_DIR)/Frameworks/Quartz.framework/Frameworks -iframework $(SDKROOT)$(SYSTEM_LIBRARY_DIR)/PrivateFrameworks;
+OTHER_CPLUSPLUSFLAGS = $(OTHER_CFLAGS);
+
+HEADER_SEARCH_PATHS = PAL ForwardingHeaders icu /usr/include/libxslt /usr/include/libxml2 "$(BUILT_PRODUCTS_DIR)/usr/local/include" $(HEADER_SEARCH_PATHS);
+INSTALL_PATH = $(INSTALL_PATH_$(CONFIGURATION));
+INSTALL_PATH_Production = /usr/local/lib;
+INSTALLHDRS_COPY_PHASE = YES;
+INSTALLHDRS_SCRIPT_PHASE = YES;
+PRODUCT_NAME = PAL;
+PRODUCT_BUNDLE_IDENTIFIER = com.apple.$(PRODUCT_NAME:rfc1034identifier);
+
+WK_PREFIXED_IPHONEOS_DEPLOYMENT_TARGET = V$(IPHONEOS_DEPLOYMENT_TARGET);
+
+NORMAL_PRODUCTION_FRAMEWORKS_DIR[sdk=iphone*] = $(SDKROOT)$(SYSTEM_LIBRARY_DIR)/PrivateFrameworks;
+NORMAL_PRODUCTION_FRAMEWORKS_DIR[sdk=macosx*] = $(NEXT_ROOT)$(SYSTEM_LIBRARY_DIR)/Frameworks;
+
+PRODUCTION_FRAMEWORKS_DIR[sdk=iphone*] = $(NORMAL_PRODUCTION_FRAMEWORKS_DIR);
+PRODUCTION_FRAMEWORKS_DIR = $(PRODUCTION_FRAMEWORKS_DIR_USE_OVERRIDE_FRAMEWORKS_DIR_$(WK_USE_OVERRIDE_FRAMEWORKS_DIR));
+PRODUCTION_FRAMEWORKS_DIR_USE_OVERRIDE_FRAMEWORKS_DIR_NO = $(NORMAL_PRODUCTION_FRAMEWORKS_DIR);
+PRODUCTION_FRAMEWORKS_DIR_USE_OVERRIDE_FRAMEWORKS_DIR_YES = $(WK_OVERRIDE_FRAMEWORKS_DIR);
+
+EXCLUDED_SOURCE_FILE_NAMES[sdk=iphone*] = *.tiff *Cursor.png;
+EXCLUDED_SOURCE_FILE_NAMES[sdk=macosx*] = *IOS.h *IOS.cpp *IOS.mm;
+
+WK_EMPTY_ = YES;
+WK_NOT_ = YES;
+WK_NOT_YES = NO;
+
+WK_USE_OVERRIDE_FRAMEWORKS_DIR = $(WK_NOT_$(WK_EMPTY_$(WK_OVERRIDE_FRAMEWORKS_DIR)));
+
+WK_OVERRIDE_FRAMEWORKS_DIR = $(WK_OVERRIDE_FRAMEWORKS_DIR_USE_STAGING_INSTALL_PATH_$(USE_STAGING_INSTALL_PATH));
+WK_OVERRIDE_FRAMEWORKS_DIR_USE_STAGING_INSTALL_PATH_YES = $(SYSTEM_LIBRARY_DIR)/StagedFrameworks/Safari;
+
+WK_QUOTED_OVERRIDE_FRAMEWORKS_DIR = $(WK_QUOTED_OVERRIDE_FRAMEWORKS_DIR_$(WK_USE_OVERRIDE_FRAMEWORKS_DIR));
+WK_QUOTED_OVERRIDE_FRAMEWORKS_DIR_YES = "$(WK_OVERRIDE_FRAMEWORKS_DIR)";
+
+SKIP_INSTALL = $(SKIP_INSTALL_$(FORCE_TOOL_INSTALL));
+SKIP_INSTALL_ = YES;
+SKIP_INSTALL_NO = YES;
+SKIP_INSTALL_YES = NO;
+
+EXECUTABLE_PREFIX = lib;
diff --git a/Source/WebCore/PAL/Configurations/Version.xcconfig b/Source/WebCore/PAL/Configurations/Version.xcconfig
new file mode 100644 (file)
index 0000000..267fccf
--- /dev/null
@@ -0,0 +1,60 @@
+// Copyright (C) 2017 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.
+//
+// THIS SOFTWARE IS PROVIDED BY APPLE INC. ``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 INC. OR
+// 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. 
+
+MAJOR_VERSION = 604;
+MINOR_VERSION = 1;
+TINY_VERSION = 5;
+MICRO_VERSION = 0;
+NANO_VERSION = 0;
+FULL_VERSION = $(MAJOR_VERSION).$(MINOR_VERSION).$(TINY_VERSION);
+
+// The bundle version and short version string are set based on the current build configuration, see below.
+BUNDLE_VERSION = $(BUNDLE_VERSION_$(CONFIGURATION));
+SHORT_VERSION_STRING = $(SHORT_VERSION_STRING_$(CONFIGURATION))
+
+// The system version prefix is based on the current system version.
+SYSTEM_VERSION_PREFIX[sdk=iphone*] = 8;
+SYSTEM_VERSION_PREFIX = $(SYSTEM_VERSION_PREFIX_$(PLATFORM_NAME)_$(TARGET_MAC_OS_X_VERSION_MAJOR));
+SYSTEM_VERSION_PREFIX_macosx_101000 = 10;
+SYSTEM_VERSION_PREFIX_macosx_101100 = 11;
+SYSTEM_VERSION_PREFIX_macosx_101200 = 12;
+SYSTEM_VERSION_PREFIX_macosx_101300 = 13;
+
+// The production build always uses the full version with a system version prefix.
+BUNDLE_VERSION_Production = $(SYSTEM_VERSION_PREFIX)$(FULL_VERSION);
+BUNDLE_VERSION_ = $(BUNDLE_VERSION_Production);
+
+// The production build always uses the major version with a system version prefix
+SHORT_VERSION_STRING_Production = $(SYSTEM_VERSION_PREFIX)$(MAJOR_VERSION);
+SHORT_VERSION_STRING_ = $(SHORT_VERSION_STRING_Production);
+
+// Local builds are the full version with a plus suffix.
+BUNDLE_VERSION_Release = $(FULL_VERSION)+;
+BUNDLE_VERSION_Debug = $(BUNDLE_VERSION_Release);
+
+// Local builds use the major version with a plus suffix
+SHORT_VERSION_STRING_Release = $(MAJOR_VERSION)+;
+SHORT_VERSION_STRING_Debug = $(SHORT_VERSION_STRING_Release);
+
+DYLIB_COMPATIBILITY_VERSION = 1;
+DYLIB_CURRENT_VERSION = $(FULL_VERSION);
diff --git a/Source/WebCore/PAL/PAL.xcodeproj/project.pbxproj b/Source/WebCore/PAL/PAL.xcodeproj/project.pbxproj
new file mode 100644 (file)
index 0000000..20c2951
--- /dev/null
@@ -0,0 +1,247 @@
+// !$*UTF8*$!
+{
+       archiveVersion = 1;
+       classes = {
+       };
+       objectVersion = 46;
+       objects = {
+
+/* Begin PBXBuildFile section */
+               1C09D0531E31C44100725F18 /* CryptoDigest.h in Headers */ = {isa = PBXBuildFile; fileRef = 1C09D0521E31C44100725F18 /* CryptoDigest.h */; };
+               1C09D0561E31C46500725F18 /* CryptoDigestCommonCrypto.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1C09D0551E31C46500725F18 /* CryptoDigestCommonCrypto.cpp */; };
+               1C09D0581E31C57E00725F18 /* config.h in Headers */ = {isa = PBXBuildFile; fileRef = 1C09D0571E31C57E00725F18 /* config.h */; };
+/* End PBXBuildFile section */
+
+/* Begin PBXFileReference section */
+               1C09D03D1E31C32800725F18 /* libPAL.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libPAL.a; sourceTree = BUILT_PRODUCTS_DIR; };
+               1C09D0521E31C44100725F18 /* CryptoDigest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CryptoDigest.h; sourceTree = "<group>"; };
+               1C09D0551E31C46500725F18 /* CryptoDigestCommonCrypto.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CryptoDigestCommonCrypto.cpp; path = commoncrypto/CryptoDigestCommonCrypto.cpp; sourceTree = "<group>"; };
+               1C09D0571E31C57E00725F18 /* config.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = config.h; sourceTree = "<group>"; };
+               1C09D05D1E31C77A00725F18 /* PAL.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; path = PAL.xcconfig; sourceTree = "<group>"; };
+               1C09D0621E31EC2800725F18 /* DebugRelease.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; path = DebugRelease.xcconfig; sourceTree = "<group>"; };
+               1C09D0631E31EC3100725F18 /* Base.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; path = Base.xcconfig; sourceTree = "<group>"; };
+               1C67CEA11E32EDA800F80F2E /* FeatureDefines.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; path = FeatureDefines.xcconfig; sourceTree = "<group>"; };
+               1C67CEA21E32EE2600F80F2E /* Version.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; path = Version.xcconfig; sourceTree = "<group>"; };
+/* End PBXFileReference section */
+
+/* Begin PBXFrameworksBuildPhase section */
+               1C09D03A1E31C32800725F18 /* Frameworks */ = {
+                       isa = PBXFrameworksBuildPhase;
+                       buildActionMask = 2147483647;
+                       files = (
+                       );
+                       runOnlyForDeploymentPostprocessing = 0;
+               };
+/* End PBXFrameworksBuildPhase section */
+
+/* Begin PBXGroup section */
+               1C09D0341E31C32800725F18 = {
+                       isa = PBXGroup;
+                       children = (
+                               1C09D05C1E31C73300725F18 /* Configurations */,
+                               1C09D0571E31C57E00725F18 /* config.h */,
+                               1C09D03F1E31C32800725F18 /* pal */,
+                               1C09D03E1E31C32800725F18 /* Products */,
+                       );
+                       sourceTree = "<group>";
+               };
+               1C09D03E1E31C32800725F18 /* Products */ = {
+                       isa = PBXGroup;
+                       children = (
+                               1C09D03D1E31C32800725F18 /* libPAL.a */,
+                       );
+                       name = Products;
+                       sourceTree = "<group>";
+               };
+               1C09D03F1E31C32800725F18 /* pal */ = {
+                       isa = PBXGroup;
+                       children = (
+                               1C09D0511E31C41200725F18 /* crypto */,
+                       );
+                       path = pal;
+                       sourceTree = "<group>";
+               };
+               1C09D0511E31C41200725F18 /* crypto */ = {
+                       isa = PBXGroup;
+                       children = (
+                               1C09D0541E31C45200725F18 /* commoncrypto */,
+                               1C09D0521E31C44100725F18 /* CryptoDigest.h */,
+                       );
+                       path = crypto;
+                       sourceTree = "<group>";
+               };
+               1C09D0541E31C45200725F18 /* commoncrypto */ = {
+                       isa = PBXGroup;
+                       children = (
+                               1C09D0551E31C46500725F18 /* CryptoDigestCommonCrypto.cpp */,
+                       );
+                       name = commoncrypto;
+                       sourceTree = "<group>";
+               };
+               1C09D05C1E31C73300725F18 /* Configurations */ = {
+                       isa = PBXGroup;
+                       children = (
+                               1C67CEA21E32EE2600F80F2E /* Version.xcconfig */,
+                               1C67CEA11E32EDA800F80F2E /* FeatureDefines.xcconfig */,
+                               1C09D05D1E31C77A00725F18 /* PAL.xcconfig */,
+                               1C09D0621E31EC2800725F18 /* DebugRelease.xcconfig */,
+                               1C09D0631E31EC3100725F18 /* Base.xcconfig */,
+                       );
+                       path = Configurations;
+                       sourceTree = "<group>";
+               };
+/* End PBXGroup section */
+
+/* Begin PBXHeadersBuildPhase section */
+               1C09D03B1E31C32800725F18 /* Headers */ = {
+                       isa = PBXHeadersBuildPhase;
+                       buildActionMask = 2147483647;
+                       files = (
+                               1C09D0581E31C57E00725F18 /* config.h in Headers */,
+                               1C09D0531E31C44100725F18 /* CryptoDigest.h in Headers */,
+                       );
+                       runOnlyForDeploymentPostprocessing = 0;
+               };
+/* End PBXHeadersBuildPhase section */
+
+/* Begin PBXNativeTarget section */
+               1C09D03C1E31C32800725F18 /* PAL */ = {
+                       isa = PBXNativeTarget;
+                       buildConfigurationList = 1C09D0481E31C32800725F18 /* Build configuration list for PBXNativeTarget "PAL" */;
+                       buildPhases = (
+                               1C09D0391E31C32800725F18 /* Sources */,
+                               1C09D03A1E31C32800725F18 /* Frameworks */,
+                               1C09D03B1E31C32800725F18 /* Headers */,
+                       );
+                       buildRules = (
+                       );
+                       dependencies = (
+                       );
+                       name = PAL;
+                       productName = PAL;
+                       productReference = 1C09D03D1E31C32800725F18 /* libPAL.a */;
+                       productType = "com.apple.product-type.library.static";
+               };
+/* End PBXNativeTarget section */
+
+/* Begin PBXProject section */
+               1C09D0351E31C32800725F18 /* Project object */ = {
+                       isa = PBXProject;
+                       attributes = {
+                               LastUpgradeCheck = 0830;
+                               TargetAttributes = {
+                                       1C09D03C1E31C32800725F18 = {
+                                               CreatedOnToolsVersion = 8.3;
+                                               ProvisioningStyle = Automatic;
+                                       };
+                               };
+                       };
+                       buildConfigurationList = 1C09D0381E31C32800725F18 /* Build configuration list for PBXProject "PAL" */;
+                       compatibilityVersion = "Xcode 3.2";
+                       developmentRegion = English;
+                       hasScannedForEncodings = 1;
+                       knownRegions = (
+                               English,
+                               Japanese,
+                               French,
+                               German,
+                               Spanish,
+                               Dutch,
+                               Italian,
+                       );
+                       mainGroup = 1C09D0341E31C32800725F18;
+                       productRefGroup = 1C09D03E1E31C32800725F18 /* Products */;
+                       projectDirPath = "";
+                       projectRoot = "";
+                       targets = (
+                               1C09D03C1E31C32800725F18 /* PAL */,
+                       );
+               };
+/* End PBXProject section */
+
+/* Begin PBXSourcesBuildPhase section */
+               1C09D0391E31C32800725F18 /* Sources */ = {
+                       isa = PBXSourcesBuildPhase;
+                       buildActionMask = 2147483647;
+                       files = (
+                               1C09D0561E31C46500725F18 /* CryptoDigestCommonCrypto.cpp in Sources */,
+                       );
+                       runOnlyForDeploymentPostprocessing = 0;
+               };
+/* End PBXSourcesBuildPhase section */
+
+/* Begin XCBuildConfiguration section */
+               1C09D0461E31C32800725F18 /* Debug */ = {
+                       isa = XCBuildConfiguration;
+                       baseConfigurationReference = 1C09D0621E31EC2800725F18 /* DebugRelease.xcconfig */;
+                       buildSettings = {
+                               DEAD_CODE_STRIPPING = "$(DEAD_CODE_STRIPPING_debug)";
+                               DEBUG_DEFINES = "$(DEBUG_DEFINES_debug)";
+                               GCC_OPTIMIZATION_LEVEL = "$(GCC_OPTIMIZATION_LEVEL_debug)";
+                               STRIP_INSTALLED_PRODUCT = "$(STRIP_INSTALLED_PRODUCT_debug)";
+                       };
+                       name = Debug;
+               };
+               1C09D0471E31C32800725F18 /* Release */ = {
+                       isa = XCBuildConfiguration;
+                       baseConfigurationReference = 1C09D0621E31EC2800725F18 /* DebugRelease.xcconfig */;
+                       buildSettings = {
+                               STRIP_INSTALLED_PRODUCT = NO;
+                       };
+                       name = Release;
+               };
+               1C09D0491E31C32800725F18 /* Debug */ = {
+                       isa = XCBuildConfiguration;
+                       baseConfigurationReference = 1C09D05D1E31C77A00725F18 /* PAL.xcconfig */;
+                       buildSettings = {
+                       };
+                       name = Debug;
+               };
+               1C09D04A1E31C32800725F18 /* Release */ = {
+                       isa = XCBuildConfiguration;
+                       baseConfigurationReference = 1C09D05D1E31C77A00725F18 /* PAL.xcconfig */;
+                       buildSettings = {
+                       };
+                       name = Release;
+               };
+               1C09D05A1E31C6F000725F18 /* Production */ = {
+                       isa = XCBuildConfiguration;
+                       baseConfigurationReference = 1C09D0631E31EC3100725F18 /* Base.xcconfig */;
+                       buildSettings = {
+                       };
+                       name = Production;
+               };
+               1C09D05B1E31C6F000725F18 /* Production */ = {
+                       isa = XCBuildConfiguration;
+                       baseConfigurationReference = 1C09D05D1E31C77A00725F18 /* PAL.xcconfig */;
+                       buildSettings = {
+                       };
+                       name = Production;
+               };
+/* End XCBuildConfiguration section */
+
+/* Begin XCConfigurationList section */
+               1C09D0381E31C32800725F18 /* Build configuration list for PBXProject "PAL" */ = {
+                       isa = XCConfigurationList;
+                       buildConfigurations = (
+                               1C09D0461E31C32800725F18 /* Debug */,
+                               1C09D0471E31C32800725F18 /* Release */,
+                               1C09D05A1E31C6F000725F18 /* Production */,
+                       );
+                       defaultConfigurationIsVisible = 0;
+                       defaultConfigurationName = Production;
+               };
+               1C09D0481E31C32800725F18 /* Build configuration list for PBXNativeTarget "PAL" */ = {
+                       isa = XCConfigurationList;
+                       buildConfigurations = (
+                               1C09D0491E31C32800725F18 /* Debug */,
+                               1C09D04A1E31C32800725F18 /* Release */,
+                               1C09D05B1E31C6F000725F18 /* Production */,
+                       );
+                       defaultConfigurationIsVisible = 0;
+                       defaultConfigurationName = Production;
+               };
+/* End XCConfigurationList section */
+       };
+       rootObject = 1C09D0351E31C32800725F18 /* Project object */;
+}
diff --git a/Source/WebCore/PAL/config.h b/Source/WebCore/PAL/config.h
new file mode 100644 (file)
index 0000000..5488c80
--- /dev/null
@@ -0,0 +1,58 @@
+/*
+ * Copyright (C) 2004, 2005, 2006, 2013, 2014 Apple Inc. All rights reserved.
+ * Copyright (C) 2009 Google Inc. All rights reserved.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Library General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * Library General Public License for more details.
+ *
+ * You should have received a copy of the GNU Library General Public License
+ * along with this library; see the file COPYING.LIB.  If not, write to
+ * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
+ *
+ */
+
+#if defined(HAVE_CONFIG_H) && HAVE_CONFIG_H && defined(BUILDING_WITH_CMAKE)
+#include "cmakeconfig.h"
+#endif
+
+#include <wtf/Platform.h>
+
+#include <wtf/ExportMacros.h>
+
+#ifdef __APPLE__
+#define HAVE_FUNC_USLEEP 1
+#endif /* __APPLE__ */
+
+#if OS(WINDOWS)
+
+#ifndef _WIN32_WINNT
+#define _WIN32_WINNT 0x601
+#endif
+
+#ifndef WINVER
+#define WINVER 0x0601
+#endif
+
+#endif /* OS(WINDOWS) */
+
+#ifdef __cplusplus
+
+// These undefs match up with defines in WebCorePrefix.h for Mac OS X.
+// Helps us catch if anyone uses new or delete by accident in code and doesn't include "config.h".
+#undef new
+#undef delete
+#include <wtf/FastMalloc.h>
+
+#include <ciso646>
+
+#endif
+
+#include <wtf/DisallowCType.h>
diff --git a/Source/WebCore/PAL/pal/CMakeLists.txt b/Source/WebCore/PAL/pal/CMakeLists.txt
new file mode 100644 (file)
index 0000000..3b5f1ea
--- /dev/null
@@ -0,0 +1,17 @@
+set(PAL_SOURCES
+)
+
+set(PAL_INCLUDE_DIRECTORIES
+    "${PAL_DIR}"
+    "${PAL_DIR}/pal"
+    "${PAL_DIR}/pal/crypto"
+)
+
+set(PAL_LIBRARIES
+    WTF
+)
+
+WEBKIT_INCLUDE_CONFIG_FILES_IF_EXISTS()
+
+WEBKIT_WRAP_SOURCELIST(${PAL_SOURCES})
+WEBKIT_FRAMEWORK(PAL)
diff --git a/Source/WebCore/PAL/pal/PlatformEfl.cmake b/Source/WebCore/PAL/pal/PlatformEfl.cmake
new file mode 100644 (file)
index 0000000..775c189
--- /dev/null
@@ -0,0 +1,3 @@
+list(APPEND PAL_SOURCES
+    crypto/gcrypt/CryptoDigestGCrypt.cpp
+)
diff --git a/Source/WebCore/PAL/pal/PlatformGTK.cmake b/Source/WebCore/PAL/pal/PlatformGTK.cmake
new file mode 100644 (file)
index 0000000..775c189
--- /dev/null
@@ -0,0 +1,3 @@
+list(APPEND PAL_SOURCES
+    crypto/gcrypt/CryptoDigestGCrypt.cpp
+)
diff --git a/Source/WebCore/PAL/pal/PlatformMac.cmake b/Source/WebCore/PAL/pal/PlatformMac.cmake
new file mode 100644 (file)
index 0000000..2f968ec
--- /dev/null
@@ -0,0 +1,3 @@
+list(APPEND PAL_SOURCES
+    crypto/commoncrypto/CryptoDigestCommonCrypto.cpp
+)
diff --git a/Source/WebCore/PAL/pal/PlatformWin.cmake b/Source/WebCore/PAL/pal/PlatformWin.cmake
new file mode 100644 (file)
index 0000000..6f6919f
--- /dev/null
@@ -0,0 +1,3 @@
+list(APPEND PAL_SOURCES
+    crypto/win/CryptoDigestWin.cpp
+)
similarity index 94%
rename from Source/WebCore/platform/crypto/CryptoDigest.h
rename to Source/WebCore/PAL/pal/crypto/CryptoDigest.h
index 31f075a..588e127 100644 (file)
  * THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-#ifndef CryptoDigest_h
-#define CryptoDigest_h
+#pragma once
 
 #include <wtf/Noncopyable.h>
 #include <wtf/Vector.h>
 
-namespace WebCore {
+namespace PAL {
 
 struct CryptoDigestContext;
 
@@ -55,6 +54,4 @@ private:
     std::unique_ptr<CryptoDigestContext> m_context;
 };
 
-} // namespace WebCore
-
-#endif // CryptoDigest_h
+} // namespace PAL
@@ -28,7 +28,7 @@
 
 #include <CommonCrypto/CommonCrypto.h>
 
-namespace WebCore {
+namespace PAL {
 
 struct CryptoDigestContext {
     CryptoDigest::Algorithm algorithm;
@@ -176,4 +176,4 @@ Vector<uint8_t> CryptoDigest::computeHash()
     return result;
 }
 
-} // namespace WebCore
+} // namespace PAL
@@ -29,7 +29,7 @@
 
 #include <gcrypt.h>
 
-namespace WebCore {
+namespace PAL {
 
 struct CryptoDigestContext {
     int algorithm;
@@ -94,4 +94,4 @@ Vector<uint8_t> CryptoDigest::computeHash()
     return result;
 }
 
-} // namespace WebCore
+} // namespace PAL
@@ -29,7 +29,7 @@
 #include <gnutls/gnutls.h>
 #include <gnutls/crypto.h>
 
-namespace WebCore {
+namespace PAL {
 
 struct CryptoDigestContext {
     gnutls_digest_algorithm_t algorithm;
@@ -99,4 +99,4 @@ Vector<uint8_t> CryptoDigest::computeHash()
     return result;
 }
 
-} // namespace WebCore
+} // namespace PAL
 #include "config.h"
 #include "CryptoDigest.h"
 
+#include <windows.h>
 #include <wincrypt.h>
 
-namespace WebCore {
+namespace PAL {
 
 struct CryptoDigestContext {
     CryptoDigest::Algorithm algorithm;
@@ -100,4 +101,4 @@ Vector<uint8_t> CryptoDigest::computeHash()
     return result;
 }
 
-} // namespace WebCore
+} // namespace PAL
index f3ae89b..1f0e103 100644 (file)
@@ -69,8 +69,6 @@ list(APPEND WebCore_SOURCES
 
     platform/audio/efl/AudioBusEfl.cpp
 
-    platform/crypto/gcrypt/CryptoDigestGCrypt.cpp
-
     platform/efl/CursorEfl.cpp
     platform/efl/DragDataEfl.cpp
     platform/efl/DragImageEfl.cpp
index 6242162..b1c6e6b 100644 (file)
@@ -68,8 +68,6 @@ list(APPEND WebCore_SOURCES
 
     platform/audio/glib/AudioBusGLib.cpp
 
-    platform/crypto/gcrypt/CryptoDigestGCrypt.cpp
-
     platform/gamepad/glib/GamepadsGlib.cpp
 
     platform/geoclue/GeolocationProviderGeoclue1.cpp
index 4c51e2a..7dc1e6e 100644 (file)
@@ -333,8 +333,6 @@ list(APPEND WebCore_SOURCES
     platform/cocoa/ThemeCocoa.mm
     platform/cocoa/WebCoreNSErrorExtras.mm
 
-    platform/crypto/commoncrypto/CryptoDigestCommonCrypto.cpp
-
     platform/gamepad/mac/HIDGamepad.cpp
     platform/gamepad/mac/HIDGamepadProvider.cpp
 
index 8d7f508..a4a9909 100644 (file)
@@ -73,8 +73,6 @@ list(APPEND WebCore_SOURCES
 
     platform/cf/win/CertificateCFWin.cpp
 
-    platform/crypto/win/CryptoDigestWin.cpp
-
     platform/graphics/GraphicsContext3DPrivate.cpp
 
     platform/graphics/egl/GLContextEGL.cpp
index 9899922..fe02bea 100644 (file)
                1C010701192594DF008A4201 /* InlineTextBoxStyle.h in Headers */ = {isa = PBXBuildFile; fileRef = 1C0106FF192594DF008A4201 /* InlineTextBoxStyle.h */; };
                1C0939EA1A13E12900B788E5 /* CachedSVGFont.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1C0939E81A13E12900B788E5 /* CachedSVGFont.cpp */; };
                1C0939EB1A13E12900B788E5 /* CachedSVGFont.h in Headers */ = {isa = PBXBuildFile; fileRef = 1C0939E91A13E12900B788E5 /* CachedSVGFont.h */; };
+               1C09D0591E31C6A900725F18 /* libPAL.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 1C09D0501E31C32900725F18 /* libPAL.a */; };
                1C18DA58181AF6A500C4EF22 /* TextPainter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1C18DA56181AF6A500C4EF22 /* TextPainter.cpp */; };
                1C18DA59181AF6A500C4EF22 /* TextPainter.h in Headers */ = {isa = PBXBuildFile; fileRef = 1C18DA57181AF6A500C4EF22 /* TextPainter.h */; };
                1C21E57C183ED1FF001C289D /* IOSurfacePool.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1C21E57A183ED1FF001C289D /* IOSurfacePool.cpp */; };
                E1F80B8818317252007885C3 /* CryptoKeyPair.h in Headers */ = {isa = PBXBuildFile; fileRef = E1F80B8618317252007885C3 /* CryptoKeyPair.h */; settings = {ATTRIBUTES = (Private, ); }; };
                E1F80B8D183172B5007885C3 /* JSCryptoKeyPair.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E1F80B8B183172B5007885C3 /* JSCryptoKeyPair.cpp */; };
                E1F80B8E183172B5007885C3 /* JSCryptoKeyPair.h in Headers */ = {isa = PBXBuildFile; fileRef = E1F80B8C183172B5007885C3 /* JSCryptoKeyPair.h */; };
-               E1FE13641834351100892F13 /* CryptoDigestCommonCrypto.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E1FE13621834351100892F13 /* CryptoDigestCommonCrypto.cpp */; };
-               E1FE136718343A1000892F13 /* CryptoDigest.h in Headers */ = {isa = PBXBuildFile; fileRef = E1FE136618343A1000892F13 /* CryptoDigest.h */; };
                E1FE136A183FE1AB00892F13 /* CryptoAlgorithmRSA_OAEP.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E1FE1368183FE1AB00892F13 /* CryptoAlgorithmRSA_OAEP.cpp */; };
                E1FE136B183FE1AB00892F13 /* CryptoAlgorithmRSA_OAEP.h in Headers */ = {isa = PBXBuildFile; fileRef = E1FE1369183FE1AB00892F13 /* CryptoAlgorithmRSA_OAEP.h */; };
                E1FE1370183FECF000892F13 /* CryptoAlgorithmRSA_OAEPMac.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E1FE136E183FECF000892F13 /* CryptoAlgorithmRSA_OAEPMac.cpp */; };
 /* End PBXBuildFile section */
 
 /* Begin PBXContainerItemProxy section */
+               1C09D04F1E31C32900725F18 /* PBXContainerItemProxy */ = {
+                       isa = PBXContainerItemProxy;
+                       containerPortal = 1C09D04B1E31C32800725F18 /* PAL.xcodeproj */;
+                       proxyType = 2;
+                       remoteGlobalIDString = 1C09D03D1E31C32800725F18;
+                       remoteInfo = PAL;
+               };
+               1C09D0671E32079D00725F18 /* PBXContainerItemProxy */ = {
+                       isa = PBXContainerItemProxy;
+                       containerPortal = 1C09D04B1E31C32800725F18 /* PAL.xcodeproj */;
+                       proxyType = 1;
+                       remoteGlobalIDString = 1C09D03C1E31C32800725F18;
+                       remoteInfo = PAL;
+               };
                417DA6D413734E0D007C57FB /* PBXContainerItemProxy */ = {
                        isa = PBXContainerItemProxy;
                        containerPortal = 0867D690FE84028FC02AAC07 /* Project object */;
                1C0106FF192594DF008A4201 /* InlineTextBoxStyle.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = InlineTextBoxStyle.h; sourceTree = "<group>"; };
                1C0939E81A13E12900B788E5 /* CachedSVGFont.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CachedSVGFont.cpp; sourceTree = "<group>"; };
                1C0939E91A13E12900B788E5 /* CachedSVGFont.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CachedSVGFont.h; sourceTree = "<group>"; };
+               1C09D04B1E31C32800725F18 /* PAL.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = PAL.xcodeproj; path = PAL/PAL.xcodeproj; sourceTree = "<group>"; };
                1C18DA56181AF6A500C4EF22 /* TextPainter.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = TextPainter.cpp; sourceTree = "<group>"; };
                1C18DA57181AF6A500C4EF22 /* TextPainter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TextPainter.h; sourceTree = "<group>"; };
                1C21E57A183ED1FF001C289D /* IOSurfacePool.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = IOSurfacePool.cpp; sourceTree = "<group>"; };
                E1F80B8618317252007885C3 /* CryptoKeyPair.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CryptoKeyPair.h; sourceTree = "<group>"; };
                E1F80B8B183172B5007885C3 /* JSCryptoKeyPair.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSCryptoKeyPair.cpp; sourceTree = "<group>"; };
                E1F80B8C183172B5007885C3 /* JSCryptoKeyPair.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSCryptoKeyPair.h; sourceTree = "<group>"; };
-               E1FE13621834351100892F13 /* CryptoDigestCommonCrypto.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CryptoDigestCommonCrypto.cpp; sourceTree = "<group>"; };
-               E1FE136618343A1000892F13 /* CryptoDigest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CryptoDigest.h; sourceTree = "<group>"; };
                E1FE1368183FE1AB00892F13 /* CryptoAlgorithmRSA_OAEP.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CryptoAlgorithmRSA_OAEP.cpp; sourceTree = "<group>"; };
                E1FE1369183FE1AB00892F13 /* CryptoAlgorithmRSA_OAEP.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CryptoAlgorithmRSA_OAEP.h; sourceTree = "<group>"; };
                E1FE136E183FECF000892F13 /* CryptoAlgorithmRSA_OAEPMac.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CryptoAlgorithmRSA_OAEPMac.cpp; sourceTree = "<group>"; };
                        isa = PBXFrameworksBuildPhase;
                        buildActionMask = 2147483647;
                        files = (
+                               1C09D0591E31C6A900725F18 /* libPAL.a in Frameworks */,
                                FD2DBF1212B048A300ED98C6 /* Accelerate.framework in Frameworks */,
                                FD2DBF1312B048A300ED98C6 /* AudioToolbox.framework in Frameworks */,
                                1AB33DA512551E320024457A /* IOKit.framework in Frameworks */,
                0867D691FE84028FC02AAC07 /* WebKit */ = {
                        isa = PBXGroup;
                        children = (
+                               1C09D04B1E31C32800725F18 /* PAL.xcodeproj */,
                                65C97AF208EA908800ACD273 /* config.h */,
                                EDEC98020AED7E170059137F /* WebCorePrefix.h */,
                                9307061309E0CA8200B17FE4 /* DerivedSources.make */,
                        path = mac;
                        sourceTree = "<group>";
                };
+               1C09D04C1E31C32800725F18 /* Products */ = {
+                       isa = PBXGroup;
+                       children = (
+                               1C09D0501E31C32900725F18 /* libPAL.a */,
+                       );
+                       name = Products;
+                       sourceTree = "<group>";
+               };
                1C5FAECA0DCFD8C900D58F78 /* Inspector */ = {
                        isa = PBXGroup;
                        children = (
                                FD31604012B026A300C1A359 /* audio */,
                                1AE42F670AA4B8CB00C8612D /* cf */,
                                A5C974CE11485FDA0066F2AB /* cocoa */,
-                               CE50D8CE1C8932ED0072EA5A /* crypto */,
                                515BE1871D54F5DB00DD7C68 /* gamepad */,
                                B2A015910AF6CD53006BCE0E /* graphics */,
                                A59E3C1B11580F340072928E /* ios */,
                        path = ios;
                        sourceTree = "<group>";
                };
-               CE50D8CE1C8932ED0072EA5A /* crypto */ = {
-                       isa = PBXGroup;
-                       children = (
-                               CE50D8CF1C8932FB0072EA5A /* commoncrypto */,
-                               E1FE136618343A1000892F13 /* CryptoDigest.h */,
-                       );
-                       path = crypto;
-                       sourceTree = "<group>";
-               };
-               CE50D8CF1C8932FB0072EA5A /* commoncrypto */ = {
-                       isa = PBXGroup;
-                       children = (
-                               E1FE13621834351100892F13 /* CryptoDigestCommonCrypto.cpp */,
-                       );
-                       path = commoncrypto;
-                       sourceTree = "<group>";
-               };
                DF9AFD6F13FC31B00015FEB7 /* objc */ = {
                        isa = PBXGroup;
                        children = (
                                E19AC3F11824DC7900349426 /* CryptoAlgorithmSHA256.h in Headers */,
                                E19AC3F31824DC7900349426 /* CryptoAlgorithmSHA384.h in Headers */,
                                E19AC3F51824DC7900349426 /* CryptoAlgorithmSHA512.h in Headers */,
-                               E1FE136718343A1000892F13 /* CryptoDigest.h in Headers */,
                                E157A8E518173A3A009F821D /* CryptoKey.h in Headers */,
                                E125F84E1824289D00D84CD9 /* CryptoKeyAES.h in Headers */,
                                E125F85E182C2DF600D84CD9 /* CryptoKeyData.h in Headers */,
                        buildRules = (
                        );
                        dependencies = (
+                               1C09D0681E32079D00725F18 /* PBXTargetDependency */,
                                DD041FF109D9E3250010AF2A /* PBXTargetDependency */,
                        );
                        name = WebCore;
                        mainGroup = 0867D691FE84028FC02AAC07 /* WebKit */;
                        productRefGroup = 034768DFFF38A50411DB9C8B /* Products */;
                        projectDirPath = "";
+                       projectReferences = (
+                               {
+                                       ProductGroup = 1C09D04C1E31C32800725F18 /* Products */;
+                                       ProjectRef = 1C09D04B1E31C32800725F18 /* PAL.xcodeproj */;
+                               },
+                       );
                        projectRoot = "";
                        targets = (
                                41816F7913859C550057AAA4 /* All */,
                };
 /* End PBXProject section */
 
+/* Begin PBXReferenceProxy section */
+               1C09D0501E31C32900725F18 /* libPAL.a */ = {
+                       isa = PBXReferenceProxy;
+                       fileType = archive.ar;
+                       path = libPAL.a;
+                       remoteRef = 1C09D04F1E31C32900725F18 /* PBXContainerItemProxy */;
+                       sourceTree = BUILT_PRODUCTS_DIR;
+               };
+/* End PBXReferenceProxy section */
+
 /* Begin PBXResourcesBuildPhase section */
                93F199FD08245E59001E9ABC /* Resources */ = {
                        isa = PBXResourcesBuildPhase;
                                E19AC3F01824DC7900349426 /* CryptoAlgorithmSHA256.cpp in Sources */,
                                E19AC3F21824DC7900349426 /* CryptoAlgorithmSHA384.cpp in Sources */,
                                E19AC3F41824DC7900349426 /* CryptoAlgorithmSHA512.cpp in Sources */,
-                               E1FE13641834351100892F13 /* CryptoDigestCommonCrypto.cpp in Sources */,
                                E157A8E418173A3A009F821D /* CryptoKey.cpp in Sources */,
                                E125F84D1824289D00D84CD9 /* CryptoKeyAES.cpp in Sources */,
                                E125F863182C303A00D84CD9 /* CryptoKeyDataOctetSequence.cpp in Sources */,
 /* End PBXSourcesBuildPhase section */
 
 /* Begin PBXTargetDependency section */
+               1C09D0681E32079D00725F18 /* PBXTargetDependency */ = {
+                       isa = PBXTargetDependency;
+                       name = PAL;
+                       targetProxy = 1C09D0671E32079D00725F18 /* PBXContainerItemProxy */;
+               };
                417DA6D513734E0D007C57FB /* PBXTargetDependency */ = {
                        isa = PBXTargetDependency;
                        target = 93F198A508245E59001E9ABC /* WebCore */;
index 0c8dfdd..addf84d 100644 (file)
@@ -28,9 +28,9 @@
 
 #if ENABLE(SUBTLE_CRYPTO)
 
-#include "CryptoDigest.h"
 #include "ExceptionCode.h"
 #include "ScriptExecutionContext.h"
+#include <pal/crypto/CryptoDigest.h>
 
 namespace WebCore {
 
@@ -46,7 +46,7 @@ CryptoAlgorithmIdentifier CryptoAlgorithmSHA1::identifier() const
 
 void CryptoAlgorithmSHA1::digest(Vector<uint8_t>&& message, VectorCallback&& callback, ExceptionCallback&& exceptionCallback, ScriptExecutionContext& context, WorkQueue& workQueue)
 {
-    auto digest = CryptoDigest::create(CryptoDigest::Algorithm::SHA_1);
+    auto digest = PAL::CryptoDigest::create(PAL::CryptoDigest::Algorithm::SHA_1);
     if (!digest) {
         exceptionCallback(OperationError);
         return;
@@ -65,7 +65,7 @@ void CryptoAlgorithmSHA1::digest(Vector<uint8_t>&& message, VectorCallback&& cal
 
 ExceptionOr<void> CryptoAlgorithmSHA1::digest(const CryptoAlgorithmParametersDeprecated&, const CryptoOperationData& data, VectorCallback&& callback, VoidCallback&& failureCallback)
 {
-    auto digest = CryptoDigest::create(CryptoDigest::Algorithm::SHA_1);
+    auto digest = PAL::CryptoDigest::create(PAL::CryptoDigest::Algorithm::SHA_1);
     if (!digest) {
         failureCallback();
         return { };
index 6ca1aee..634c5a3 100644 (file)
@@ -28,9 +28,9 @@
 
 #if ENABLE(SUBTLE_CRYPTO)
 
-#include "CryptoDigest.h"
 #include "ExceptionCode.h"
 #include "ScriptExecutionContext.h"
+#include <pal/crypto/CryptoDigest.h>
 
 namespace WebCore {
 
@@ -46,7 +46,7 @@ CryptoAlgorithmIdentifier CryptoAlgorithmSHA224::identifier() const
 
 void CryptoAlgorithmSHA224::digest(Vector<uint8_t>&& message, VectorCallback&& callback, ExceptionCallback&& exceptionCallback, ScriptExecutionContext& context, WorkQueue& workQueue)
 {
-    auto digest = CryptoDigest::create(CryptoDigest::Algorithm::SHA_224);
+    auto digest = PAL::CryptoDigest::create(PAL::CryptoDigest::Algorithm::SHA_224);
     if (!digest) {
         exceptionCallback(OperationError);
         return;
@@ -65,7 +65,7 @@ void CryptoAlgorithmSHA224::digest(Vector<uint8_t>&& message, VectorCallback&& c
 
 ExceptionOr<void> CryptoAlgorithmSHA224::digest(const CryptoAlgorithmParametersDeprecated&, const CryptoOperationData& data, VectorCallback&& callback, VoidCallback&& failureCallback)
 {
-    auto digest = CryptoDigest::create(CryptoDigest::Algorithm::SHA_224);
+    auto digest = PAL::CryptoDigest::create(PAL::CryptoDigest::Algorithm::SHA_224);
     if (!digest) {
         failureCallback();
         return { };
index 73660f5..0ea0506 100644 (file)
@@ -28,9 +28,9 @@
 
 #if ENABLE(SUBTLE_CRYPTO)
 
-#include "CryptoDigest.h"
 #include "ExceptionCode.h"
 #include "ScriptExecutionContext.h"
+#include <pal/crypto/CryptoDigest.h>
 
 namespace WebCore {
 
@@ -46,7 +46,7 @@ CryptoAlgorithmIdentifier CryptoAlgorithmSHA256::identifier() const
 
 void CryptoAlgorithmSHA256::digest(Vector<uint8_t>&& message, VectorCallback&& callback, ExceptionCallback&& exceptionCallback, ScriptExecutionContext& context, WorkQueue& workQueue)
 {
-    auto digest = CryptoDigest::create(CryptoDigest::Algorithm::SHA_256);
+    auto digest = PAL::CryptoDigest::create(PAL::CryptoDigest::Algorithm::SHA_256);
     if (!digest) {
         exceptionCallback(OperationError);
         return;
@@ -65,7 +65,7 @@ void CryptoAlgorithmSHA256::digest(Vector<uint8_t>&& message, VectorCallback&& c
 
 ExceptionOr<void> CryptoAlgorithmSHA256::digest(const CryptoAlgorithmParametersDeprecated&, const CryptoOperationData& data, VectorCallback&& callback, VoidCallback&& failureCallback)
 {
-    auto digest = CryptoDigest::create(CryptoDigest::Algorithm::SHA_256);
+    auto digest = PAL::CryptoDigest::create(PAL::CryptoDigest::Algorithm::SHA_256);
     if (!digest) {
         failureCallback();
         return { };
index c97752d..88f3136 100644 (file)
@@ -28,9 +28,9 @@
 
 #if ENABLE(SUBTLE_CRYPTO)
 
-#include "CryptoDigest.h"
 #include "ExceptionCode.h"
 #include "ScriptExecutionContext.h"
+#include <pal/crypto/CryptoDigest.h>
 
 namespace WebCore {
 
@@ -46,7 +46,7 @@ CryptoAlgorithmIdentifier CryptoAlgorithmSHA384::identifier() const
 
 void CryptoAlgorithmSHA384::digest(Vector<uint8_t>&& message, VectorCallback&& callback, ExceptionCallback&& exceptionCallback, ScriptExecutionContext& context, WorkQueue& workQueue)
 {
-    auto digest = CryptoDigest::create(CryptoDigest::Algorithm::SHA_384);
+    auto digest = PAL::CryptoDigest::create(PAL::CryptoDigest::Algorithm::SHA_384);
     if (!digest) {
         exceptionCallback(OperationError);
         return;
@@ -65,7 +65,7 @@ void CryptoAlgorithmSHA384::digest(Vector<uint8_t>&& message, VectorCallback&& c
 
 ExceptionOr<void> CryptoAlgorithmSHA384::digest(const CryptoAlgorithmParametersDeprecated&, const CryptoOperationData& data, VectorCallback&& callback, VoidCallback&& failureCallback)
 {
-    auto digest = CryptoDigest::create(CryptoDigest::Algorithm::SHA_384);
+    auto digest = PAL::CryptoDigest::create(PAL::CryptoDigest::Algorithm::SHA_384);
     if (!digest) {
         failureCallback();
         return { };
index 33e483d..0103f09 100644 (file)
@@ -28,9 +28,9 @@
 
 #if ENABLE(SUBTLE_CRYPTO)
 
-#include "CryptoDigest.h"
 #include "ExceptionCode.h"
 #include "ScriptExecutionContext.h"
+#include <pal/crypto/CryptoDigest.h>
 
 namespace WebCore {
 
@@ -46,7 +46,7 @@ CryptoAlgorithmIdentifier CryptoAlgorithmSHA512::identifier() const
 
 void CryptoAlgorithmSHA512::digest(Vector<uint8_t>&& message, VectorCallback&& callback, ExceptionCallback&& exceptionCallback, ScriptExecutionContext& context, WorkQueue& workQueue)
 {
-    auto digest = CryptoDigest::create(CryptoDigest::Algorithm::SHA_512);
+    auto digest = PAL::CryptoDigest::create(PAL::CryptoDigest::Algorithm::SHA_512);
     if (!digest) {
         exceptionCallback(OperationError);
         return;
@@ -65,7 +65,7 @@ void CryptoAlgorithmSHA512::digest(Vector<uint8_t>&& message, VectorCallback&& c
 
 ExceptionOr<void> CryptoAlgorithmSHA512::digest(const CryptoAlgorithmParametersDeprecated&, const CryptoOperationData& data, VectorCallback&& callback, VoidCallback&& failureCallback)
 {
-    auto digest = CryptoDigest::create(CryptoDigest::Algorithm::SHA_512);
+    auto digest = PAL::CryptoDigest::create(PAL::CryptoDigest::Algorithm::SHA_512);
     if (!digest) {
         failureCallback();
         return { };
index f6ab7a2..0f0bf93 100644 (file)
 
 #include "CommonCryptoUtilities.h"
 #include "CryptoAlgorithmRsaSsaParamsDeprecated.h"
-#include "CryptoDigest.h"
 #include "CryptoKeyRSA.h"
 #include "ExceptionCode.h"
 #include "ScriptExecutionContext.h"
+#include <pal/crypto/CryptoDigest.h>
 
 namespace WebCore {
 
-inline std::optional<CryptoDigest::Algorithm> cryptoDigestAlgorithm(CryptoAlgorithmIdentifier hashFunction)
+inline std::optional<PAL::CryptoDigest::Algorithm> cryptoDigestAlgorithm(CryptoAlgorithmIdentifier hashFunction)
 {
     switch (hashFunction) {
     case CryptoAlgorithmIdentifier::SHA_1:
-        return CryptoDigest::Algorithm::SHA_1;
+        return PAL::CryptoDigest::Algorithm::SHA_1;
     case CryptoAlgorithmIdentifier::SHA_224:
-        return CryptoDigest::Algorithm::SHA_224;
+        return PAL::CryptoDigest::Algorithm::SHA_224;
     case CryptoAlgorithmIdentifier::SHA_256:
-        return CryptoDigest::Algorithm::SHA_256;
+        return PAL::CryptoDigest::Algorithm::SHA_256;
     case CryptoAlgorithmIdentifier::SHA_384:
-        return CryptoDigest::Algorithm::SHA_384;
+        return PAL::CryptoDigest::Algorithm::SHA_384;
     case CryptoAlgorithmIdentifier::SHA_512:
-        return CryptoDigest::Algorithm::SHA_512;
+        return PAL::CryptoDigest::Algorithm::SHA_512;
     default:
         return std::nullopt;
     }
@@ -66,7 +66,7 @@ static ExceptionOr<Vector<uint8_t>> signRSASSA_PKCS1_v1_5(CryptoAlgorithmIdentif
     auto cryptoDigestAlgorithm = WebCore::cryptoDigestAlgorithm(hash);
     if (!cryptoDigestAlgorithm)
         return Exception { OperationError };
-    auto digest = CryptoDigest::create(*cryptoDigestAlgorithm);
+    auto digest = PAL::CryptoDigest::create(*cryptoDigestAlgorithm);
     if (!digest)
         return Exception { OperationError };
     digest->addBytes(data, dataLength);
@@ -93,7 +93,7 @@ static ExceptionOr<bool> verifyRSASSA_PKCS1_v1_5(CryptoAlgorithmIdentifier hash,
     auto cryptoDigestAlgorithm = WebCore::cryptoDigestAlgorithm(hash);
     if (!cryptoDigestAlgorithm)
         return Exception { OperationError };
-    auto digest = CryptoDigest::create(*cryptoDigestAlgorithm);
+    auto digest = PAL::CryptoDigest::create(*cryptoDigestAlgorithm);
     if (!digest)
         return Exception { OperationError };
     digest->addBytes(data, dataLength);
index a157a84..df77cb4 100644 (file)
@@ -45,7 +45,6 @@
 #include "ContainerNode.h"
 #include "Cookie.h"
 #include "CookieJar.h"
-#include "CryptoDigest.h"
 #include "DOMEditor.h"
 #include "DOMPatchSupport.h"
 #include "DOMWindow.h"
@@ -96,6 +95,7 @@
 #include <inspector/IdentifiersFactory.h>
 #include <inspector/InjectedScript.h>
 #include <inspector/InjectedScriptManager.h>
+#include <pal/crypto/CryptoDigest.h>
 #include <runtime/JSCInlines.h>
 #include <wtf/text/Base64.h>
 #include <wtf/text/CString.h>
@@ -1316,7 +1316,7 @@ static String computeContentSecurityPolicySHA256Hash(const Element& element)
     TextEncoding documentEncoding = element.document().textEncoding();
     const TextEncoding& encodingToUse = documentEncoding.isValid() ? documentEncoding : UTF8Encoding();
     CString content = encodingToUse.encode(TextNodeTraversal::contentsAsString(element), EntitiesForUnencodables);
-    auto cryptoDigest = CryptoDigest::create(CryptoDigest::Algorithm::SHA_256);
+    auto cryptoDigest = PAL::CryptoDigest::create(PAL::CryptoDigest::Algorithm::SHA_256);
     cryptoDigest->addBytes(content.data(), content.length());
     Vector<uint8_t> digest = cryptoDigest->computeHash();
     return makeString("sha256-", base64Encode(digest.data(), digest.size()));
index 4a19c8e..bd88c9d 100644 (file)
@@ -33,7 +33,6 @@
 #include "ContentSecurityPolicyHash.h"
 #include "ContentSecurityPolicySource.h"
 #include "ContentSecurityPolicySourceList.h"
-#include "CryptoDigest.h"
 #include "DOMStringList.h"
 #include "Document.h"
 #include "DocumentLoader.h"
@@ -57,6 +56,7 @@
 #include <inspector/InspectorValues.h>
 #include <inspector/ScriptCallStack.h>
 #include <inspector/ScriptCallStackFactory.h>
+#include <pal/crypto/CryptoDigest.h>
 #include <wtf/SetForScope.h>
 #include <wtf/text/StringBuilder.h>
 #include <wtf/text/TextPosition.h>
@@ -301,18 +301,18 @@ bool ContentSecurityPolicy::allPoliciesAllow(ViolatedDirectiveCallback&& callbac
     return isAllowed;
 }
 
-static CryptoDigest::Algorithm toCryptoDigestAlgorithm(ContentSecurityPolicyHashAlgorithm algorithm)
+static PAL::CryptoDigest::Algorithm toCryptoDigestAlgorithm(ContentSecurityPolicyHashAlgorithm algorithm)
 {
     switch (algorithm) {
     case ContentSecurityPolicyHashAlgorithm::SHA_256:
-        return CryptoDigest::Algorithm::SHA_256;
+        return PAL::CryptoDigest::Algorithm::SHA_256;
     case ContentSecurityPolicyHashAlgorithm::SHA_384:
-        return CryptoDigest::Algorithm::SHA_384;
+        return PAL::CryptoDigest::Algorithm::SHA_384;
     case ContentSecurityPolicyHashAlgorithm::SHA_512:
-        return CryptoDigest::Algorithm::SHA_512;
+        return PAL::CryptoDigest::Algorithm::SHA_512;
     }
     ASSERT_NOT_REACHED();
-    return CryptoDigest::Algorithm::SHA_512;
+    return PAL::CryptoDigest::Algorithm::SHA_512;
 }
 
 template<typename Predicate>
@@ -333,7 +333,7 @@ ContentSecurityPolicy::HashInEnforcedAndReportOnlyPoliciesPair ContentSecurityPo
     bool foundHashInEnforcedPolicies = false;
     bool foundHashInReportOnlyPolicies = false;
     for (auto algorithm : algorithms) {
-        auto cryptoDigest = CryptoDigest::create(toCryptoDigestAlgorithm(algorithm));
+        auto cryptoDigest = PAL::CryptoDigest::create(toCryptoDigestAlgorithm(algorithm));
         cryptoDigest->addBytes(contentCString.data(), contentCString.length());
         ContentSecurityPolicyHash hash = { algorithm, cryptoDigest->computeHash() };
         if (!foundHashInEnforcedPolicies && allPoliciesWithDispositionAllow(ContentSecurityPolicy::Disposition::Enforce, std::forward<Predicate>(predicate), hash))
index 852b9b8..26db7f2 100644 (file)
@@ -30,7 +30,6 @@
 #include "SoupNetworkSession.h"
 
 #include "AuthenticationChallenge.h"
-#include "CryptoDigest.h"
 #include "FileSystem.h"
 #include "GUniquePtrSoup.h"
 #include "Logging.h"
@@ -38,6 +37,7 @@
 #include "SoupNetworkProxySettings.h"
 #include <glib/gstdio.h>
 #include <libsoup/soup.h>
+#include <pal/crypto/CryptoDigest.h>
 #include <wtf/HashSet.h>
 #include <wtf/NeverDestroyed.h>
 #include <wtf/text/Base64.h>
@@ -78,7 +78,7 @@ private:
         if (!certificateData)
             return String();
 
-        auto digest = CryptoDigest::create(CryptoDigest::Algorithm::SHA_256);
+        auto digest = PAL::CryptoDigest::create(PAL::CryptoDigest::Algorithm::SHA_256);
         digest->addBytes(certificateData->data, certificateData->len);
 
         auto hash = digest->computeHash();
index c341abf..c790b5f 100644 (file)
@@ -32,6 +32,7 @@ set(WebKit_SYSTEM_INCLUDE_DIRECTORIES
 set(WebKit_LIBRARIES
     PRIVATE JavaScriptCore${DEBUG_SUFFIX}
     PRIVATE WebCore${DEBUG_SUFFIX}
+    PRIVATE PAL${DEBUG_SUFFIX}
 )
 
 WEBKIT_INCLUDE_CONFIG_FILES_IF_EXISTS()
index 2d043a0..9a58f9d 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2009, 2010, 2014, 2015, 2016 Apple Inc. All rights reserved.
+// Copyright (C) 2009, 2010, 2014, 2015, 2016, 2017 Apple Inc. All rights reserved.
 // Copyright (C) 2009 Google Inc. All rights reserved.
 //
 // Redistribution and use in source and binary forms, with or without
index 2d043a0..9a58f9d 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2009, 2010, 2014, 2015, 2016 Apple Inc. All rights reserved.
+// Copyright (C) 2009, 2010, 2014, 2015, 2016, 2017 Apple Inc. All rights reserved.
 // Copyright (C) 2009 Google Inc. All rights reserved.
 //
 // Redistribution and use in source and binary forms, with or without
index fdf3614..b788c2b 100644 (file)
@@ -182,5 +182,6 @@ endif ()
 set(PORT Win)
 set(JavaScriptCore_LIBRARY_TYPE SHARED)
 set(WTF_LIBRARY_TYPE SHARED)
+set(PAL_LIBRARY_TYPE STATIC)
 
 find_package(ICU REQUIRED)
index 29a0969..5130ffc 100644 (file)
@@ -10,6 +10,9 @@ endif ()
 if (NOT WEBCORE_DIR)
     set(WEBCORE_DIR "${CMAKE_SOURCE_DIR}/Source/WebCore")
 endif ()
+if (NOT PAL_DIR)
+    set(PAL_DIR "${CMAKE_SOURCE_DIR}/Source/WebCore/PAL")
+endif ()
 if (NOT WEBKIT_DIR)
     set(WEBKIT_DIR "${CMAKE_SOURCE_DIR}/Source/WebKit")
 endif ()
index 29762ba..491fc49 100644 (file)
@@ -43,6 +43,7 @@ class FeatureDefinesChecker(object):
         feature_defines_files = [
             "Source/JavaScriptCore/Configurations/FeatureDefines.xcconfig",
             "Source/WebCore/Configurations/FeatureDefines.xcconfig",
+            "Source/WebCore/PAL/Configurations/FeatureDefines.xcconfig",
             "Source/WebKit/mac/Configurations/FeatureDefines.xcconfig",
             "Source/WebKit2/Configurations/FeatureDefines.xcconfig",
             "Tools/TestWebKitAPI/Configurations/FeatureDefines.xcconfig",
index 2d043a0..9a58f9d 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2009, 2010, 2014, 2015, 2016 Apple Inc. All rights reserved.
+// Copyright (C) 2009, 2010, 2014, 2015, 2016, 2017 Apple Inc. All rights reserved.
 // Copyright (C) 2009 Google Inc. All rights reserved.
 //
 // Redistribution and use in source and binary forms, with or without