HomeiOS DevelopmentXcode construct fails with return code 65 throughout Azure DevOps pipeline archive...

Xcode construct fails with return code 65 throughout Azure DevOps pipeline archive step (Swift mission with submodules)


I’m making an attempt to construct and archive an iOS mission in an Azure DevOps pipeline, however the construct retains failing with return code 65 when operating the Xcode@5 job.

The mission construction:

  • Root repo incorporates CI/CD config (azure-pipelines.yml)
  • iOS mission (Core.xcworkspace) is a Swift native app that makes use of submodules
  • CocoaPods are used for dependency administration

Right here’s the related error snippet from the pipeline logs:

** ARCHIVE FAILED **

The next construct instructions failed:
    Archiving workspace NexoCore with scheme NexoCore
(1 failure)

##[error]Error: /usr/bin/xcodebuild failed with return code: 65

My pipeline YAML (related elements):

jobs:
  - job: ios
    pool:
      vmImage: 'macOS-latest'
    variables:
      configuration: "Launch"
      sdk: "iphoneos"
      scheme: "Core"
      system.debug: true
      derivedData: "DerivedData"
      outputDir: "$(construct.artifactStagingDirectory)"

    steps:
      - checkout: self
        submodules: recursive

      - script: |
          gem set up cocoapods --no-document
          pod set up --repo-update
        displayName: "Set up CocoaPods"

      - job: InstallAppleCertificate@2
        inputs:
          certSecureFile: 'AppCetificate.p12'
          certPwd: $(appCertificatePassword)
          keychain: 'temp'
          deleteCert: true

      - job: InstallAppleProvisioningProfile@1
        inputs:
          provProfileSecureFile: 'IOSProvisioningProfile.mobileprovision'
          removeProfile: true

      - job: Xcode@5
        inputs:
          actions: 'clear archive'
          configuration: '$(configuration)'
          sdk: '$(sdk)'
          xcWorkspacePath: 'Core.xcworkspace'
          scheme: '$(scheme)'
          xcodeVersion: 'specifyPath'
          xcodeDeveloperDir: '/Functions/Xcode_16.4.app'
          packageApp: true
          signingOption: 'handbook'
          signingIdentity: '$(APPLE_CERTIFICATE_SIGNING_IDENTITY)'
          provisioningProfileUuid: '$(APPLE_PROV_PROFILE_UUID)'
          args: '-derivedDataPath $(derivedData) -destination "generic/platform=iOS"'

What I’ve tried:

  • Verified the provisioning profile and certificates are uploaded appropriately in DevOps
  • Confirmed that submodules are checked out (submodules: recursive)
  • Ran pod set up with –repo-update to verify Pods are updated
  • Explicitly set Xcode model (/Functions/Xcode_16.4.app)
  • Used -destination "generic/platform=iOS"

Nonetheless, the archive step fails with code 65.

Xcode construct fails with return code 65 throughout Azure DevOps pipeline archive step (Swift mission with submodules)

I put in CocoaPods with pod set up –repo-update, checked out submodules, and arrange signing utilizing certificates + provisioning profile duties. I anticipated the Xcode@5 job to archive the workspace and generate an .ipa file, however as an alternative it fails with xcodebuild return code 65 in the course of the archive step.

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

- Advertisment -
Google search engine

Most Popular

Recent Comments