Skip to content

Consuming Protobuf via Protobuf-C++ podspec fails on XCode 14.3 #12944

Closed

Description

@Niranjan-B

What version of protobuf and what language are you using?
Version: 3.21.3
Language: Objective-C

What operating system (Linux, Windows, ...) and version?
MacOS

What runtime / compiler are you using (e.g., python version or gcc version)
clang version: 14.0.0

What did you do?
Steps to reproduce the behavior:

  1. Consume the protobuf library as a pod via the Protobuf-C++ spec.
  2. Build the project on XCode 14.3

What did you expect to see
A successful build.

What did you see instead?
Build fails with the following error -

ld: file not found: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/arc/libarclite_iphonesimulator.a
clang: error: linker command failed with exit code 1 (use -v to see invocation)

This linker error disappears when the iOS deployment target is set to a minimum of iOS 11.
There is a workaround where missing static libraries can be added to the correct path in XCode 14.3 but Apple does not recommend doing this.
The right approach would be to update the deployment target versions across Protobuf-C++.podspec, Protobuf.podspec and the xcode project.

Anything else we should know about your project / environment

Activity

  1. added
    untriagedauto added to all issues by default when created.
    on May 31, 2023
  2. Niranjan-B commented on May 31, 2023

    @Niranjan-B
    ContributorAuthor

    I can raise a PR to fix this issue, but please let me know if updating the deployment version to iOS 11.0 works.

    Just my 2 cents, I think it would be fine since nearly 85% of the users globally are on iOS versions 15.7 and up. (https://gs.statcounter.com/ios-version-market-share)

  3. added and removed
    untriagedauto added to all issues by default when created.
    on Jun 1, 2023
  4. added 3 commits that reference this issue on Jun 2, 2023
    7cc6871
    e484721
    ba71dac
  5. added a commit that references this issue on Aug 12, 2024
    d3242a1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions