Title: [243567] trunk
Revision
243567
Author
aes...@apple.com
Date
2019-03-27 16:09:51 -0700 (Wed, 27 Mar 2019)

Log Message

REGRESSION (r242686): package-root creates roots with broken symlinks in WebKit.framework/XPCServices/
https://bugs.webkit.org/show_bug.cgi?id=196317

Reviewed by Dan Bernstein.

Source/WebKit:

Removed some remnants of the Storage Process.

* Configurations/BaseTarget.xcconfig:
* Resources/SandboxProfiles/ios/com.apple.WebKit.Storage.sb: Removed.
* WebKit.xcodeproj/project.pbxproj:

Tools:

package-root copies built products into a staging directory using ditto(1), which does not
follow symbolic links as it traverses a directory. Now that the files in
WebKit.framework/XPCServices/ are symbolic links to a location outside of the framework
itself, these become broken links when ditto'd into the staging directory.

To account for this, change package-root to copy using cp(1) in a mode that follows symlinks.

* Scripts/package-root:

Modified Paths

Removed Paths

Diff

Modified: trunk/Source/WebKit/ChangeLog (243566 => 243567)


--- trunk/Source/WebKit/ChangeLog	2019-03-27 22:16:22 UTC (rev 243566)
+++ trunk/Source/WebKit/ChangeLog	2019-03-27 23:09:51 UTC (rev 243567)
@@ -1,3 +1,16 @@
+2019-03-27  Andy Estes  <aes...@apple.com>
+
+        REGRESSION (r242686): package-root creates roots with broken symlinks in WebKit.framework/XPCServices/
+        https://bugs.webkit.org/show_bug.cgi?id=196317
+
+        Reviewed by Dan Bernstein.
+
+        Removed some remnants of the Storage Process.
+
+        * Configurations/BaseTarget.xcconfig:
+        * Resources/SandboxProfiles/ios/com.apple.WebKit.Storage.sb: Removed.
+        * WebKit.xcodeproj/project.pbxproj:
+
 2019-03-27  Keith Rollin  <krol...@apple.com>
 
         Include the CFNetworking task UUID to the NSError when a resource-load fails

Modified: trunk/Source/WebKit/Configurations/BaseTarget.xcconfig (243566 => 243567)


--- trunk/Source/WebKit/Configurations/BaseTarget.xcconfig	2019-03-27 22:16:22 UTC (rev 243566)
+++ trunk/Source/WebKit/Configurations/BaseTarget.xcconfig	2019-03-27 23:09:51 UTC (rev 243567)
@@ -111,13 +111,3 @@
 
 WK_CORE_PREDICTION_DEFINES = $(WK_CORE_PREDICTION_DEFINES_$(WK_HAVE_CORE_PREDICTION));
 WK_CORE_PREDICTION_DEFINES_YES = HAVE_CORE_PREDICTION;
-
-WK_STORAGE_SERVICE_PRODUCT_NAME = $(WK_STORAGE_SERVICE_PRODUCT_NAME_$(WK_USE_LEGACY_STORAGE_SERVICE_NAME));
-WK_STORAGE_SERVICE_PRODUCT_NAME_ = $(WK_STORAGE_SERVICE_PRODUCT_NAME_NO);
-WK_STORAGE_SERVICE_PRODUCT_NAME_NO = com.apple.WebKit.Storage;
-WK_STORAGE_SERVICE_PRODUCT_NAME_YES = com.apple.WebKit.Databases;
-
-WK_USE_LEGACY_STORAGE_SERVICE_NAME[sdk=iphoneos11*] = $(WK_USE_LEGACY_STORAGE_SERVICE_NAME_11$(IPHONEOS_DEPLOYMENT_TARGET:suffix:identifier));
-WK_USE_LEGACY_STORAGE_SERVICE_NAME_11_0 = YES;
-WK_USE_LEGACY_STORAGE_SERVICE_NAME_11_1 = YES;
-WK_USE_LEGACY_STORAGE_SERVICE_NAME_11_2 = YES;

Deleted: trunk/Source/WebKit/Resources/SandboxProfiles/ios/com.apple.WebKit.Storage.sb (243566 => 243567)


--- trunk/Source/WebKit/Resources/SandboxProfiles/ios/com.apple.WebKit.Storage.sb	2019-03-27 22:16:22 UTC (rev 243566)
+++ trunk/Source/WebKit/Resources/SandboxProfiles/ios/com.apple.WebKit.Storage.sb	2019-03-27 23:09:51 UTC (rev 243567)
@@ -1,47 +0,0 @@
-; Copyright (C) 2014-2018 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. AND ITS CONTRIBUTORS ``AS IS''
-; AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
-; THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
-; PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
-; BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-; CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-; SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-; INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-; CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-; ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
-; THE POSSIBILITY OF SUCH DAMAGE.
-
-(version 1)
-(deny default (with partial-symbolication))
-(allow system-audit file-read-metadata)
-
-(import "common.sb")
-
-(deny mach-lookup (xpc-service-name-prefix ""))
-
-(deny lsopen)
-
-(allow file-read* file-write* (extension "com.apple.app-sandbox.read-write"))
-
-(deny sysctl*)
-(allow sysctl-read
-    (sysctl-name
-        "hw.availcpu"
-        "hw.ncpu"
-        "hw.model"
-        "kern.memorystatus_level"
-        "vm.footprint_suspend"))
-
-;; Various services required by system frameworks
-(allow mach-lookup
-   (global-name "com.apple.analyticsd"))

Modified: trunk/Source/WebKit/WebKit.xcodeproj/project.pbxproj (243566 => 243567)


--- trunk/Source/WebKit/WebKit.xcodeproj/project.pbxproj	2019-03-27 22:16:22 UTC (rev 243566)
+++ trunk/Source/WebKit/WebKit.xcodeproj/project.pbxproj	2019-03-27 23:09:51 UTC (rev 243567)
@@ -3958,7 +3958,6 @@
 		A5EC6AD32151BD6900677D17 /* WebPageDebuggable.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = WebPageDebuggable.h; sourceTree = "<group>"; };
 		A5EFD38B16B0E88C00B2F0E8 /* WKPageVisibilityTypes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKPageVisibilityTypes.h; sourceTree = "<group>"; };
 		A72D5D7F1236CBA800A88B15 /* APISerializedScriptValue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = APISerializedScriptValue.h; sourceTree = "<group>"; };
-		A78CCDD7193AC9E3005ECC25 /* com.apple.WebKit.Storage.sb */ = {isa = PBXFileReference; lastKnownFileType = text; path = com.apple.WebKit.Storage.sb; sourceTree = "<group>"; };
 		A78CCDD8193AC9E3005ECC25 /* com.apple.WebKit.Networking.sb */ = {isa = PBXFileReference; lastKnownFileType = text; path = com.apple.WebKit.Networking.sb; sourceTree = "<group>"; };
 		A78CCDD9193AC9E3005ECC25 /* com.apple.WebKit.WebContent.sb */ = {isa = PBXFileReference; lastKnownFileType = text; path = com.apple.WebKit.WebContent.sb; sourceTree = "<group>"; };
 		A7D792D41767CB0900881CBE /* ActivityAssertion.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ActivityAssertion.h; sourceTree = "<group>"; };
@@ -7219,7 +7218,6 @@
 			isa = PBXGroup;
 			children = (
 				A78CCDD8193AC9E3005ECC25 /* com.apple.WebKit.Networking.sb */,
-				A78CCDD7193AC9E3005ECC25 /* com.apple.WebKit.Storage.sb */,
 				A78CCDD9193AC9E3005ECC25 /* com.apple.WebKit.WebContent.sb */,
 			);
 			path = ios;
@@ -10737,7 +10735,7 @@
 			);
 			runOnlyForDeploymentPostprocessing = 0;
 			shellPath = /bin/sh;
-			shellScript = "if [[ \"${CONFIGURATION}\" == \"Production\" ]]; then\n    exit\nfi\n\nif [[ ${WK_PLATFORM_NAME} != \"macosx\" ]]; then\n    XPC_SERVICES_PATH=\"${BUILT_PRODUCTS_DIR}/WebKit.framework/XPCServices\"\n    BUILT_PRODUCTS_DIR_RELATIVE_PATH_FROM_XPC_SERVICES=\"../..\"\nelse\n    XPC_SERVICES_PATH=\"${BUILT_PRODUCTS_DIR}/WebKit.framework/Versions/A/XPCServices\"\n    BUILT_PRODUCTS_DIR_RELATIVE_PATH_FROM_XPC_SERVICES=\"../../../..\"\nfi\n\nmkdir -p \"${XPC_SERVICES_PATH}\"\nln -sFh \"${BUILT_PRODUCTS_DIR_RELATIVE_PATH_FROM_XPC_SERVICES}/com.apple.WebKit.WebContent.xpc\" \"${XPC_SERVICES_PATH}/com.apple.WebKit.WebContent.xpc\"\nln -sFh \"${BUILT_PRODUCTS_DIR_RELATIVE_PATH_FROM_XPC_SERVICES}/com.apple.WebKit.Networking.xpc\" \"${XPC_SERVICES_PATH}/com.apple.WebKit.Networking.xpc\"\nln -sFh \"${BUILT_PRODUCTS_DIR_RELATIVE_PATH_FROM_XP
 C_SERVICES}/${WK_STORAGE_SERVICE_PRODUCT_NAME}.xpc\" \"${XPC_SERVICES_PATH}/${WK_STORAGE_SERVICE_PRODUCT_NAME}.xpc\"\n\nif [[ ${WK_PLATFORM_NAME} == macosx ]]; then\n    ln -sFh \"${BUILT_PRODUCTS_DIR_RELATIVE_PATH_FROM_XPC_SERVICES}/com.apple.WebKit.Plugin.64.xpc\" \"${XPC_SERVICES_PATH}/com.apple.WebKit.Plugin.64.xpc\"\nfi\n";
+			shellScript = "if [[ \"${CONFIGURATION}\" == \"Production\" ]]; then\n    exit\nfi\n\nif [[ ${WK_PLATFORM_NAME} != \"macosx\" ]]; then\n    XPC_SERVICES_PATH=\"${BUILT_PRODUCTS_DIR}/WebKit.framework/XPCServices\"\n    BUILT_PRODUCTS_DIR_RELATIVE_PATH_FROM_XPC_SERVICES=\"../..\"\nelse\n    XPC_SERVICES_PATH=\"${BUILT_PRODUCTS_DIR}/WebKit.framework/Versions/A/XPCServices\"\n    BUILT_PRODUCTS_DIR_RELATIVE_PATH_FROM_XPC_SERVICES=\"../../../..\"\nfi\n\nmkdir -p \"${XPC_SERVICES_PATH}\"\nln -sFh \"${BUILT_PRODUCTS_DIR_RELATIVE_PATH_FROM_XPC_SERVICES}/com.apple.WebKit.WebContent.xpc\" \"${XPC_SERVICES_PATH}/com.apple.WebKit.WebContent.xpc\"\nln -sFh \"${BUILT_PRODUCTS_DIR_RELATIVE_PATH_FROM_XPC_SERVICES}/com.apple.WebKit.Networking.xpc\" \"${XPC_SERVICES_PATH}/com.apple.WebKit.Networking.xpc\"\n\nif [[ ${WK_PLATFORM_NAME} == macosx ]]; then\n    ln -sF
 h \"${BUILT_PRODUCTS_DIR_RELATIVE_PATH_FROM_XPC_SERVICES}/com.apple.WebKit.Plugin.64.xpc\" \"${XPC_SERVICES_PATH}/com.apple.WebKit.Plugin.64.xpc\"\nfi\n";
 		};
 		99CA3862207286DB00BAD578 /* Copy WebDriver Atoms to Framework Private Headers */ = {
 			isa = PBXShellScriptBuildPhase;

Modified: trunk/Tools/ChangeLog (243566 => 243567)


--- trunk/Tools/ChangeLog	2019-03-27 22:16:22 UTC (rev 243566)
+++ trunk/Tools/ChangeLog	2019-03-27 23:09:51 UTC (rev 243567)
@@ -1,3 +1,19 @@
+2019-03-27  Andy Estes  <aes...@apple.com>
+
+        REGRESSION (r242686): package-root creates roots with broken symlinks in WebKit.framework/XPCServices/
+        https://bugs.webkit.org/show_bug.cgi?id=196317
+
+        Reviewed by Dan Bernstein.
+
+        package-root copies built products into a staging directory using ditto(1), which does not
+        follow symbolic links as it traverses a directory. Now that the files in
+        WebKit.framework/XPCServices/ are symbolic links to a location outside of the framework
+        itself, these become broken links when ditto'd into the staging directory.
+
+        To account for this, change package-root to copy using cp(1) in a mode that follows symlinks.
+
+        * Scripts/package-root:
+
 2019-03-27  Aakash Jain  <aakash_j...@apple.com>
 
         [ews-app] Update display text of Submit for ews analysis

Modified: trunk/Tools/Scripts/package-root (243566 => 243567)


--- trunk/Tools/Scripts/package-root	2019-03-27 22:16:22 UTC (rev 243566)
+++ trunk/Tools/Scripts/package-root	2019-03-27 23:09:51 UTC (rev 243567)
@@ -80,21 +80,24 @@
 my $platform = xcodeSDKPlatformName();
 my $productDir = productDir();
 my $stagingRoot = tempdir(CLEANUP => 1);
-my $stagingPrivatePath = "/$stagingRoot$privateInstallPath";
-my $stagingPublicPath = "/$stagingRoot/$publicInstallPath";
+my $stagingPrivatePath = "$stagingRoot$privateInstallPath";
+my $stagingPublicPath = "$stagingRoot$publicInstallPath";
 my $archiveName = "webkit-$configuration-$platform";
 my $archivePath = "$productDir/$archiveName.tar.gz";
 my ($fh, $tempArchiveName) = tempfile( "/tmp/$archiveName-XXXXXXX");
 
+system 'mkdir', '-p', $stagingPrivatePath;
+system 'mkdir', '-p', $stagingPublicPath;
+
 foreach my $framework (@privateFrameworks) {
     print "Copying Private $framework from $productDir ...\n";
-    system 'ditto', $productDir . "/$framework.framework/", "$stagingPrivatePath/$framework.framework/";
+    system 'cp', '-LpR', $productDir . "/$framework.framework", "$stagingPrivatePath/";
     die "Check to see that you have built $framework for $configuration-$platform" if $? and $framework ne 'WebKit2';
 }
 
 foreach my $framework (@publicFrameworks) {
     print "Copying Public $framework from $productDir ...\n";
-    system 'ditto', $productDir . "/$framework.framework/", "$stagingPublicPath/$framework.framework/";
+    system 'cp', '-LpR', $productDir . "/$framework.framework", "$stagingPublicPath/";
     die "Check to see that you have built $framework for $configuration-$platform" if $?;
 }
 
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to