open-telemetry / opentelemetry-swift

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

xcodebuild on OpenTelemetryProtocolExporterHTTP fails #603

Open palmer-sn opened 1 month ago

palmer-sn commented 1 month ago

This line: xcodebuild -scheme OpenTelemetryProtocolExporterHTTP -sdk iphoneos -configuration Release BUILD_LIBRARY_FOR_DISTRIBUTION=YES ARCHS=arm64 BUILD_DIR=./Build -destination "generic/platform=iOS"

fails.

Looks to be a problem with SwiftProtobuf...

LucasCarvalho00 commented 1 month ago

I have the same error.

When trying to export the project, it says that the minimum iOS version need to be 17.2 for SwiftProtobuf.

Can anyone help us with how to fix it or force it to stay with the minimum iOS version the same of the project?

bryce-b commented 1 month ago

The issue seems to only occur when specifying BUILD_DIR. Perhaps there is another build config that needs to be specified?

atreat commented 1 month ago

Would also try -derivedDataPath ./Build instead of BUILD_DIR. This seems like xcodebuild is getting confused