Skip to content

Commit 8185906

Browse files
committed
lib: remove opentelemetry files and use fluent-otel-proto library instead
Signed-off-by: Eduardo Silva <[email protected]>
1 parent ed6adc3 commit 8185906

19 files changed

+21
-7761
lines changed

.gitmodules

+3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
11
[submodule "lib/cfl"]
22
path = lib/cfl
33
url = https://github.com/fluent/cfl
4+
[submodule "lib/fluent-otel-proto"]
5+
path = lib/fluent-otel-proto
6+
url = https://github.com/fluent/fluent-otel-proto

CMakeLists.txt

+10
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ endif()
5151

5252
# Bundled libraries
5353
include(cmake/libraries.cmake)
54+
include(cmake/headers.cmake)
5455

5556
# Include headers and dependency headers
5657
include_directories(
@@ -189,6 +190,15 @@ if (NOT CTR_HAVE_CFL)
189190
CTR_DEFINITION(CTR_HAVE_CFL_INTERNAL)
190191
endif()
191192

193+
# fluent-otel-proto
194+
if (NOT CTR_HAVE_FLUENT_OTEL_PROTO)
195+
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/${CTR_PATH_LIB_FLUENT_OTEL_PROTO}/include)
196+
CTR_OPTION(FLUENT_PROTO_EXAMPLES "off")
197+
add_subdirectory(lib/fluent-otel-proto)
198+
CTR_DEFINITION(CTR_HAVE_FLUENT_OTEL_PROTO)
199+
CTR_DEFINITION(CTR_HAVE_FLUENT_OTEL_PROTO_INTERNAL)
200+
endif()
201+
192202
# Source code
193203
add_subdirectory(include)
194204
add_subdirectory(src)

cmake/headers.cmake

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
include_directories(${PROJECT_BINARY_DIR}/lib/fluent-otel-proto)

cmake/libraries.cmake

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
# List of bundled libraries
2-
set(CTR_PATH_LIB_CFL "lib/cfl")
2+
set(CTR_PATH_LIB_CFL "lib/cfl")
3+
set(CTR_PATH_LIB_FLUENT_OTEL_PROTO "lib/fluent-otel-proto")

examples/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ set(src
44
)
55

66
add_executable(ctraces-simple-c-api ${src})
7-
target_link_libraries(ctraces-simple-c-api ctraces-static)
7+
target_link_libraries(ctraces-simple-c-api ctraces-static fluent-otel-proto)
88

99
# example: opentelemetry decoder -> ctrace
1010
set(src

examples/otlp-decoder.c

+1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
#include <ctraces/ctraces.h>
2+
#include <fluent-otel-proto/fluent-otel.h>
23

34
int main()
45
{

include/opentelemetry/opentelemetry_common.pb-c.h

-271
This file was deleted.

0 commit comments

Comments
 (0)