haikuwebkit/Tools/Makefile

56 lines
1.3 KiB
Makefile
Raw Permalink Normal View History

MODULES = DumpRenderTree WebKitTestRunner MiniBrowser ../Source/ThirdParty/gtest/xcode TestWebKitAPI
TO_LOWER = $(shell echo $(1) | tr [:upper:] [:lower:])
ifneq (,$(SDKROOT))
ifeq (,$(findstring macosx,$(call TO_LOWER,$(notdir $(SDKROOT)))))
# Embedded OS
MODULES = DumpRenderTree WebKitTestRunner ../Source/ThirdParty/gtest/xcode TestWebKitAPI
endif
ifneq (,$(findstring macosx,$(call TO_LOWER,$(notdir $(SDKROOT)))))
MODULES += lldb/lldbWebKitTester
endif
ifneq (,$(findstring iphone,$(call TO_LOWER,$(notdir $(SDKROOT)))))
MODULES += MobileMiniBrowser
endif
endif
ifeq (,$(DO_NOT_BUILD_IMAGE_DIFF))
MODULES += ImageDiff
endif
macCatalyst: Get TestWebKitAPI building https://bugs.webkit.org/show_bug.cgi?id=203728 Reviewed by Alexey Proskuryakov. .: * Makefile: Descend into Tools/. Source/ThirdParty: * gtest/xcode/Config/General.xcconfig: * gtest/xcode/Config/SDKVariant.xcconfig: Added. Add SDKVariant.xcconfig to gtest so that it builds into the correct directory. Tools: * Makefile: Only build gtest and TestWebKitAPI for macCatalyst. * TestWebKitAPI/Configurations/Base.xcconfig: * TestWebKitAPI/Configurations/TestWebKitAPI.xcconfig: Make use of WK_COCOA_TOUCH instead of SDK conditionals. * TestWebKitAPI/Tests/WebKitCocoa/Challenge.mm: * TestWebKitAPI/Tests/WebKitCocoa/DragAndDropTests.mm: * TestWebKitAPI/Tests/ios/DragAndDropTestsIOS.mm: * TestWebKitAPI/ios/DragAndDropSimulatorIOS.mm: Fix some #ifdefs for macCatalyst. * TestWebKitAPI/Tests/WebKitLegacy/ios/ScrollToRevealSelection.mm: (-[LegacyLoadingDelegate webViewDidFinishLoad:]): * TestWebKitAPI/Tests/ios/ScrollViewInsetTests.mm: (-[AsyncPolicyDelegateForInsetTest webView:didFinishNavigation:]): (TestWebKitAPI::TEST): Util::runUntil wants a bool, not a BOOL. * TestWebKitAPI/config.h: Import WebKitLegacy.h after WebKit.h. Traditionally WebKit.h includes WebKitLegacy.h, except in macCatalyst. Many tests depend on being able to get WebKitLegacy.h this way. * Scripts/webkitpy/style/checkers/sdkvariant.py: * Scripts/webkitpy/port/factory.py: * Scripts/webkitpy/port/mac.py: Add a MacCatalyst port behind --maccatalyst, and do the bare minimum required to get it working and finding the right binaries. It inherits from Mac instead of iOS because for the purposes of finding and running binaries, dealing with I/O, etc., these are 100% bona fide macOS products. Canonical link: https://commits.webkit.org/217114@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@251941 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2019-11-01 21:29:25 +00:00
ifeq (iosmac,$(SDK_VARIANT))
MODULES = DumpRenderTree WebKitTestRunner ../Source/ThirdParty/gtest/xcode TestWebKitAPI
macCatalyst: Get TestWebKitAPI building https://bugs.webkit.org/show_bug.cgi?id=203728 Reviewed by Alexey Proskuryakov. .: * Makefile: Descend into Tools/. Source/ThirdParty: * gtest/xcode/Config/General.xcconfig: * gtest/xcode/Config/SDKVariant.xcconfig: Added. Add SDKVariant.xcconfig to gtest so that it builds into the correct directory. Tools: * Makefile: Only build gtest and TestWebKitAPI for macCatalyst. * TestWebKitAPI/Configurations/Base.xcconfig: * TestWebKitAPI/Configurations/TestWebKitAPI.xcconfig: Make use of WK_COCOA_TOUCH instead of SDK conditionals. * TestWebKitAPI/Tests/WebKitCocoa/Challenge.mm: * TestWebKitAPI/Tests/WebKitCocoa/DragAndDropTests.mm: * TestWebKitAPI/Tests/ios/DragAndDropTestsIOS.mm: * TestWebKitAPI/ios/DragAndDropSimulatorIOS.mm: Fix some #ifdefs for macCatalyst. * TestWebKitAPI/Tests/WebKitLegacy/ios/ScrollToRevealSelection.mm: (-[LegacyLoadingDelegate webViewDidFinishLoad:]): * TestWebKitAPI/Tests/ios/ScrollViewInsetTests.mm: (-[AsyncPolicyDelegateForInsetTest webView:didFinishNavigation:]): (TestWebKitAPI::TEST): Util::runUntil wants a bool, not a BOOL. * TestWebKitAPI/config.h: Import WebKitLegacy.h after WebKit.h. Traditionally WebKit.h includes WebKitLegacy.h, except in macCatalyst. Many tests depend on being able to get WebKitLegacy.h this way. * Scripts/webkitpy/style/checkers/sdkvariant.py: * Scripts/webkitpy/port/factory.py: * Scripts/webkitpy/port/mac.py: Add a MacCatalyst port behind --maccatalyst, and do the bare minimum required to get it working and finding the right binaries. It inherits from Mac instead of iOS because for the purposes of finding and running binaries, dealing with I/O, etc., these are 100% bona fide macOS products. Canonical link: https://commits.webkit.org/217114@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@251941 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2019-11-01 21:29:25 +00:00
endif
define build_target_for_each_module
for dir in $(MODULES); do \
${MAKE} $@ -C $$dir PATH_FROM_ROOT=$(PATH_FROM_ROOT)/$${dir}; \
exit_status=$$?; \
[ $$exit_status -ne 0 ] && exit $$exit_status; \
done; true
endef
all:
@$(build_target_for_each_module)
debug d:
@$(build_target_for_each_module)
release r:
@$(build_target_for_each_module)
release+assert ra:
@$(build_target_for_each_module)
testing t:
@$(build_target_for_each_module)
analyze:
@$(build_target_for_each_module)
clean:
@$(build_target_for_each_module)
installsrc:
@true