You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While upgrading the Ruby profiler to use libdatadog 0.8.0, I ran into the following issue:
In file included from /usr/local/bundle/gems/libdatadog-0.8.0.1.0-x86_64-linux/vendor/libdatadog-0.8.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/lib/pkgconfig/../../include/datadog/profiling.h:11:0,
from ../../../../ext/ddtrace_profiling_native_extension/collectors_stack.h:3,
from ../../../../ext/ddtrace_profiling_native_extension/collectors_cpu_and_wall_time.c:4:
/usr/local/bundle/gems/libdatadog-0.8.0.1.0-x86_64-linux/vendor/libdatadog-0.8.0/x86_64-linux/libdatadog-x86_64-unknown-linux-gnu/lib/pkgconfig/../../include/datadog/common.h:24:52: error: missing binary operator before token "("
#elif (defined(__has_attribute) && (__has_attribute(warn_unused_result))) || \
^
Makefile:237: recipe for target 'collectors_cpu_and_wall_time.o' failed
make: *** [collectors_cpu_and_wall_time.o] Error 1
Describe the bug
While upgrading the Ruby profiler to use libdatadog 0.8.0, I ran into the following issue:
Looking through the gcc docs this issue seems to be documented in https://gcc.gnu.org/onlinedocs/cpp/_005f_005fhas_005fattribute.html and we seem to be using
defined(__has_atribute)
incorrectly.This issue seems to be introduced in #24
To Reproduce
Steps to reproduce the behavior:
Use the
ivoanjo/docker-library:ddtrace_rb_2_2_10
docker image to get a suitable old version of gcc:and try to compile anything that includes that header.
Expected behavior
Compiling libdatadog on this gcc version should ideally still be possible.
Errors or warnings received
(See above)
How does
libdatadog
help you?There's quite a lot of code on the Ruby profiler that I'll be able to delete soon ;)
The text was updated successfully, but these errors were encountered: