Fix the static library build

Building with -DLIBRARY_TYPE=STATIC fails with 3 undefined symbols.
Add weak symbols to satisfy the linker (mirror what is done for the
other Loader symbols).

Change-Id: I8a2878def21d5f500b0764ceacb4e5255e1111c5


[ROCm/roctracer commit: b352eedac6]
This commit is contained in:
Laurent Morichetti
2022-04-22 19:00:39 -07:00
committed by Laurent Morichetti
parent 9dd5a58e3e
commit 4a50f3b88f
+5
View File
@@ -151,6 +151,11 @@ __attribute__((weak)) const char* hipKernelNameRefByPtr(const void* hostFunction
__attribute__((weak)) int hipGetStreamDeviceId(hipStream_t stream) { return 0; }
__attribute__((weak)) const char* hipApiName(uint32_t id) { return NULL; }
__attribute__((weak)) void hipInitActivityCallback(void* id_callback, void* op_callback,
void* arg) {}
__attribute__((weak)) bool hipEnableActivityCallback(unsigned op, bool enable) { return false; }
__attribute__((weak)) const char* hipGetCmdName(unsigned op) { return NULL; }
class HipLoaderStatic {
public:
typedef std::mutex mutex_t;