open-telemetry / opentelemetry-swift

OpenTelemetry API for Swift
https://opentelemetry.io/docs/instrumentation/swift/
Apache License 2.0
207 stars 124 forks source link

Adding pod specification file #506

Closed Archish27 closed 7 months ago

Archish27 commented 7 months ago

Currently opentelemert swift cannot be used with cocoapods. Goal is to make compatible with cocoapods example,

s.dependency = "OpenTelemetrySwift", "~> 1.9.1"

nachoBonafonte commented 7 months ago

There are no plans to add support for it, at least not from the team. I would say the best solution would be that you create locally a framework and link it directly or expose it from a custom cocoapods repository.

The reason for it is that some of our dependencies are not available from Cocoapods, so that limits us. We are also not releasing any binary in our project, so we cannot distribute the binaries through Cocoapods

Archish27 commented 1 month ago

@nachoBonafonte Any guide or help can you provide for the same?

nachoBonafonte commented 1 month ago

The approach would be generating a binary xcframework on your side and expose that xcframework using Cocoapods. You should link only those targets that you are interested in. There should be lots of documentation out there about those two topics.