summary refs log tree commit diff stats
path: root/scripts/tracetool/backend/dtrace.py
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/tracetool/backend/dtrace.py')
-rw-r--r--scripts/tracetool/backend/dtrace.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/scripts/tracetool/backend/dtrace.py b/scripts/tracetool/backend/dtrace.py
index 5711892ba0..b7fe4c1b50 100644
--- a/scripts/tracetool/backend/dtrace.py
+++ b/scripts/tracetool/backend/dtrace.py
@@ -40,6 +40,12 @@ def generate_h_begin(events, group):
     else:
         header = "trace-dtrace.h"
 
+    # Workaround for ust backend, which also includes <sys/sdt.h> and may
+    # require SDT_USE_VARIADIC to be defined. If dtrace includes <sys/sdt.h>
+    # first without defining SDT_USE_VARIADIC then ust breaks because the
+    # STAP_PROBEV() macro is not defined.
+    out('#define SDT_USE_VARIADIC 1')
+
     out('#include "%s"' % header,
         '')