libarclite always linked into static library, producing linker errors

Originator:steipete
Number:rdar://11433499 Date Originated:11-May-2012 08:22 PM
Status:Fixed Resolved:
Product:Dev Tools Product Version:4.4DP4
Classification:Regression / Serious Bug Reproducible:Always
 
11-May-2012 08:22 PM Peter Steinberger:
Summary:

Xcode 4.4 (all tested versions) libarclite is *always* linked into a binary, even for static libraries that *never*  should link libarclite, as this most likely always produces linker errors later on.

In 4.3, i solved the linking problem by setting the iOS min deployment target to 5.0 to NOT link it in. This is also far from ideal, but was a doable workaround.

Note that everything works great when using code as a submodule; however as I provide a commercial client this isn't a useful option.

Steps to Reproduce:

execute:

  `xcodebuild -project PSPDFKit.xcodeproj -scheme UniversalFramework -sdk iphoneos5.1`
check the Product folder, PSPDFKit.framework binary, contains libarclite when compiled with Xcode 4.4 but not with 4.3

(or open PSPDFKit.xcodeproj and compile the framework)

Expected Results:

No regression, no linking of libarclite.

Also, Xcode should be smart enough to not throw linker errors IF libarclite is linked multiple times.

Actual Results:

Regression:

Notes:

Contact steipete@gmail.com / @steipete for more information.

11-May-2012 08:25 PM Peter Steinberger:
'PSPDFKit.zip' was successfully uploaded

11-May-2012 08:30 PM Peter Steinberger:
You'll find the binary that contains libarclite in Products/PSPDFKit.framework/Versions/A/PSPDFKit

Comments

Fixed in Xcode 4.4DP6/Xcode 4.5DP1.


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!