getsentry / relay

Sentry event forwarding and ingestion service.
https://docs.sentry.io/product/relay/
Other
318 stars 91 forks source link

RHEL/Centos 7 compatibility #1137

Closed futureweb closed 2 years ago

futureweb commented 2 years ago

Unfortunately it's not possible to run the relay Binary on Centos 7 Servers.

# ./relay-Linux-x86_64 
./relay-Linux-x86_64: /lib64/libc.so.6: version `GLIBC_2.18' not found (required by ./relay-Linux-x86_64)
./relay-Linux-x86_64: /lib64/libc.so.6: version `GLIBC_2.25' not found (required by ./relay-Linux-x86_64)

Also building the Sources manually won't work seamless:

error: failed to run custom build command for `relay-crash v21.11.0 (/dl/sentry/relay/relay-crash)`

Caused by:
  process didn't exit successfully: `/dl/sentry/relay/target/debug/build/relay-crash-cd94ce90247f9139/build-script-build` (exit status: 101)
  --- stdout
  cargo:rustc-link-lib=dylib=stdc++
  cargo:rustc-link-lib=curl
  CMAKE_TOOLCHAIN_FILE_x86_64-unknown-linux-gnu = None
  CMAKE_TOOLCHAIN_FILE_x86_64_unknown_linux_gnu = None
  HOST_CMAKE_TOOLCHAIN_FILE = None
  CMAKE_TOOLCHAIN_FILE = None
  CMAKE_GENERATOR_x86_64-unknown-linux-gnu = None
  CMAKE_GENERATOR_x86_64_unknown_linux_gnu = None
  HOST_CMAKE_GENERATOR = None
  CMAKE_GENERATOR = None
  CMAKE_PREFIX_PATH_x86_64-unknown-linux-gnu = None
  CMAKE_PREFIX_PATH_x86_64_unknown_linux_gnu = None
  HOST_CMAKE_PREFIX_PATH = None
  CMAKE_PREFIX_PATH = None
  CMAKE_x86_64-unknown-linux-gnu = None
  CMAKE_x86_64_unknown_linux_gnu = None
  HOST_CMAKE = None
  CMAKE = None
  running: "cmake" "/dl/sentry/relay/relay-crash/sentry-native" "-DSENTRY_BACKEND=breakpad" "-DBUILD_SHARED_LIBS=OFF" "-DSENTRY_BUILD_TESTS=OFF" "-DSENTRY_BUILD_EXAMPLES=OFF" "-DCMAKE_INSTALL_PREFIX=/dl/sentry/relay/target/debug/build/relay-crash-a0f4db61ff33d05b/out" "-DCMAKE_C_FLAGS= -ffunction-sections -fdata-sections -fPIC -m64" "-DCMAKE_C_COMPILER=/usr/bin/cc" "-DCMAKE_CXX_FLAGS= -ffunction-sections -fdata-sections -fPIC -m64" "-DCMAKE_CXX_COMPILER=/usr/bin/c++" "-DCMAKE_ASM_FLAGS= -ffunction-sections -fdata-sections -fPIC -m64" "-DCMAKE_ASM_COMPILER=/usr/bin/cc" "-DCMAKE_BUILD_TYPE=RelWithDebInfo"

  --- stderr
  You need to run this command from the toplevel of the working tree.
  CMake Error: The source directory "/dl/sentry/relay/relay-crash/sentry-native" does not appear to contain CMakeLists.txt.
  Specify --help for usage, or press the help button on the CMake GUI.
  thread 'main' panicked at '
  command did not execute successfully, got: exit status: 1

  build script failed, must exit now', /root/.cargo/registry/src/github.com-1ecc6299db9ec823/cmake-0.1.46/src/lib.rs:974:5
  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
warning: build failed, waiting for other jobs to finish...
error: build failed

It would really be great if there would be a RHEL/Centos 7 compatible Version.

ahmedetefy commented 2 years ago

Hello @futureweb, Have you tried running the docker container on CENTOS7?

futureweb commented 2 years ago

Hello @futureweb, Have you tried running the docker container on CENTOS7?

Hi @ahmedetefy, in this case Docker unfortunately is not possible - we need it running on a High Performance SAAS Node (Virtuozzo Container) to be sure the Latency is as low as possible. (Same Host as SAAS CMS) Also to be sure we have no blocking of the Websites when the Sentry Server is down/not reachable (upate, network troubles, other problems, ...) as the PHP Implementation is unfortunately BLOCKING in case it's not reaching Sentry Server ... not async ... (I know .... rather hard to do in PHP)

I would guess that the relay with GLIBC_2.17 (Centos 7) should work at least as well as with GLIBC_2.18, right?

ahmedetefy commented 2 years ago

Hi @futureweb so we don't support centos 7 officially yet (we are considering adding centos 7 support) but one way you can unblock yourself is to compile it yourself

You can check out relay from git, run make release (after updating submodules) which will give you a relay binary in target/release/relay

futureweb commented 2 years ago

Hi @futureweb so we don't support centos 7 officially yet (we are considering adding centos 7 support) but one way you can unblock yourself is to compile it yourself

You can check out relay from git, run make release (after updating submodules) which will give you a relay binary in target/release/relay

already tried compiling myself - but unfortunately I'm running into lot's of Errors while compiling - once one is fixed the next is around the corner ... :-/

already fixed some dependencies Errors the last time, tried again now - next Errors ... :-/

# git clone https://github.com/getsentry/relay.git
# cd relay
# git submodule update --init --recursive

# cargo run --all-features -- config init
error: failed to run custom build command for `relay-crash v21.11.0 (/dl/sentry/relay/relay-crash)`

Caused by:
  process didn't exit successfully: `/dl/sentry/relay/target/debug/build/relay-crash-cd94ce90247f9139/build-script-build` (exit status: 101)
  --- stdout
  cargo:rustc-link-lib=dylib=stdc++
  cargo:rustc-link-lib=curl
  CMAKE_TOOLCHAIN_FILE_x86_64-unknown-linux-gnu = None
  CMAKE_TOOLCHAIN_FILE_x86_64_unknown_linux_gnu = None
  HOST_CMAKE_TOOLCHAIN_FILE = None
  CMAKE_TOOLCHAIN_FILE = None
  CMAKE_GENERATOR_x86_64-unknown-linux-gnu = None
  CMAKE_GENERATOR_x86_64_unknown_linux_gnu = None
  HOST_CMAKE_GENERATOR = None
  CMAKE_GENERATOR = None
  CMAKE_PREFIX_PATH_x86_64-unknown-linux-gnu = None
  CMAKE_PREFIX_PATH_x86_64_unknown_linux_gnu = None
  HOST_CMAKE_PREFIX_PATH = None
  CMAKE_PREFIX_PATH = None
  CMAKE_x86_64-unknown-linux-gnu = None
  CMAKE_x86_64_unknown_linux_gnu = None
  HOST_CMAKE = None
  CMAKE = None
  running: "cmake" "/dl/sentry/relay/relay-crash/sentry-native" "-DSENTRY_BACKEND=breakpad" "-DBUILD_SHARED_LIBS=OFF" "-DSENTRY_BUILD_TESTS=OFF" "-DSENTRY_BUILD_EXAMPLES=OFF" "-DCMAKE_INSTALL_PREFIX=/dl/sentry/relay/target/debug/build/relay-crash-a0f4db61ff33d05b/out" "-DCMAKE_C_FLAGS= -ffunction-sections -fdata-sections -fPIC -m64" "-DCMAKE_C_COMPILER=/usr/bin/cc" "-DCMAKE_CXX_FLAGS= -ffunction-sections -fdata-sections -fPIC -m64" "-DCMAKE_CXX_COMPILER=/usr/bin/c++" "-DCMAKE_ASM_FLAGS= -ffunction-sections -fdata-sections -fPIC -m64" "-DCMAKE_ASM_COMPILER=/usr/bin/cc" "-DCMAKE_BUILD_TYPE=RelWithDebInfo"
  -- The C compiler identification is GNU 4.8.5
  -- The CXX compiler identification is GNU 4.8.5
  -- The ASM compiler identification is GNU
  -- Found assembler: /usr/bin/cc
  -- Check for working C compiler: /usr/bin/cc
  -- Check for working C compiler: /usr/bin/cc - works
  -- Detecting C compiler ABI info
  -- Detecting C compiler ABI info - done
  -- Detecting C compile features
  -- Detecting C compile features - done
  -- Check for working CXX compiler: /usr/bin/c++
  -- Check for working CXX compiler: /usr/bin/c++ - works
  -- Detecting CXX compiler ABI info
  -- Detecting CXX compiler ABI info - done
  -- Detecting CXX compile features
  -- Detecting CXX compile features - done
  -- Looking for pthread.h
  -- Looking for pthread.h - found
  -- Performing Test CMAKE_HAVE_LIBC_PTHREAD
  -- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
  -- Looking for pthread_create in pthreads
  -- Looking for pthread_create in pthreads - not found
  -- Looking for pthread_create in pthread
  -- Looking for pthread_create in pthread - found
  -- Found Threads: TRUE  
  -- SENTRY_TRANSPORT=curl
  -- SENTRY_BACKEND=breakpad
  -- SENTRY_LIBRARY_TYPE=STATIC
  -- Looking for sys/types.h
  -- Looking for sys/types.h - found
  -- Looking for stdint.h
  -- Looking for stdint.h - found
  -- Looking for stddef.h
  -- Looking for stddef.h - found
  -- Check size of long
  -- Check size of long - done
  -- Found CURL: /usr/lib64/libcurl.so (found version "7.29.0")  
  -- Looking for getcontext
  -- Looking for getcontext - found
  -- Configuring done
  -- Generating done
  -- Build files have been written to: /dl/sentry/relay/target/debug/build/relay-crash-a0f4db61ff33d05b/out/build
  running: "cmake" "--build" "." "--target" "install" "--config" "RelWithDebInfo" "--parallel" "16"
  Scanning dependencies of target breakpad_client
  [  3%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/common/linux/elfutils.cc.o
  [  5%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/common/linux/file_id.cc.o
  [  6%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/common/convert_UTF.cc.o
  [  6%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/common/md5.cc.o
  [  8%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/common/linux/guid_creator.cc.o
  [ 10%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/common/linux/linux_libc_support.cc.o
  [ 12%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/common/linux/safe_readlink.cc.o
  [ 13%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/common/string_conversion.cc.o
  [ 15%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/client/linux/crash_generation/crash_generation_client.cc.o
  [ 17%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/client/minidump_file_writer.cc.o
  [ 18%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/common/linux/elf_core_dump.cc.o
  [ 20%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/common/linux/memory_mapped_file.cc.o
  [ 22%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/client/linux/crash_generation/crash_generation_server.cc.o
  [ 24%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/client/linux/dump_writer_common/thread_info.cc.o
  [ 25%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/client/linux/dump_writer_common/ucontext_reader.cc.o
  [ 27%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/client/linux/handler/exception_handler.cc.o
  [ 29%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/client/linux/log/log.cc.o
  [ 31%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/client/linux/microdump_writer/microdump_writer.cc.o
  [ 32%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/client/linux/handler/minidump_descriptor.cc.o
  [ 34%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/client/linux/minidump_writer/linux_dumper.cc.o
  [ 36%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc.o
  [ 37%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/client/linux/minidump_writer/linux_core_dumper.cc.o
  [ 39%] Building CXX object external/CMakeFiles/breakpad_client.dir/breakpad/src/client/linux/minidump_writer/minidump_writer.cc.o
  [ 41%] Linking CXX static library libbreakpad_client.a
  [ 41%] Built target breakpad_client
  Scanning dependencies of target sentry
  [ 43%] Building C object CMakeFiles/sentry.dir/src/sentry_backend.c.o
  [ 44%] Building C object CMakeFiles/sentry.dir/src/sentry_core.c.o
  [ 46%] Building C object CMakeFiles/sentry.dir/vendor/mpack.c.o
  [ 48%] Building C object CMakeFiles/sentry.dir/src/sentry_database.c.o
  [ 50%] Building C object CMakeFiles/sentry.dir/src/sentry_alloc.c.o
  [ 51%] Building C object CMakeFiles/sentry.dir/src/sentry_json.c.o
  [ 53%] Building C object CMakeFiles/sentry.dir/src/sentry_envelope.c.o
  [ 55%] Building C object CMakeFiles/sentry.dir/src/sentry_logger.c.o
  [ 56%] Building C object CMakeFiles/sentry.dir/src/sentry_options.c.o
  [ 60%] Building C object CMakeFiles/sentry.dir/src/sentry_os.c.o
  [ 60%] Building C object CMakeFiles/sentry.dir/src/sentry_ratelimiter.c.o
  [ 62%] Building C object CMakeFiles/sentry.dir/src/sentry_random.c.o
  [ 63%] Building C object CMakeFiles/sentry.dir/src/sentry_scope.c.o
  [ 65%] Building C object CMakeFiles/sentry.dir/src/sentry_session.c.o
  [ 67%] Building C object CMakeFiles/sentry.dir/src/sentry_slice.c.o
  [ 68%] Building C object CMakeFiles/sentry.dir/src/sentry_string.c.o
  [ 70%] Building C object CMakeFiles/sentry.dir/src/sentry_sync.c.o
  [ 72%] Building C object CMakeFiles/sentry.dir/src/sentry_transport.c.o
  [ 74%] Building C object CMakeFiles/sentry.dir/src/sentry_utils.c.o
  [ 75%] Building C object CMakeFiles/sentry.dir/src/sentry_uuid.c.o
  [ 77%] Building C object CMakeFiles/sentry.dir/src/path/sentry_path.c.o
  [ 79%] Building C object CMakeFiles/sentry.dir/src/sentry_value.c.o
  [ 81%] Building C object CMakeFiles/sentry.dir/src/transports/sentry_disk_transport.c.o
  [ 82%] Building C object CMakeFiles/sentry.dir/src/transports/sentry_function_transport.c.o
  [ 84%] Building C object CMakeFiles/sentry.dir/src/unwinder/sentry_unwinder.c.o
  [ 86%] Building C object CMakeFiles/sentry.dir/src/sentry_unix_pageallocator.c.o
  [ 87%] Building C object CMakeFiles/sentry.dir/src/symbolizer/sentry_symbolizer_unix.c.o
  [ 89%] Building C object CMakeFiles/sentry.dir/src/path/sentry_path_unix.c.o
  [ 91%] Building C object CMakeFiles/sentry.dir/src/modulefinder/sentry_modulefinder_linux.c.o
  [ 94%] Building C object CMakeFiles/sentry.dir/src/transports/sentry_transport_curl.c.o
  [ 94%] Building CXX object CMakeFiles/sentry.dir/src/backends/sentry_backend_breakpad.cpp.o
  [ 96%] Building C object CMakeFiles/sentry.dir/src/unwinder/sentry_unwinder_libbacktrace.c.o
  [ 98%] Building C object CMakeFiles/sentry.dir/vendor/stb_sprintf.c.o
  [100%] Linking CXX static library libsentry.a
  [100%] Built target sentry
  Install the project...
  -- Install configuration: "RelWithDebInfo"
  -- Installing: /dl/sentry/relay/target/debug/build/relay-crash-a0f4db61ff33d05b/out/lib64/libbreakpad_client.a
  -- Installing: /dl/sentry/relay/target/debug/build/relay-crash-a0f4db61ff33d05b/out/lib64/libsentry.a
  -- Installing: /dl/sentry/relay/target/debug/build/relay-crash-a0f4db61ff33d05b/out/include/sentry.h
  -- Installing: /dl/sentry/relay/target/debug/build/relay-crash-a0f4db61ff33d05b/out/lib64/cmake/sentry/sentry-targets.cmake
  -- Installing: /dl/sentry/relay/target/debug/build/relay-crash-a0f4db61ff33d05b/out/lib64/cmake/sentry/sentry-targets-relwithdebinfo.cmake
  -- Installing: /dl/sentry/relay/target/debug/build/relay-crash-a0f4db61ff33d05b/out/lib64/cmake/sentry/sentry-config.cmake
  -- Installing: /dl/sentry/relay/target/debug/build/relay-crash-a0f4db61ff33d05b/out/lib64/cmake/sentry/sentry-config-version.cmake
  cargo:root=/dl/sentry/relay/target/debug/build/relay-crash-a0f4db61ff33d05b/out
  cargo:rustc-link-search=native=/dl/sentry/relay/target/debug/build/relay-crash-a0f4db61ff33d05b/out/lib
  cargo:rustc-link-lib=static=breakpad_client
  cargo:rustc-link-lib=static=sentry

  --- stderr
  gmake: warning: -jN forced in submake: disabling jobserver mode.
  /dl/sentry/relay/relay-crash/sentry-native/src/path/sentry_path_unix.c: In function ‘sentry__path_remove’:
  /dl/sentry/relay/relay-crash/sentry-native/src/path/sentry_path_unix.c:276:15: warning: the comparison will always evaluate as ‘true’ for the address of ‘status’ will never be NULL [-Waddress]
           if (Y != 0) {                                                          \
                 ^
  /dl/sentry/relay/relay-crash/sentry-native/src/path/sentry_path_unix.c:286:9: note: in expansion of macro ‘EINTR_RETRY’
           EINTR_RETRY(unlink(path->path), &status);
           ^
  /dl/sentry/relay/relay-crash/sentry-native/src/path/sentry_path_unix.c:276:15: warning: the comparison will always evaluate as ‘true’ for the address of ‘status’ will never be NULL [-Waddress]
           if (Y != 0) {                                                          \
                 ^
  /dl/sentry/relay/relay-crash/sentry-native/src/path/sentry_path_unix.c:291:9: note: in expansion of macro ‘EINTR_RETRY’
           EINTR_RETRY(rmdir(path->path), &status);
           ^
  In file included from /dl/sentry/relay/relay-crash/sentry-native/vendor/stb_sprintf.c:2:0:
  /dl/sentry/relay/relay-crash/sentry-native/vendor/stb_sprintf.h: In function ‘stbsp_vsprintfcb’:
  /dl/sentry/relay/relay-crash/sentry-native/vendor/stb_sprintf.h:1077:19: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
                     *(stbsp__uint16 *)s = *(stbsp__uint16 *)&stbsp__digitpair.pair[(n % 100) * 2];
                     ^
  /dl/sentry/relay/relay-crash/sentry-native/vendor/stb_sprintf.h: In function ‘stbsp__real_to_str’:
  /dl/sentry/relay/relay-crash/sentry-native/vendor/stb_sprintf.h:1797:10: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
            *(stbsp__uint16 *)out = *(stbsp__uint16 *)&stbsp__digitpair.pair[(n % 100) * 2];
            ^
  In file included from /dl/sentry/relay/relay-crash/sentry-native/external/breakpad/src/common/memory_allocator.h:50:0,
                   from /dl/sentry/relay/relay-crash/sentry-native/external/breakpad/src/client/linux/dump_writer_common/thread_info.h:37,
                   from /dl/sentry/relay/relay-crash/sentry-native/external/breakpad/src/client/linux/minidump_writer/linux_dumper.h:54,
                   from /dl/sentry/relay/relay-crash/sentry-native/external/breakpad/src/client/linux/minidump_writer/minidump_writer.h:42,
                   from /dl/sentry/relay/relay-crash/sentry-native/external/breakpad/src/client/linux/handler/exception_handler.h:42,
                   from /dl/sentry/relay/relay-crash/sentry-native/src/backends/sentry_backend_breakpad.cpp:32:
  /dl/sentry/relay/relay-crash/sentry-native/external/third_party/lss/linux_syscall_support.h:3384:1: warning: ISO C99 requires rest arguments to be used [enabled by default]
       LSS_INLINE _syscall0(pid_t,   fork)
   ^
  /dl/sentry/relay/relay-crash/sentry-native/external/third_party/lss/linux_syscall_support.h:3384:1: warning: ISO C99 requires rest arguments to be used [enabled by default]
  /dl/sentry/relay/relay-crash/sentry-native/external/third_party/lss/linux_syscall_support.h:3407:1: warning: ISO C99 requires rest arguments to be used [enabled by default]
     LSS_INLINE _syscall0(gid_t,   getegid)
   ^
  /dl/sentry/relay/relay-crash/sentry-native/external/third_party/lss/linux_syscall_support.h:3407:1: warning: ISO C99 requires rest arguments to be used [enabled by default]
  /dl/sentry/relay/relay-crash/sentry-native/external/third_party/lss/linux_syscall_support.h:3408:1: warning: ISO C99 requires rest arguments to be used [enabled by default]
     LSS_INLINE _syscall0(uid_t,   geteuid)
   ^
  /dl/sentry/relay/relay-crash/sentry-native/external/third_party/lss/linux_syscall_support.h:3408:1: warning: ISO C99 requires rest arguments to be used [enabled by default]
  /dl/sentry/relay/relay-crash/sentry-native/external/third_party/lss/linux_syscall_support.h:3410:1: warning: ISO C99 requires rest arguments to be used [enabled by default]
       LSS_INLINE _syscall0(pid_t,   getpgrp)
   ^
  /dl/sentry/relay/relay-crash/sentry-native/external/third_party/lss/linux_syscall_support.h:3410:1: warning: ISO C99 requires rest arguments to be used [enabled by default]
  /dl/sentry/relay/relay-crash/sentry-native/external/third_party/lss/linux_syscall_support.h:3412:1: warning: ISO C99 requires rest arguments to be used [enabled by default]
     LSS_INLINE _syscall0(pid_t,   getpid)
   ^
  /dl/sentry/relay/relay-crash/sentry-native/external/third_party/lss/linux_syscall_support.h:3412:1: warning: ISO C99 requires rest arguments to be used [enabled by default]
  /dl/sentry/relay/relay-crash/sentry-native/external/third_party/lss/linux_syscall_support.h:3413:1: warning: ISO C99 requires rest arguments to be used [enabled by default]
     LSS_INLINE _syscall0(pid_t,   getppid)
   ^
  /dl/sentry/relay/relay-crash/sentry-native/external/third_party/lss/linux_syscall_support.h:3413:1: warning: ISO C99 requires rest arguments to be used [enabled by default]
  /dl/sentry/relay/relay-crash/sentry-native/external/third_party/lss/linux_syscall_support.h:3425:1: warning: ISO C99 requires rest arguments to be used [enabled by default]
     LSS_INLINE _syscall0(pid_t,   _gettid)
   ^
  /dl/sentry/relay/relay-crash/sentry-native/external/third_party/lss/linux_syscall_support.h:3425:1: warning: ISO C99 requires rest arguments to be used [enabled by default]
  /dl/sentry/relay/relay-crash/sentry-native/external/third_party/lss/linux_syscall_support.h:3524:1: warning: ISO C99 requires rest arguments to be used [enabled by default]
     LSS_INLINE _syscall0(int,     sched_yield)
   ^
  /dl/sentry/relay/relay-crash/sentry-native/external/third_party/lss/linux_syscall_support.h:3524:1: warning: ISO C99 requires rest arguments to be used [enabled by default]
  /dl/sentry/relay/relay-crash/sentry-native/external/third_party/lss/linux_syscall_support.h:3540:1: warning: ISO C99 requires rest arguments to be used [enabled by default]
     LSS_INLINE _syscall0(pid_t,    setsid)
   ^
  /dl/sentry/relay/relay-crash/sentry-native/external/third_party/lss/linux_syscall_support.h:3540:1: warning: ISO C99 requires rest arguments to be used [enabled by default]
  /dl/sentry/relay/relay-crash/sentry-native/src/path/sentry_path_unix.c: At top level:
  cc1: warning: unrecognized command line option "-Wno-gnu-include-next" [enabled by default]
  cc1plus: warning: unrecognized command line option "-Wno-gnu-include-next" [enabled by default]
  /dl/sentry/relay/relay-crash/sentry-native/vendor/stb_sprintf.c: At top level:
  cc1: warning: unrecognized command line option "-Wno-gnu-include-next" [enabled by default]
  thread 'main' panicked at 'Unable to find libclang: "the `libclang` shared library at /usr/lib64/clang-private/libclang.so.7 could not be opened: libclangAST.so.7: cannot open shared object file: No such file or directory"', /root/.cargo/registry/src/github.com-1ecc6299db9ec823/bindgen-0.59.1/src/lib.rs:2117:31
  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
warning: build failed, waiting for other jobs to finish...
error: build failed
# make release
error: no such subcommand: `+stable`
make: *** [release] Error 101

Would be great if Centos 7 / RHEL 7 would be added to your supported OS - as it's still very wide spread expecially in the Web-Hosting Sector ... ;-)

futureweb commented 2 years ago

This Error fixed with

rpm -qa | grep "llvm-private"
rpm -e --nodeps llvm-private-7.0.1-1.el7.x86_64
yum install -y clang llvm

Next Error:

  /dl/sentry/relay/relay-crash/sentry-native/src/path/sentry_path_unix.c: At top level:
  cc1: warning: unrecognized command line option "-Wno-gnu-include-next" [enabled by default]
  cc1plus: warning: unrecognized command line option "-Wno-gnu-include-next" [enabled by default]
  /dl/sentry/relay/relay-crash/sentry-native/vendor/stb_sprintf.c: At top level:
  cc1: warning: unrecognized command line option "-Wno-gnu-include-next" [enabled by default]
  thread 'main' panicked at '`libclang` function not loaded: `clang_Cursor_isMacroFunctionLike`. This crate requires that `libclang` 3.9 or later be installed on your system. For more information on how to accomplish this, see here: https://rust-lang.github.io/rust-bindgen/requirements.html#installing-clang-39', /root/.cargo/registry/src/github.com-1ecc6299db9ec823/clang-sys-1.3.0/src/lib.rs:1704:1
  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
warning: build failed, waiting for other jobs to finish...
error: build failed
futureweb commented 2 years ago

again fixed with:

$ sudo yum install centos-release-scl
$ sudo yum install llvm-toolset-7
$ scl enable llvm-toolset-7 bash

Next Error:

 Compiling relay-log v21.11.0 (/dl/sentry/relay/relay-log)
error: could not find native static library `breakpad_client`, perhaps an -L flag is missing?

error: could not compile `relay-crash` due to previous error
warning: build failed, waiting for other jobs to finish...
error: build failed

Feeling a bit like Don Quijote ... 😅

untitaker commented 2 years ago

do you need this for relay on your own self-hosted install, or relay in front of sentry.io? you can use cargo build --release, i.e. build without breakpad for the latter

futureweb commented 2 years ago

do you need this for relay on your own self-hosted install, or relay in front of sentry.io? you can use cargo build --release, i.e. build without breakpad for the latter

in front of self hosted sentry instance

mitsuhiko commented 2 years ago

The issue you're running in is definitely --all-features. This turns on functionality you do not need.

futureweb commented 2 years ago

The issue you're running in is definitely --all-features. This turns on functionality you do not need.

I did follow the Building and Running Section in the Relay Readme --> https://github.com/getsentry/relay#building-and-running

What would be the minimal Feature Set for a running Relay Instance for Self Hostes Sentry?

untitaker commented 2 years ago

can you try cargo build --features processing instead?

chadwhitacre commented 2 years ago

Applying Needs More Info based on conversation. Lmk if not appropriate.

futureweb commented 2 years ago

can you try cargo build --features processing instead?

with this Flag it's working.

I would suggest adapting the instructions a little. Or to give more information which flags are at least necessary to compile a functioning relay server. https://github.com/getsentry/relay#building-and-running was unfortunately not particularly informative here.

Would also include the corresponding GIT part in the Manual - with the first 2 compile attempts I overlooked, for example, that there are submodules which you first have to fetch via GIT: git submodule update --init --recursive

Thank you! :-)

jan-auer commented 2 years ago

A compatible version will be released with 22.6.0