Xcode 16 Beta Developer Portal Issue

There is a quite annoying regression that was introduced in Xcode 16 β2 that was not present in β1 nor Xcode 15.4 where the account that you are signed into’s credentials are not accessible on the command line via xcodebuild. Typically, in the keychain, you’d see Xcode-Token and Xcode-AlternateDSID indicating that Xcode has an account signed in and it uses those credentials to talk to the developer portal when you pass -allowProvisioningUpdates to your build....

TSan Breaks Exception Expectations

Yesterday, Apple released Xcode 15 β3 (15A195k) and I noticed that my tests started failing. These tests verified that an expectation was thrown from calling a method that should be unavailable. However, these tests were failing with an uncaught exception: xctest(8933,0x1f2049e00) malloc: nano zone abandoned due to inability to reserve vm space. Test Suite 'ExampleClassTest' started at 2023-07-06 07:40:43.904. Test Case '-[ExampleClassTest testInit]' started. 2023-07-06 07:40:43.907915-0500 xctest[8933:99736] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'init is unavailable for class ExampleClass' *** First throw call stack: ( 0 CoreFoundation 0x00000001971a3154 __exceptionPreprocess + 176 1 libobjc....

Leveraging Mergeable Libraries

When building your application with binary dependencies, you are either statically or dynamically linking them to your app. When statically linking, the symbols used are copied directly into the binary executable and discards the unused symbols. This increases the compile time of the app and the size of the binary executable, although some additional space savings (overall) can be had by using Link Time Optimization (LTO) and by using the -Os optimization level....

Xcode Supply Chain Security

Xcode 15 includes a few changes from Apple in an effort to harden the software supply chain. The majority of these changes are being phased in, while another is actively impacting developers attempting to test on the new OS versions with the new version of Xcode. First up is script sandboxing. Xcode 14 introduced a new build setting, ENABLE_USER_SCRIPT_SANDBOXING, that prevents shell scripts from accessing any files inside of SRCROOT and the Derived Data folder without being declared as inputs and outputs to the script....

Resource Bundle Code Signing

With Xcode 13.3, Apple introduced a new requirement for iOS applications to code sign any and all resource bundles. This has, apparently, been a requirement for Mac Catalyst for quite some time and has now made its way to the iOS platform. This is somewhat problematic for teams that consume resource bundles as part of a library/framework as the distributor cannot specify the code signing configuration on behalf of the consuming application....