Skip to content

Commit 8460283

Browse files
committed
Fix CMake build
1 parent c89d441 commit 8460283

File tree

5 files changed

+42
-82
lines changed

5 files changed

+42
-82
lines changed

CMakeLists.txt

Lines changed: 5 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

build_autogenerated.yaml

Lines changed: 8 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

test/cpp/ext/otel/otel_tracing_test.cc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
#include "gtest/gtest.h"
2424
#include "opentelemetry/exporters/memory/in_memory_span_exporter_factory.h"
2525
#include "opentelemetry/sdk/trace/simple_processor_factory.h"
26+
#include "opentelemetry/sdk/trace/tracer.h"
2627
#include "opentelemetry/sdk/trace/tracer_provider.h"
2728
#include "src/core/config/core_configuration.h"
2829
#include "src/core/telemetry/call_tracer.h"

tools/buildgen/extract_metadata_from_bazel_xml.py

Lines changed: 28 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -359,6 +359,13 @@ def _external_dep_name_from_bazel_dependency(bazel_dep: str) -> Optional[str]:
359359
return "opentelemetry-cpp::api"
360360
elif bazel_dep == "@io_opentelemetry_cpp//sdk/src/metrics:metrics":
361361
return "opentelemetry-cpp::metrics"
362+
elif bazel_dep == "@io_opentelemetry_cpp//sdk/src/trace:trace":
363+
return "opentelemetry-cpp::trace"
364+
elif (
365+
bazel_dep
366+
== "@io_opentelemetry_cpp//exporters/memory:in_memory_span_exporter"
367+
):
368+
return "opentelemetry-cpp::in_memory_span_exporter"
362369
else:
363370
# Two options here:
364371
# * either this is not external dependency at all (which is fine, we will treat it as internal library)
@@ -1010,7 +1017,6 @@ def _generate_build_extra_metadata_for_tests(
10101017
" to %s" % (test_name, long_name)
10111018
)
10121019
test_metadata[test_name]["_RENAME"] = long_name
1013-
print(test_metadata["test/cpp/ext/otel:otel_plugin_test"])
10141020
return test_metadata
10151021

10161022

@@ -1322,6 +1328,27 @@ def _detect_and_print_issues(build_yaml_like: BuildYaml) -> None:
13221328
"plugin_option": "gRPC_BUILD_GRPCPP_OTEL_PLUGIN",
13231329
"_RENAME": "otel_plugin_test",
13241330
},
1331+
"test/cpp/ext/otel:grpc_text_map_carrier_test": {
1332+
"language": "c++",
1333+
"build": "plugin_test",
1334+
"_TYPE": "target",
1335+
"plugin_option": "gRPC_BUILD_GRPCPP_OTEL_PLUGIN",
1336+
"_RENAME": "grpc_text_map_carrier_test",
1337+
},
1338+
"test/cpp/ext/otel:grpc_trace_bin_text_map_propagator_test": {
1339+
"language": "c++",
1340+
"build": "plugin_test",
1341+
"_TYPE": "target",
1342+
"plugin_option": "gRPC_BUILD_GRPCPP_OTEL_PLUGIN",
1343+
"_RENAME": "grpc_trace_bin_text_map_propagator_test",
1344+
},
1345+
"test/cpp/ext/otel:otel_tracing_test": {
1346+
"language": "c++",
1347+
"build": "plugin_test",
1348+
"_TYPE": "target",
1349+
"plugin_option": "gRPC_BUILD_GRPCPP_OTEL_PLUGIN",
1350+
"_RENAME": "otel_tracing_test",
1351+
},
13251352
# TODO(jtattermusch): create_jwt and verify_jwt breaks distribtests because it depends on grpc_test_utils and thus requires tests to be built
13261353
# For now it's ok to disable them as these binaries aren't very useful anyway.
13271354
# 'test/core/security:create_jwt': { 'language': 'c', 'build': 'tool', '_TYPE': 'target', '_RENAME': 'grpc_create_jwt' },

tools/run_tests/generated/tests.json

Lines changed: 0 additions & 72 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)