Bug 217068

Summary: [tvOS] [watchOS] Add support in libTestWTFAlwaysMissing-iOS-v2.tbd
Product: WebKit Reporter: Ryan Haddad <ryanhaddad>
Component: New BugsAssignee: Jonathan Bedard <jbedard>
Status: RESOLVED FIXED    
Severity: Normal CC: aakash_jain, jbedard, jlewis3, thorton, webkit-bot-watchers-bugzilla, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch none

Description Ryan Haddad 2020-09-28 17:15:02 PDT
Since the tvOS simulator bot was updated to the tvOS 14 SDK, the build has been failing with the following:

ld: warning: directory not found for option '-F/Applications/Xcode.app/Contents/Developer/Platforms/AppleTVSimulator.platform/Developer/SDKs/AppleTVSimulator14.0.sdk/System/Library/Frameworks/Quartz.framework/Frameworks'
ld: warning: building for tvOS Simulator, but linking in .tbd built for iOS Simulator, 'TestWTFAlwaysMissing-iOS-v2'
ld: warning: Could not find or use auto-linked library 'TestWTFAlwaysMissing-iOS-v2'
Undefined symbols for architecture x86_64:
  "_TestWTFAlwaysMissing", referenced from:
      TestWebKitAPI::WeakLinking_WeakImport_Test::TestBody() in libTestWTF.a(WeakLinking.o)
  "_TestWTFAlwaysMissingWithoutAttributeWeakImport", referenced from:
      TestWebKitAPI::WeakLinking_WeakImport_Test::TestBody() in libTestWTF.a(WeakLinking.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

https://build.webkit.org/builders/Apple-tvOS-Simulator-14-Release-Build/builds/1/steps/compile-webkit/logs/stdio

The tvOS device build seems OK.
Comment 1 Radar WebKit Bug Importer 2020-09-28 17:15:43 PDT
<rdar://problem/69724742>
Comment 2 Jonathan Bedard 2020-09-28 17:21:05 PDT
My bet is that we're somehow missing Tools/TestWebKitAPI/Tests/WTF/darwin/libTestWTFAlwaysMissing-iOS.tbd in the tvOS Simulator build.
Comment 3 Jonathan Bedard 2020-09-29 09:42:45 PDT
Created attachment 410011 [details]
Patch
Comment 4 Jonathan Bedard 2020-09-29 09:45:16 PDT
Looks like the rules for platform specifiers in tbd has gotten a bit more strict, I was able to reproduce this locally and this change fixes the problem. I'm pretty much certain that watchOS needs it as well.
Comment 5 Aakash Jain 2020-09-29 09:49:13 PDT
rs=me if EWS passes.
Comment 6 Jonathan Bedard 2020-09-29 12:31:00 PDT
Created attachment 410031 [details]
Patch
Comment 7 EWS 2020-09-29 13:13:32 PDT
Committed r267757: <https://trac.webkit.org/changeset/267757>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 410031 [details].