XCBuild warns about static frameworks linking dynamic frameworks like Foundation
| Originator: | keithbsmiley | ||
| Number: | rdar://34873444 | Date Originated: | 07-Oct-2017 14:29 |
| Status: | Duplicate of 34314195 (open) | Resolved: | |
| Product: | Developer Tools | Product Version: | Xcode 9.1 beta (9B37) |
| Classification: | Other Bug | Reproducible: | Always |
Summary: Currently if you have a project with an empty static framework, and you add Foundation to its "Link Binary With Libraries" phase, XCBuild emits a warning in the build log about it. Steps to Reproduce: 1. Create a new project (and switch to XCBuild) 2. Add a framework target, and change it's Mach-O type to "Static Library" 3. Add Foundation to its "Link Binary With Libraries" phase 4. Build the static framework target Expected Results: There are no build warnings Actual Results: XCBuild emits a warning in the build log that says: ``` warning: Target StaticFramework product StaticFramework cannot link framework Foundation.framework ``` Version: Xcode 9.1 beta (9B37) Notes: This could be the intended behavior and previously we were just doing this wrong? Also note that this warning isn't emitted for static library targets. See the attached project for an example.
Comments
Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!