File openucx-extern-c.patch of Package openucx
github.com/openucx/ucx/issues/10663
github.com/openucx/ucx/pull/10664
github.com/openucx/ucx/commit/2e6f69d
adapted to opensuse's source tree:
- change to -p0 as used by %autopatch in opensuse's openucx.spec
From 2e6f69db88da2c38c89c688a932817b6b4912920 Mon Sep 17 00:00:00 2001
From: Thomas Vegas <tvegas@nvidia.com>
Date: Tue, 29 Apr 2025 05:22:28 +0000
Subject: [PATCH] TOOLS/PERF: Include omp.h outside of extern C declarations
--- src/tools/perf/lib/libperf_int.h
+++ src/tools/perf/lib/libperf_int.h
@@ -11,6 +11,12 @@
#include <tools/perf/api/libperf.h>
+
+#if _OPENMP
+#include <omp.h>
+#endif
+
+
BEGIN_C_DECLS
/** @file libperf_int.h */
@@ -20,11 +26,6 @@ BEGIN_C_DECLS
#include <ucs/sys/math.h>
-#if _OPENMP
-#include <omp.h>
-#endif
-
-
#define TIMING_QUEUE_SIZE 2048
#define UCT_PERF_TEST_AM_ID 5
#define ADDR_BUF_SIZE 4096