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

Failed to build v1.10.0 #2274

Closed
oandreeva-nv opened this issue Aug 22, 2023 · 3 comments
Closed

Failed to build v1.10.0 #2274

oandreeva-nv opened this issue Aug 22, 2023 · 3 comments
Labels
bug Something isn't working

Comments

@oandreeva-nv
Copy link

Describe your environment

We build an opentelemetry as an external project here: https://github.com/triton-inference-server/third_party/blob/e2786f2029f1ca67fca4a0e071505e3423e9e97c/CMakeLists.txt#L478
v1.8.3 was fine, but now we need to upgrade to v1.10.0 due to critical bug in OTLP http exporter: #2191

My GCC version:

Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/11/lto-wrapper
OFFLOAD_TARGET_NAMES=nvptx-none:amdgcn-amdhsa
OFFLOAD_TARGET_DEFAULT=1
Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu 11.3.0-1ubuntu1~22.04.1' --with-bugurl=file:///usr/share/doc/gcc-11/README.Bugs --enable-languages=c,ada,c++,go,brig,d,fortran,objc,obj-c++,m2 --prefix=/usr --with-gcc-major-version-only --program-suffix=-11 --program-prefix=x86_64-linux-gnu- --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --libdir=/usr/lib --enable-nls --enable-bootstrap --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new --enable-gnu-unique-object --disable-vtable-verify --enable-plugin --enable-default-pie --with-system-zlib --enable-libphobos-checking=release --with-target-system-zlib=auto --enable-objc-gc=auto --enable-multiarch --disable-werror --enable-cet --with-arch-32=i686 --with-abi=m64 --with-multilib-list=m32,m64,mx32 --enable-multilib --with-tune=generic --enable-offload-targets=nvptx-none=/build/gcc-11-aYxV0E/gcc-11-11.3.0/debian/tmp-nvptx/usr,amdgcn-amdhsa=/build/gcc-11-aYxV0E/gcc-11-11.3.0/debian/tmp-gcn/usr --without-cuda-driver --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu --with-build-config=bootstrap-lto-lean --enable-link-serialization=2
Thread model: posix
Supported LTO compression algorithms: zlib zstd
gcc version 11.3.0 (Ubuntu 11.3.0-1ubuntu1~22.04.1) 

Failed to build v1.10.0 due to

In file included from /tmp/tritonbuild/tritonserver/build/_deps/repo-third-party-build/opentelemetry-cpp/src/opentelemetry-cpp/sdk/src/metrics/data/circular_buffer.cc:4:
/tmp/tritonbuild/tritonserver/build/_deps/repo-third-party-build/opentelemetry-cpp/src/opentelemetry-cpp/sdk/include/opentelemetry/sdk/metrics/data/circular_buffer.h:44:32: error: 'uint64_t' has not been declared
   44 |   void Increment(size_t index, uint64_t count);
      |                                ^~~~~~~~
/tmp/tritonbuild/tritonserver/build/_deps/repo-third-party-build/opentelemetry-cpp/src/opentelemetry-cpp/sdk/include/opentelemetry/sdk/metrics/data/circular_buffer.h:52:3: error: 'uint64_t' does not name a type
   52 |   uint64_t Get(size_t index) const;
      |   ^~~~~~~~
/tmp/tritonbuild/tritonserver/build/_deps/repo-third-party-build/opentelemetry-cpp/src/opentelemetry-cpp/sdk/include/opentelemetry/sdk/metrics/data/circular_buffer.h:9:1: note: 'uint64_t' is defined in header '<cstdint>'; did you forget to '#include <cstdint>'?
    8 | #include <limits>
  +++ |+#include <cstdint>
    9 | #include <vector>
/tmp/tritonbuild/tritonserver/build/_deps/repo-third-party-build/opentelemetry-cpp/src/opentelemetry-cpp/sdk/include/opentelemetry/sdk/metrics/data/circular_buffer.h:67:21: error: 'uint64_t' has not been declared
   67 |   void EnlargeToFit(uint64_t value);
      |                     ^~~~~~~~
/tmp/tritonbuild/tritonserver/build/_deps/repo-third-party-build/opentelemetry-cpp/src/opentelemetry-cpp/sdk/include/opentelemetry/sdk/metrics/data/circular_buffer.h:69:30: error: 'uint8_t' was not declared in this scope
   69 |   nostd::variant<std::vector<uint8_t>,

Steps to reproduce

Build flags are:

set(CMAKE_CXX_STANDARD "17" CACHE STRING "Initial cache" FORCE)
set(Protobuf_LIBRARIES "<path_to>/protobuf/lib/libprotobuf.a" CACHE STRING "Initial cache" FORCE)
set(Protobuf_INCLUDE_DIR "<path_to>/build/third-party/protobuf/include" CACHE STRING "Initial cache" FORCE)
set(Protobuf_PROTOC_EXECUTABLE "<path_to>/build/third-party/protobuf/bin/protoc" CACHE STRING "Initial cache" FORCE)
set(absl_DIR "<path_to>build/third-party/absl/lib/cmake/absl" CACHE PATH "Initial cache" FORCE)
set(nlohmann_json_DIR "<path_to>build/third-party/nlohmann_json/lib/cmake/nlohmann_json" CACHE PATH "Initial cache" FORCE)
set(CMAKE_BUILD_TYPE "Release" CACHE STRING "Initial cache" FORCE)
set(BUILD_TESTING "OFF" CACHE BOOL "Initial cache" FORCE)
set(WITH_EXAMPLES "OFF" CACHE BOOL "Initial cache" FORCE)
set(WITH_BENCHMARK "OFF" CACHE BOOL "Initial cache" FORCE)
set(WITH_ABSEIL "ON" CACHE BOOL "Initial cache" FORCE)
set(WITH_OTLP_GRPC "OFF" CACHE BOOL "Initial cache" FORCE)
set(WITH_OTLP_HTTP "ON" CACHE BOOL "Initial cache" FORCE)
set(OPENTELEMETRY_INSTALL "ON" CACHE BOOL "Initial cache" FORCE)
set(CURL_DIR "<path_to>/third-party/curl/lib/cmake/CURL" CACHE STRING "Initial cache" FORCE)
set(gRPC_DIR "<path_to>third-party/grpc/lib/cmake/grpc" CACHE PATH "Initial cache" FORCE)
set(CMAKE_POSITION_INDEPENDENT_CODE "ON" CACHE BOOL "Initial cache" FORCE)
set(CMAKE_BUILD_TYPE "" CACHE STRING "Initial cache" FORCE)
set(CMAKE_INSTALL_PREFIX "<path_to>/third-party/opentelemetry-cpp" CACHE PATH "Initial cache" FORCE)

Note, all paths are correct, I just masked them.

So steps would be : cmake with the above flags && make install

What is the expected behavior?
Successful build

What is the actual behavior?
build failed

Additional context
I've tried to manually include missing <cstdint> to opentelemetry-cpp/src/opentelemetrycpp/sdk/include/opentelemetry/sdk/metrics/data/circular_buffer.h and it fixed the issue. Thus, I have a question, is <cstdint> is trully missing from circular_buffer.h or it was left out intentionally and I am not setting flags properly?

@oandreeva-nv oandreeva-nv added the bug Something isn't working label Aug 22, 2023
@github-actions github-actions bot added the needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. label Aug 22, 2023
@ThomsonTan
Copy link
Contributor

ThomsonTan commented Aug 22, 2023

Can you please try v1.11.0 and see if it still reproduces? Sounds like it was fixed in below PR.

#2230

@oandreeva-nv
Copy link
Author

Thanks, v1.11.0 is working. May I ask when v1.11.0 will be officially released, since current lates version is indicated as v1.10.0?

@oandreeva-nv
Copy link
Author

oh, I see, it was release 1 hour ago. Thanks!

@marcalff marcalff removed the needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. label Aug 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants