Questions tagged [xcodebuild]
Questions related to the use of the command-line xcodebuild tool, which is part of Apple's Xcode toolset
1,392
questions
2
votes
2
answers
468
views
ld: warning: ignoring duplicate libraries: '-lgcc' after the recent update of Xcodebuild tools
Recently, I upgraded to Xcode 15, and with that the update of the xcodebuild tools. However, suddenly, my standalone C++ applications are not able to use the g++-13 compiler for some reason? Anyone ...
0
votes
0
answers
11
views
Get the output path or the ".xcresult" file of "xcodebuild test"
I am working on a bash script which executes UI tests via xcodebuild and I am looking for a way to retrieve the path where the test results (the .xcresult file) are generated
After I execute a command ...
0
votes
1
answer
56
views
React Native iOS builds break on the command line until I build once in Xcode
I'm running react-native iOS debug builds and I can see that it runs xcodebuild commands. I find that whenever there are dependency updates, the xcodebuild commands fail.
The actual errors are ...
0
votes
0
answers
26
views
xcodebuild failing to fetch a swift package
I've a swift Xcode (14.3.1) project that has some dependencies to swift packages, one of those is coming from a developer public github repo, while compiling the project with Xcode all works fine once ...
0
votes
0
answers
27
views
RxCocoa fails to archive via xcodebuild
I have a framework with RxSwift dependency added via SPM and when trying to archive my framework via the following script:
xcodebuild archive \
-project Project.xcodeproj \
-scheme Scheme \
...
-1
votes
2
answers
23
views
How to check whether xcodebuild succeeded in the post-action shell?
Is there any way to check if xcodebuild is successful in the post-action shell?
I want to run a custom script only when the build succeeds.
I checked env vars with the set command in the post-action ...
0
votes
0
answers
29
views
xcodebuild archive command does not create dSYM files inside the .xcarchive when running through Github actions
I am using Github actions to automate the build/deploy process for a project, and so within my .yml file, I have a step that uses the xcodebuild archive command to generate a .xcarchive file. The ....
0
votes
2
answers
229
views
Unable to Build App on iOS Simulator, but Android Works Fine - Xcode Error
I am facing an issue while trying to run my Flutter app on an iOS simulator using Xcode. The app runs smoothly on Android devices, but when I attempt to launch it on an iPhone 14 simulator in debug ...
1
vote
0
answers
53
views
how to build for testing iOS with xcode and run test on real device with CI
I am working on CI/CD for iOS development and I'm facing an issue with XCUITest. I want to build the project for testing and then upload the zip to pCloudy service to run test.
I tried to run it with ...
0
votes
0
answers
10
views
What does install option of xcodebuild do
When running xcodebuild from the command line. What does the install option do?
xcodebuild -configuration release install
For the release scheme in this example, what switches does install flip?
The ...
0
votes
0
answers
21
views
Custom binary for codesign in xcodebuild (handling timestamp service is unavailable)
On one of our projects, we have flaky errors from the codesign binary with timestamp service is unavailable errors. The thing is that these errors are happening way too random and cannot be reproduced ...
2
votes
1
answer
217
views
Xcode Build getting failed with "There are no accounts registered with Xcode. Add your developer account to Xcode"
I was trying to setup CI-CD to automate the build process using GitHub Actions. Steps followed are as mentioned below.
Create Keychain
Add certificate to Keychain
Unlock Keychain
Check if certificate ...
1
vote
0
answers
51
views
building for iOS Simulator, but linking in .tbd built for macOS/Mac Catalyst
In my iOS project, when I build my app from the command line with the following command :
xcodebuild -project Project.xcodeproj -scheme Scheme -destination 'platform=iOS Simulator,name=iPhone 14 Pro'
...
0
votes
0
answers
24
views
xcodebuild command in place of Fastlane
Currently we use fastlane to run tests. How to replace the following code with xcodebuild
arch -x86_64 bundle exec fastlane ui_tests
0
votes
0
answers
50
views
Xcode 14.3: Build and Archive error when copying private framework during build - framework: no such file or directory
Ever since I've upgrade to Xcode 14.3, our project has been failing to archive after build, with following error:
Copy /<redacted_path_to_project>/Build/Intermediates/ArchiveIntermediates/...
0
votes
0
answers
109
views
How to add an iOS version to xcodebuild?
I downloaded Xcode 15 beta 3 and am trying to generate screenshots for 5.5" displays, but "iPhone 8 Plus" only goes up to iOS 16.4 (not iOS 17).
When I run "fastlane snapshot",...
0
votes
0
answers
91
views
XCode 14.3.1 - M1 runner - xcodebuild - UI tests doesn't create clones of simulators
I'm having problems with UI tests on an M1 runner using Xcode 14.3.1. In my project, I need to build using the Rosetta simulator because I have a dependency that is not updated to support the arm ...
1
vote
1
answer
200
views
xcodebuild -exportArchive fails when not logged with appleid in xcode
xcodebuild \
-exportArchive -verbose \
-sdk iphoneos \
-archivePath XYZProject.xcarchive \
-exportOptionsPlist $RUNNER_TEMP/ExportOptions.plist \
-exportPath "" \
-...
0
votes
0
answers
205
views
SwiftEmitModule normal arm64 Emitting\ module\ for\ MyKit
I am creating a framework within I also have some pods installed, Now I want to create a Universal framework out of it, but I am facing issue doing that.
Here is the Command I am using to build for ...
2
votes
3
answers
171
views
Archiving successful but ends with BCSymbolMaps error and proceeding impossible because a similar file already exists
This error comes up after archiving
"A file with the name “0D43A9F9-2A23-386C-9568-E0D28099B3D5.bcsymbolmap” already exists.
To save the file, either provide a different name, or move aside or ...
0
votes
0
answers
32
views
Require provision profile with apple pay feature xcodebuild -exportArchive -archivePath
I am trying to export the ios(flutter) app using the manual command line as mentioned below. When I try to export ipa with this command it gives some profile-related error but when I checked the ...
0
votes
0
answers
16
views
Prompt "can't exec xcodebuild Operation Not Permitted" after Upgraded Xcode to 12.4 with macOS Catalina 10.15.7 [duplicate]
I am upgrading one of my dev machines to macOS 10.15 (last intel platform) to increase compatibility.
From following webpage: https://xcodereleases.com/, I noticed last compatible version with macOS ...
0
votes
0
answers
9
views
Newly Created Certificate is Already Expired on XCode
i'm trying to upload an app for days, had to move it from one mac to another, tried everthing on the internet to export the old certificate and private key to the new mac, but it just doesn't work. I ...
1
vote
0
answers
61
views
How to make the Xcode build a binary for my project into a consistent location, if I copy my project to another computer? [duplicate]
I am using Xcode 14.1 to build a native macOS app. It outputs the binary into a folder, as such:
/Users/<user>/Library/Developer/Xcode/DerivedData/ProjectName-<crazy_string>/Build/Products/...
2
votes
1
answer
800
views
Create .xcframework with dependencies
I am trying to create a custom Swift xcframework "FrameworkA" for a client based on my own code, which has a dependency to another 3rd party framework "FrameworkB" (which I ...
0
votes
0
answers
93
views
Xcode not using the latest scheme version
I am making a set of shell commands to generate a scheme for my iOS project. Now, when I create the scheme via Xcode GUI, the scheme generated uses the following version:
<?xml version="1.0&...
1
vote
1
answer
284
views
xcodebuild error in Xcode14.3 with argument DSTROOT
We are having a tool which internally create iPhone build using xcodebuild command line tool. It all working fine until Xcode14.3 release. Below is my build command
It uses SYMROOT and DSTROOT ...
1
vote
1
answer
47
views
Export Mac App via xcodebuild with Mac Developer & Mac Installer certificates
I'm trying to export my Mac App via Commandline, it works if I go through the Xcode interface, but I want to automate it.
I'm confused by the signing steps I need to go through as a Mac App has two ...
1
vote
0
answers
53
views
Using xcodebuild to install the build target onto a locally-connected iOS device
I'm trying to write a script that builds and installs my iOS project on one of my iOS devices.
I am not able to get xcodebuild to actually install the app on my iOS device:
xcodebuild -project ...
8
votes
0
answers
933
views
Internal inconsistency error (didStartTask)
Sometimes, about 2 times out of 10, when I run my application through Xcode, I get this error:
Internal inconsistency error (didStartTask): targetID (174) not found in _activeTargets.
Internal ...
-1
votes
1
answer
125
views
Is Xcode xcframework more secure from reverse engineering than a static lib .a?
We have an Xcode static lib with a single Swift public access func and a bunch of private C.
Would it be less vulnerable to reverse engineering to use "xcodebuild ... -library ..." to import ...
0
votes
0
answers
19
views
Rsync Error When Building Unity Project with Xcodebuild [duplicate]
I'm encountering an issue with building my Unity project using xcodebuild. Specifically, I'm getting an rsync error that is preventing the build from completing successfully. What's strange is that I ...
0
votes
1
answer
282
views
how to use xcodebuild to import a static lib into Xcode xcframework so that iOS app only calls xcframework
We have a propriety iOS static lib that contains Swift and C. We want to put its executable into our framework project, to protect it.
We build static lib into the xcframework with xcodebuild at ...
5
votes
4
answers
1k
views
xcodebuild ignores testPlan when using test-without-building
Consider this sample project: https://github.com/stremsdoerfer/TestPlan. This is just a Hello World that has two test plans: TestPlanUnit that only runs unit tests and TestPlanUI that only run UI ...
0
votes
0
answers
68
views
When I use xcodebuild to create xcframwork I got an error It should be caused by Google WebRTC May I ask how I will resolve this error
This is the xcodebuild terminal file I am using
BUILD_DIR=$(dirname "$PWD")/sdk/xc
PROJECT=$PWD/Example/SDK.xcworkspace
TARGET_DIR=$(dirname "$PWD")/sdk/archives
rm -Rf $...
0
votes
0
answers
135
views
React Native Expo project by migrating from "Manager" to "bare" workflow - "xcodebuild" throws "error code 65"
everybody.
I have built a React Native app using expo manage workflow, but then I enjected it from the manager to bare workflow by running - npx expo prebuild command. I followed Setting up the ...
0
votes
3
answers
100
views
In Bash, "No such file or directory" when using variable but not when using path directly [duplicate]
Context: I'm trying to clean my Xcode workspace and scheme via the command line. I've tried both trimming the quotes and not trimming them.
The current result is: -bash: ~/my/workspace/location: No ...
1
vote
0
answers
312
views
Xcode IOS build failing with random errors but also succeed after 1 or 2 retries
Currently we are in a very strange situation with our Xcode build for an IOS App. Archiving our app with
xcodebuild -workspace App.xcworkspace -scheme AppName -sdk iphoneos clean archive -archivePath ...
0
votes
0
answers
77
views
Mac - Appium - How to setup Xcode simulator with specific OS version and .app file through command line
While setting up Appium on Mac, I am stuck at a point where we have got .app file to automate on an iphone simulator.
I am able to launch app which comes with .xcodeproj on Xcode.
But now I have an ...
-1
votes
1
answer
541
views
Is it possible to run an Xcode Build Phase Script when running xcodebuild from the command line?
I have a build phase Run Script in my Xcode project that is required for ensuring the module bundle is up to date. The script runs when actions are executed through the Xcode GUI, and the Swift ...
2
votes
1
answer
2k
views
xcodebuild archive failing with SwiftEmitModule normal arm64 Emitting
I have a framework and it has other frameworks as dependency. I wanted to archive the framework for Device, Simulator to create XCFramework. when i run below command archive is failing with below ...
0
votes
0
answers
123
views
xcodebuild refuses to export archive without signing
I'm trying to export a debug IPA of my IOS App from my CI (Github Actions) and I don't figure out why it fails. The following commands work on my computer:
xcodebuild clean archive \
...
1
vote
0
answers
270
views
xcodebuild 14.2 create xcframework doesn't recognize mac catalyst static library build in rust
So I've build the following fat binary
➜ wallet-core git:(m/rust_fix) ✗ lipo -detailed_info build/local/catalyst/libwallet_core_rs.a
Fat header in: build/local/catalyst/libwallet_core_rs.a
fat_magic ...
0
votes
0
answers
39
views
Use a remote iOS device for testing
I want to run my UITests on iOS devices which are connected to a remote host. To put it differently:
I have a Mac mini (MM1) in my parent's house (for example), which is connected to the internet.
I ...
0
votes
0
answers
62
views
xcodebuild command is not building dependency of target
I am working on a C++ Xcode project. Let's say it PA.xcodeproj. I am building its target targetA using the command line:
xcodebuild -project PA.xcodeproj -target targetA
In targetA, I have specified ...
0
votes
0
answers
194
views
xcodebuild -create-xcframework copies dSym file to different folders randomly
I have following framework binaries:
Device.framework
Device.dSYM
Simulator_x86.framework
Simulator_arm.framework
I first create a fat binary from the 2 simulator files:
lipo -create
-output /...
0
votes
1
answer
47
views
Emit SwiftSupport directory for Ad Hoc builds
Is there a way to generate the SwiftSupport directory in Ad-hoc builds, i.e. without method=app-store in exportOptions.plist?
We build developer-signed .ipas for internal testing, then resign them ...
0
votes
1
answer
134
views
Xcode: build all the dependent targets when building a framework target
I have an Xcode project with a Framework A target.
That target depends on a few other modules, e.g. SubFramework A and SubFramework B.
When running the Xcodebuild command:
xcodebuild archive \
-scheme ...
3
votes
0
answers
369
views
Building a Flutter release build for iOS or Android results in an Out of memory error. Exhausted heap space
I've built several release builds in the past but suddenly my release builds are no longer working. My debug builds are working fine. I can not determine what has changed since the last time I ...
7
votes
1
answer
729
views
Extract App Intents Metadata - very slow build step
The app intents extraction from the new AppIntents framework takes a lot of time, even when changes in code don't touch the intents directly.
In the build log reasons for this step to happen differ, ...