Diff
Modified: branches/safari-601.1.46-branch/Tools/ChangeLog (198862 => 198863)
--- branches/safari-601.1.46-branch/Tools/ChangeLog 2016-03-30 23:06:39 UTC (rev 198862)
+++ branches/safari-601.1.46-branch/Tools/ChangeLog 2016-03-30 23:06:44 UTC (rev 198863)
@@ -1,5 +1,42 @@
2016-03-30 Matthew Hanson <matthew_han...@apple.com>
+ Merge r194115. rdar://problem/25253479
+
+ 2015-12-15 David Kilzer <ddkil...@apple.com>
+
+ REGRESSION (r192375): DumpRenderTree.app exits immediately with no error
+ <http://webkit.org/b/152314>
+
+ Reviewed by Daniel Bates.
+
+ The change to DumpRenderTreeMain.mm in r192375 caused the iOS
+ code path to exit immediately when calling main().
+ Unfortunately, DumpRenderTreeMain.mm was used for both
+ DumpRenderTree command-line binary and DumpRenderTree.app, which
+ meant that the app would exit immediately with no error code
+ when run!
+
+ The workaround is to introduce a separate source file called
+ DumpRenderTreeAppMain.mm, similar to what WebKitTestRunner
+ already does.
+
+ * DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj: Add
+ DumpRenderTreeAppMain.mm to the project. Make it the only
+ compiled source for the DumpRenderTree.app target.
+ * DumpRenderTree/ios/DumpRenderTreeAppMain.mm: Copied from Tools/DumpRenderTree/mac/DumpRenderTreeMain.mm.
+ (main): Call DumpRenderTreeMain() on iOS. Assert on OS X in
+ case someone tries mistakenly to use the app.
+ * DumpRenderTree/mac/Configurations/DumpRenderTree.xcconfig:
+ Link to _javascript_Core.framework on iOS for the assert.
+ * DumpRenderTree/mac/Configurations/DumpRenderTreeApp.xcconfig:
+ Link to _javascript_Core.framework on OS X for the assert. Remove
+ unneeded EXCLUDED_SOURCE_FILE_NAMES setting.
+ * DumpRenderTree/mac/DumpRenderTreeMain.mm:
+ (main): Add assert for iOS so that a crash occurs if someone
+ tries to run the wrong command.
+
+2016-03-30 Matthew Hanson <matthew_han...@apple.com>
+
Merge r192375. rdar://problem/25253479
2015-11-12 Daniel Bates <daba...@apple.com>
Modified: branches/safari-601.1.46-branch/Tools/DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj (198862 => 198863)
--- branches/safari-601.1.46-branch/Tools/DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj 2016-03-30 23:06:39 UTC (rev 198862)
+++ branches/safari-601.1.46-branch/Tools/DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj 2016-03-30 23:06:44 UTC (rev 198863)
@@ -61,6 +61,7 @@
31117B3D15D9A56A00163BC8 /* MockWebNotificationProvider.mm in Sources */ = {isa = PBXBuildFile; fileRef = 31117B3B15D9A56A00163BC8 /* MockWebNotificationProvider.mm */; };
440590711268453800CFD48D /* WebArchiveDumpSupportMac.mm in Sources */ = {isa = PBXBuildFile; fileRef = 440590701268453800CFD48D /* WebArchiveDumpSupportMac.mm */; };
4437730E125CBC3600AAE02C /* WebArchiveDumpSupport.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 44A997830FCDE86400580F10 /* WebArchiveDumpSupport.cpp */; };
+ 4464CABE1C20A08B00E5BB55 /* DumpRenderTreeAppMain.mm in Sources */ = {isa = PBXBuildFile; fileRef = 4464CABD1C20A07000E5BB55 /* DumpRenderTreeAppMain.mm */; };
4AD6A11413C8124000EA9737 /* FormValue.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4AD6A11313C8124000EA9737 /* FormValue.cpp */; };
5106803E15CC7B10001A8A23 /* SlowNPPNew.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 5106803D15CC7B10001A8A23 /* SlowNPPNew.cpp */; };
51134C9916014FDC001AA513 /* InvokeDestroysPluginWithinNPP_New.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 51134C9816014FDB001AA513 /* InvokeDestroysPluginWithinNPP_New.cpp */; };
@@ -89,7 +90,6 @@
A1158D59189274360088C17B /* PixelDumpSupportIOS.mm in Sources */ = {isa = PBXBuildFile; fileRef = A1158D57189273EB0088C17B /* PixelDumpSupportIOS.mm */; };
A134E531188FC27000901D06 /* DumpRenderTreeMain.mm in Sources */ = {isa = PBXBuildFile; fileRef = A134E52F188FC27000901D06 /* DumpRenderTreeMain.mm */; };
A134E53618905EFF00901D06 /* AccessibilityCommonMac.mm in Sources */ = {isa = PBXBuildFile; fileRef = BC0E26140E2DA4C6001B6BC3 /* AccessibilityCommonMac.mm */; };
- A19318001892886B001C52B1 /* DumpRenderTreeMain.mm in Sources */ = {isa = PBXBuildFile; fileRef = A134E52F188FC27000901D06 /* DumpRenderTreeMain.mm */; };
A8B91ADA0CF3B32F008F91FF /* DumpRenderTreePasteboard.m in Sources */ = {isa = PBXBuildFile; fileRef = A8B91AD70CF3B32F008F91FF /* DumpRenderTreePasteboard.m */; };
A8B91ADC0CF3B32F008F91FF /* DumpRenderTreeWindow.mm in Sources */ = {isa = PBXBuildFile; fileRef = A8B91AD90CF3B32F008F91FF /* DumpRenderTreeWindow.mm */; };
A8B91BFD0CF522B4008F91FF /* CheckedMalloc.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A8B91BF70CF522B4008F91FF /* CheckedMalloc.cpp */; };
@@ -255,6 +255,7 @@
375F09790DAC3CB600C8B4E5 /* WebKitWeightWatcher900.ttf */ = {isa = PBXFileReference; lastKnownFileType = file; name = WebKitWeightWatcher900.ttf; path = fonts/WebKitWeightWatcher900.ttf; sourceTree = "<group>"; };
417DAA1C137B3E24007C57FB /* WebCoreTestSupport.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = WebCoreTestSupport.h; path = WebCoreTestSupport/WebCoreTestSupport.h; sourceTree = BUILT_PRODUCTS_DIR; };
440590701268453800CFD48D /* WebArchiveDumpSupportMac.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = WebArchiveDumpSupportMac.mm; path = mac/WebArchiveDumpSupportMac.mm; sourceTree = "<group>"; };
+ 4464CABD1C20A07000E5BB55 /* DumpRenderTreeAppMain.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = DumpRenderTreeAppMain.mm; path = ios/DumpRenderTreeAppMain.mm; sourceTree = "<group>"; };
44A997820FCDE86400580F10 /* WebArchiveDumpSupport.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = WebArchiveDumpSupport.h; path = cf/WebArchiveDumpSupport.h; sourceTree = "<group>"; };
44A997830FCDE86400580F10 /* WebArchiveDumpSupport.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = WebArchiveDumpSupport.cpp; path = cf/WebArchiveDumpSupport.cpp; sourceTree = "<group>"; };
4AD6A11313C8124000EA9737 /* FormValue.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = FormValue.cpp; sourceTree = "<group>"; };
@@ -634,6 +635,7 @@
A1158D6A18927CE10088C17B /* ios */ = {
isa = PBXGroup;
children = (
+ 4464CABD1C20A07000E5BB55 /* DumpRenderTreeAppMain.mm */,
A1158D55189273EB0088C17B /* DumpRenderTreeBrowserView.h */,
A1158D56189273EB0088C17B /* DumpRenderTreeBrowserView.mm */,
A19317FC1892855F001C52B1 /* Info.plist */,
@@ -1002,7 +1004,7 @@
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
- A19318001892886B001C52B1 /* DumpRenderTreeMain.mm in Sources */,
+ 4464CABE1C20A08B00E5BB55 /* DumpRenderTreeAppMain.mm in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Copied: branches/safari-601.1.46-branch/Tools/DumpRenderTree/ios/DumpRenderTreeAppMain.mm (from rev 198862, branches/safari-601.1.46-branch/Tools/DumpRenderTree/mac/DumpRenderTreeMain.mm) (0 => 198863)
--- branches/safari-601.1.46-branch/Tools/DumpRenderTree/ios/DumpRenderTreeAppMain.mm (rev 0)
+++ branches/safari-601.1.46-branch/Tools/DumpRenderTree/ios/DumpRenderTreeAppMain.mm 2016-03-30 23:06:44 UTC (rev 198863)
@@ -0,0 +1,45 @@
+/*
+ * Copyright (C) 2014-2015 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * 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.
+ */
+
+#if PLATFORM(IOS)
+
+#include "DumpRenderTreeMac.h"
+
+int main(int argc, const char *argv[])
+{
+ return DumpRenderTreeMain(argc, argv);
+}
+
+#else
+
+#include <wtf/Assertions.h>
+
+int main(int, const char*[])
+{
+ RELEASE_ASSERT_WITH_MESSAGE(false, "DumpRenderTree.app is not supported on OS X; use DumpRenderTree command.");
+ return 0;
+}
+
+#endif
Modified: branches/safari-601.1.46-branch/Tools/DumpRenderTree/mac/Configurations/DumpRenderTree.xcconfig (198862 => 198863)
--- branches/safari-601.1.46-branch/Tools/DumpRenderTree/mac/Configurations/DumpRenderTree.xcconfig 2016-03-30 23:06:39 UTC (rev 198862)
+++ branches/safari-601.1.46-branch/Tools/DumpRenderTree/mac/Configurations/DumpRenderTree.xcconfig 2016-03-30 23:06:44 UTC (rev 198863)
@@ -23,8 +23,9 @@
#include "BaseTarget.xcconfig"
-OTHER_LDFLAGS = $(inherited) $(OTHER_LDFLAGS_$(PLATFORM_NAME)) $(ASAN_OTHER_LDFLAGS);
-OTHER_LDFLAGS_macosx = -l$(WEBKIT_SYSTEM_INTERFACE_LIBRARY) -lWebCoreTestSupport -force_load $(BUILT_PRODUCTS_DIR)/libDumpRenderTree.a -framework Carbon -framework Cocoa -framework _javascript_Core -framework OpenGL -framework QuartzCore -framework WebKit;
+OTHER_LDFLAGS = $(inherited) $(PLATFORM_OTHER_LDFLAGS) $(ASAN_OTHER_LDFLAGS);
+PLATFORM_OTHER_LDFLAGS[sdk=iphone*] = -framework _javascript_Core;
+PLATFORM_OTHER_LDFLAGS[sdk=macosx*] = -l$(WEBKIT_SYSTEM_INTERFACE_LIBRARY) -lWebCoreTestSupport -force_load $(BUILT_PRODUCTS_DIR)/libDumpRenderTree.a -framework Carbon -framework Cocoa -framework _javascript_Core -framework OpenGL -framework QuartzCore -framework WebKit;
LD_RUNPATH_SEARCH_PATHS = "@loader_path/.";
PRODUCT_NAME = DumpRenderTree;
SKIP_INSTALL[sdk=macosx*] = NO;
Modified: branches/safari-601.1.46-branch/Tools/DumpRenderTree/mac/Configurations/DumpRenderTreeApp.xcconfig (198862 => 198863)
--- branches/safari-601.1.46-branch/Tools/DumpRenderTree/mac/Configurations/DumpRenderTreeApp.xcconfig 2016-03-30 23:06:39 UTC (rev 198862)
+++ branches/safari-601.1.46-branch/Tools/DumpRenderTree/mac/Configurations/DumpRenderTreeApp.xcconfig 2016-03-30 23:06:44 UTC (rev 198863)
@@ -29,6 +29,6 @@
OTHER_LDFLAGS = $(PLATFORM_OTHER_LDFLAGS) $(ASAN_OTHER_LDFLAGS);
PLATFORM_OTHER_LDFLAGS[sdk=iphone*] = -l$(WEBKIT_SYSTEM_INTERFACE_LIBRARY) -lWebCoreTestSupport -force_load $(BUILT_PRODUCTS_DIR)/libDumpRenderTree.a -framework QuartzCore -framework CFNetwork -framework CoreFoundation -framework CoreGraphics -framework Foundation -framework GraphicsServices -framework ImageIO -framework MobileCoreServices -framework UIKit -framework WebCore -framework _javascript_Core -framework WebKit $(OTHER_LDFLAGS_FONTS);
+PLATFORM_OTHER_LDFLAGS[sdk=macosx*] = -framework _javascript_Core;
LD_RUNPATH_SEARCH_PATHS = "@loader_path/.";
PRODUCT_NAME = DumpRenderTree;
-EXCLUDED_SOURCE_FILE_NAMES[sdk=macosx*] = DumpRenderTreeMain.mm;
Modified: branches/safari-601.1.46-branch/Tools/DumpRenderTree/mac/DumpRenderTreeMain.mm (198862 => 198863)
--- branches/safari-601.1.46-branch/Tools/DumpRenderTree/mac/DumpRenderTreeMain.mm 2016-03-30 23:06:39 UTC (rev 198862)
+++ branches/safari-601.1.46-branch/Tools/DumpRenderTree/mac/DumpRenderTreeMain.mm 2016-03-30 23:06:44 UTC (rev 198863)
@@ -34,8 +34,11 @@
#else
+#include <wtf/Assertions.h>
+
int main(int, const char*[])
{
+ RELEASE_ASSERT_WITH_MESSAGE(false, "DumpRenderTree command is not supported on iOS; use DumpRenderTree.app.");
return 0;
}