Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Request for Support: Integration of OpenTelemetry Swift SDK via XCFramework #659

Open
shahianshu opened this issue Dec 19, 2024 · 0 comments

Comments

@shahianshu
Copy link

shahianshu commented Dec 19, 2024

Hello Team,

At Uber, we are working on integrating the opentelemetry-swift library to enable context propagation and tracing in our iOS applications. However, since our internal policy only permits the inclusion of open-source libraries via XCFramework files, integrating the opentelemetry-swift SDK has become a challenge.

Currently, we rely on a manual process to generate the XCFramework file.
Below are the steps used for obtaining XCFramework file

  1. xcodebuild -scheme OpenTelemetryApi -sdk iphoneos -configuration Release
    BUILD_LIBRARY_FOR_DISTRIBUTION=YES ARCHS=arm64 BUILD_DIR=./Build -destination "generic/platform=iOS"
  2. pushd Build/Release-iphoneos 
  3. ar -crs libOpenTelemetryApi.a OpenTelemetryApi.o
  4. popd
  5. xcodebuild -scheme OpenTelemetryApi -sdk iphonesimulator -configuration Release BUILD_LIBRARY_FOR_DISTRIBUTION=YES ARCHS=arm64 BUILD_DIR=./Build -destination "generic/platform=iOS Simulator"
  6. pushd Build/Release-iphonesimulator 
  7. ar -crs libOpenTelemetryApi.a OpenTelemetryApi.o
  8. Popd
  9. pushd Build
  10. xcodebuild -create-xcframework -library Release-iphonesimulator/libOpenTelemetryApi.a -library Release-iphoneos/libOpenTelemetryApi.a -allow-internal-distribution -output OpenTelemetryApi.xcframework
  11. popd

We aim to streamline this process to reduce manual intervention and associated risks.
Looking forward to your suggestions or any official support to simplify and optimize the integration of the opentelemetry-swift SDK.

Thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant