The flags like #if DEBUG ... endif are dependent on the Active Compilation Conditions. So if they say DEBUG the enclosed code block will be executed, otherwise not.
Now I have the phenomenon that a #DEBUG block in a Package does not evaluate these conditions. It rather depends on the name of the configuration used to build.
So if I build my app with Active Compilation Condition set to DEBUG, but the configuration name is something like App-Release, the DEBUG block in my Package is not added/executed. The ones which are directly in the project are added.
Vice versa if the Compilation Condition say RELEASE but the configuration is called App-Debug the blocks in the Package are added to the compilation, but the ones in the project itself are not
It suffices that the config name contains the word Debug for this to happen. E.g. the configuration App-Release-Debug (I know that this would be stupid, but it is for demonstrating purposes) will cause the Packages to include the DEBUG blocks.
This happens no matter what you set in the Build Settings of the project and/or target.
The Packages are added via GitHub/GitLab Source Control with SPM.
Any ideas why this behaves like it does? It doesn't seem like it should...
Xcode
RSS for tagBuild, test, and submit your app using Xcode, Apple's integrated development environment.
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
Hi all,
I'm encountering a strange crash issue during local iOS debugging on a real device, and I'm hoping someone can help explain it.
The crash log contains unusually high offsets that are completely outside of any module address ranges listed in Binary Images. For example:
6 ??? 0x129ac0ee8 -[...:] + 1052
But the Binary Images section shows:
0x102358000 - 0x102363fff ChinaMobile arm64 ...
0x11bb2c000 - 0x11bdeffff ChinaMobile.debug.dylib arm64 ...
...
There are two binaries for my app listed here, but neither matches that high crash address (0x129ac0ee8).
Additionally, sometimes the Binary Images section doesn't even include my app's binary at all, which makes the crash logs even harder to analyze.
This crash definitely happens inside my main app’s business code, yet the crash offset doesn’t match any listed binary range.
Also, the crash logs contain many ??? module names and missing symbols, even though I'm running a Debug build locally, and I know how to symbolize logs manually.
My Questions:
Why does the crash log show such high offsets, far beyond any Binary Images' range?
Why does it have so many ??? entries and missing symbols, even in a local debug build?
Could this be related to Xcode version, build settings, or some project misconfiguration?
Any suggestions or insights would be greatly appreciated!
Topic:
Developer Tools & Services
SubTopic:
Xcode
Trying to test applications on AVP as opposed to simulator. AVP can connect to MacBook via Mac virtual display so connection exists, but in X code under Windows devices the AVP does not show up same holds true on the AVP itself under remote devices. The MacBook Pro does not appear. I am signed in under the same account on the same Wi-Fi network. I have tried all basic troubleshooting. It is not clear to me that I am logged in as a developer, which could be the issue, but I am using OS 26, which does not appear to have the developer option under privacy and security where it used to reside in previous versions of the OS.
We use Perforce for version control, which means that all files not checked out are readonly. Lately Xcode has started displaying a fixed sequence of these dialogs on every launch:
This means it is trying to modify some readonly file within the xcodeproj. Out of our 60 subprojects this always comes up for the exact same 6.
I have so far uncovered the following:
It is really trying to modify the shared xcschemes and not the pbxproj. (If I set those to writable the dialog does not appear.)
Actually the files are not changed if I click "Unlock", but the com.apple.provenance xattr flag is removed from them.
These xcschemes are of version 1.7 while all others are 1.3.
If I change them to 1.3 Xcode still wants to modify them at launch and sets them back to 1.7.
This is very annoying. What is it about these xcschemes that upsets Xcode, and how can I stop these dialogs from appearing?
(One workaround is to keep them checked out dumped to a changelist that I never submit, but that is error prone when I do need to make changes to those, and also is not really possible when jumping between old states of the repo to find the change that broke something.)
Topic:
Developer Tools & Services
SubTopic:
Xcode
I want to statically link xcframework as binaryTarget in Swift Package, but it is copied into the product as dynamic when the Xcode build. How to use xcframework in SwiftPackage and statically link it into iOS product?
The Package.swift content and the project are:
The WebP.xcframework is static:
The Xcode Build Product's WebP.framework is dynamic:
I have downloaded the new Xcode beta, signed in with my ChatGPT account yet there is still no model available for me to select.
I have reinstalled Xcode, logged in and out of the ChatGPT integration a dozen times, pressed every single button, but nothing seems to make a model appear? Am I stupid or am I missing something?
Topic:
Developer Tools & Services
SubTopic:
Xcode
Hey everyone,
I'm encountering an issue when trying to run my iOS application, which integrates a Unity project, on the iOS Simulator. I'm consistently getting a dlopen error 232 related to UnityFramework.framework.
The full error message is:
Error loading ...UnityFramework.framework/UnityFramework (232): dlopen(...UnityFramework.framework/UnityFramework, 0x0109): tried: '...UnityFramework.framework/UnityFramework' (mach-o file (...UnityFramework.framework/UnityFramework), but incompatible platform (have 'iOS', need 'iOS-sim'))
It seems like the UnityFramework.framework is built for a physical iOS device (ARM architecture), but the simulator requires a different architecture (x86_64 for Intel Macs or arm64 for Apple Silicon Macs).
I've already tried:
Cleaning the build folder in Xcode.
Checking the "Frameworks, Libraries, and Embedded Content" settings in my target's General tab.
Could anyone provide guidance on how to properly configure my Unity build or Xcode project to ensure UnityFramework.framework includes the necessary simulator architectures?
Any specific build settings in Unity or Xcode, or steps to re-export/re-integrate the framework, would be greatly appreciated!
Thanks in advance for your help!
Topic:
Developer Tools & Services
SubTopic:
Xcode
I am having an issue with signing and provisioning a Vision OS app. I have an iOS app and a VisionOS app. Everything works fine on the iOS but having issues with the VisionOS.
First, I am having issues with xcodebuild -exportArchive. When I run it on an archive of my VisionOS app I get
** EXPORT FAILED **
error: exportArchive No Accounts
error: exportArchive No profiles for 'X' were found
Where X is my bundle ID. Meanwhile the iOS app succeeds. This is on a CI machine but I confirmed the distribution provision profile for the vision OS app is installed on the machine. Even if I change the value of the -exportOptionsPlist to the one I used for the iOS project I get this error. Is the issue in the archive itself?
The archives are generated from building in Unity and archiving the xcodeproject with xcodebuild archive
Second, as a workaround I archived a debug ipa on my machine and uploaded this ipa to my CI machine which has the credentials to sign for distribution. I use this script as an example as how to resign the IPA: https://gist.github.com/lodalo/754a35b48d382ae99b25
I remove the CodeSignatures and codesign both .app and UnityFramework.framework. Using this resigned IPA I get this error when I try to upload to app store connect (via Transporter app and altool)
errors: Validation failed (409) Missing or invalid signature. The bundle 'X' at bundle path 'Payload/Y.app' is not signed using an Apple submission certificate.
To verify the signing I used
codesign -dvvv --entitlements -
On both the iOS and VisionOS app and they have the same values under all the Authority fields. Different profiles, of course. So the certificate I used is eligible to upload the iOS app successfully but doesn't work on the VisionOS ipa?
Any help on solving any of these issues would be great so I can upload the vision OS app. Thank you!
Topic:
Developer Tools & Services
SubTopic:
Xcode
Tags:
App Store Connect
Command Line Tools
Code Signing
visionOS
Hi,
in XCode and iOS app. Tried to add Icon, got image size errors. reuploaded with correct sizes and started getting this error.
Tried all the solutions from forums, didn't work.
Restarted Mac
Deleted Assets.xcassets and recreated with AppIcon and AccemntColor
Copied "Assets.xcassets" from new dummy Project to main one.
I don't have info.plist file
Could you please help.
Thanks,
Bhanu
Topic:
Developer Tools & Services
SubTopic:
Xcode
I am writing to report multiple issues encountered after updating to Xcode 26 Beta, which have significantly impacted my project's compilation and functionality. My project can run normally in Xcode16.3 version, Below are the specific problems, along with the steps I took to address them and the subsequent errors that arose:
Symbol Not Found Error for _NSUserActivityTypeBrowsingWeb
After updating to Xcode 26 Beta, my project failed to build with the error: "Symbol not found: _NSUserActivityTypeBrowsingWeb." To resolve this, I removed the MobileCoreServices framework from the Build Settings, as it appeared to be related. However, this led to a new error, indicating that this change introduced further complications.
Clang++ Error: No Such File or Directory 'OpenGLES'
Following the resolution of the first issue, I encountered a new error: "iOS clang++: error: no such file or directory: 'OpenGLES'." To address this, I added the OpenGLES.framework to the Build Phases. While this resolved the clang++ error, it triggered additional errors, suggesting that the underlying issue persists or new dependencies are conflicting.
Recurring XIB File Compilation Errors
My project uses XIB files, and every time I attempt to compile and run, Xcode reports errors related to different XIB files. Notably, when I open the reported XIB file, no errors are displayed within the Interface Builder. After saving or inspecting the file, the compilation error temporarily disappears, only for another XIB file to trigger the same issue in the next build. This creates a repetitive cycle. I have confirmed this is not a caching issue, as I clean the build cache (Product > Clean Build Folder) before each run. If I skip cleaning the cache, the OpenGLES-related error (Issue 2) reappears, indicating potential interactions between these problems.
These issues have made development with Xcode 26 Beta extremely challenging, as each attempted fix seems to introduce new errors, and the XIB issue creates a persistent loop. My setup includes:
Xcode Version: 26.0 beta 2 (17A5241o)
macOS Version:15.4.1 (24E263)
When I run the debug memory graph from Xcode I'm getting a set of system objects with warnings.
Are there any tips on how to locate what might be causing these?
We can see from App Store Connect under TestFlight tab on the overview that our build got X number of crashes.
Problem is that these crashes are not found in Crash feedback tab or not from Xcode Organizer.
This problem has been ongoing for us in multiple different app builds now.
Is there any suggestions what might cause this problem and how to start solving this? I'm pretty confident that these crashes happen in our network extension (NEPacketTunnelProvider).
Note - We have a lot of TestFlight users and to start asking them all separately manual logs from phone might not help us here. (Settings > Privacy > Analytics & Improvements > Analytics Data).
Also these crashes have not been reported to us by the users. I suspect that the reason is that the extension kicks automatically back up since we are running VPN there with on demand rules. Meaning that the users might not be able to notice the service crash or shut down because of the automatic restart.
Thanks
I'm integrating Apple Pay with PayFort in a Swift iOS application, and I’m currently working on preparing a valid purchase request using Apple Pay, as described in PayFort’s documentation:
🔗 https://docsbeta.payfort.com/docs/api/build/index.html?shell#apple-pay-authorization-purchase-request
The documentation outlines the following required parameters:
apple_data
apple_signature
apple_header
apple_transactionId
apple_ephemeralPublicKey
apple_publicKeyHash
apple_paymentMethod
apple_displayName
apple_network
apple_type
Optional: apple_applicationData
I understand these should be derived from the PKPayment object after Apple Pay authorization, but I’m having trouble mapping everything correctly. Here’s what I’m seeing in code:
payment.token
// Returns something like: <PKPaymentToken: 0x28080ae80; transactionIdentifier: "..."; paymentData: 3780 bytes>
payment.token.paymentData
// Contains 3780 bytes of encrypted data
payment.token.paymentData.base64EncodedString()
// Returns a long base64 string, which at first glance seems like it could be used for apple_data,
// but PayFort doesn't accept it as-is — so this value appears to be incomplete or incorrectly formatted
I can successfully retrieve the following values from payment.token.paymentMethod:
apple_displayName
apple_network
apple_type
However, I’m still unsure how to extract or build the following in the format accepted by PayFort:
apple_data
apple_signature
apple_header
apple_transactionId
apple_ephemeralPublicKey
apple_publicKeyHash
apple_paymentMethod
These may be contained within the paymentData JSON, but I’m not sure how to decode it or if Apple allows decrypting it in a way that matches PayFort’s expected format.
How can I correctly extract or build apple_data, apple_signature, and apple_header from the Apple Pay token?
Also, how should I handle the decryption or decoding (if necessary) of paymentData to retrieve values like apple_transactionId, apple_ephemeralPublicKey, and apple_publicKeyHash?
If anyone has successfully set this up or has example code that bridges Apple Pay and PayFort’s expected request format, it would be super helpful!
Thanks in advance 🙏
I'm wondering why 'Select Previous Completion' and 'Select Next Completion' aren't working. I'm using Ctrl-K and Ctrl-J but only my arrow keys work to navigation the completion list. 'Show Completion List' works just fine with Ctrl-Esc.
There are no conflicts with any Xcode bindings, and I've checked my system settings for keyboard shortcuts as well..
I've completely disabled copilot, etc..
Is there another setting I'm missing? Or, is this a known issue?
Topic:
Developer Tools & Services
SubTopic:
Xcode
Hi,
I'm unable to install provisioning profile on my iPad and I know the xcode component iOS/iPadOs version and iPadOS version should be same or below the latest compared to xcode components.
Now the issue is xcode component version is iOS 18.4 (22E235) SDK + iOS 18.4 (22E238) Simulator (Installed) and iPadOS version is iOS 18.4.1(22E252) could this be cause of issue ?
If yes then when will apple release components for 18.4.1?
Because iOS 18.4.1 release at least 3-4 weeks before this post.
During the Camera lab session at WWDC25, support for DICOM was mentioned. I'm trying to work with the new AVFileType dcm to help with handling DICOM scans. Can anyone provide some assistance?
I have a couple apps in one git repository. I'd like to have a Swift package in that repo as well, shared by apps. In other words, I don't want a separate repo for the Swift package. I followed the instructions here:
https://developer.apple.com/documentation/xcode/organizing-your-code-with-local-packages
It seems to work. I can write code like this in my app:
import MyLocalPackage
func foo() {
myLocalPackageFunc()
}
I notice that the package is not listed under Project > MyApp > Package Dependencies. I don't really care, as long as I can reuse code between apps.
But when I try to add this package code to a 2nd app, I'm at a loss. I tried "Add Package Dependencies" and "Add Local", but that creates a different looking setup than the 1st app. The code is browsable in the project navigator. And when I try to build it says "Missing package product 'MyLocalPackage'.
The documentation linked above, which I used for the 1st app, does a "New > Package". I don't want a new package. How can I connect the existing one?
how do we add google models, deepseek, or mistral into xcode 26 intelligence model providers ?
Hey iOS Dev's,
I’m currently working on a Swift Package Manager (SPM) for WireGuard, originally developed by a previous team member. It was working fine in Xcode 15.2, but after upgrading to Xcode 16 and Swift 6, I need to update the SPM to ensure compatibility with my base projects and other projects relying on it.
With Apple making Xcode 16 mandatory for app submissions starting April 24, this has become an urgent issue. I’ve searched extensively but haven’t found a working solution yet.
Has anyone faced similar challenges with Swift 6 migration and SPM updates? Any insights, best practices, or debugging tips would be greatly appreciated!
Let’s connect and collaborate—I’d love to discuss possible solutions! 😊
#iOSDevelopment #Swift6 #Xcode16 #SPM #WireGuard #iOS #Swift #SoftwareEngineering #AppStore
Hi everyone,
I’m running into an issue trying to use the new SpeechAnalyzer framework announced at WWDC 2025.
❯ My Setup:
• macOS: Sequoia 15.5 (Build 26.0 / macOS Tahoe Beta 26.0)
• Xcode: 26.0 beta 2 (17A5241o)
• Deployment Target: macOS 26.0
• Toolchain: Clang 17.0.0 (Apple)
❯ Problem:
Despite following all setup requirements:
• Setting macOS 26 as the deployment target
• Using the latest Xcode 26 beta 2
• Running the correct developer toolchain (xcode-select is pointing to Xcode-beta)
I still get the error: No such module 'SpeechAnalyzer'
Additionally:
• The SpeechAnalyzer.framework does not appear under /Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/
• It is also not listed in the Link Binary with Libraries pane.
❯ What I’ve Tried:
• Clean builds
• Deleted DerivedData
• Verified SDK installation paths
• Reinstalled Xcode 26 beta 2
• find search for SpeechAnalyzer.framework returned nothing
❯ Request:
Has anyone successfully used SpeechAnalyzer in Xcode 26 beta 2 on macOS Sequoia/Tahoe?
Is there a separate SDK or seed profile required to access this framework?
Would appreciate any guidance from Apple engineers or other beta testers.
Thanks!
— Lalit Lakhara