Xcode fails to compile a framework target with Swift and ObjC if the build setting "use header map" is set to NO.
| Originator: | OteroNavarreteRicardo | ||
| Number: | rdar://31920700 | Date Originated: | 05/01/17 |
| Status: | Open | Resolved: | No |
| Product: | Development Tools | Product Version: | XCode: Version 8.3.2 (8E2002) ; MacOS Sierra: 10.12.4 |
| Classification: | Other Bugs | Reproducible: | Always |
Xcode fails to compile a framework target with Swift and ObjC if the build setting "use header map" is set to NO.
Steps to Reproduce:
Steps to Reproduce:
1. Create a new project and select 'Single View Application' as the type. Choose Objective-C as the language.
2. Add an empty Swift file
3. Go to the target build settings and set 'Use Header Maps' to NO
4. Press Product->Clean
5. Build the Framework
Expected Results:
The framework should successfully build
Actual Results:
Compiler error:
/Users/RO/Library/Developer/Xcode/DerivedData/SwiftHeaderSearchPathBug-byocisxzxhtkrjcmgvrxtpczadja/Build/Intermediates/SwiftHeaderSearchPathBug.build/Debug-iphonesimulator/FMWK1.build/unextended-module.modulemap:2:19: error: umbrella header 'FMWK1.h' not found
umbrella header "FMWK1.h"
^
<unknown>:0: error: could not build Objective-C module 'FMWK1'
Version:
MacOS Sierra 10.12.4
XCode Version 8.3.2 (8E2002)
Notes:
Similar to http://www.openradar.me/21038443
Configuration:
Except for the build setting 'Use Header Maps' everything other build setting is the default for the target.
In the sample code I created 2 framework targets for comparison:
* one is with 'Use Header Maps' to NO. And fails to build.
* the other is with 'Use Header Maps' to YES (the default). And builds ok.
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!