[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Minios-devel] [UNIKRAFT/LIBONNX PATCH 3/3] Add patches



In this patch, we add a guard to the ONNX_API
define as to avoid redefinition warnings.

Signed-off-by: Vlad-Andrei Badoiu <vlad_andrei.badoiu@xxxxxx>
---
 patches/0001-Add-guard-to-ONNX_API.patch | 27 ++++++++++++++++++++++++
 1 file changed, 27 insertions(+)
 create mode 100644 patches/0001-Add-guard-to-ONNX_API.patch

diff --git a/patches/0001-Add-guard-to-ONNX_API.patch 
b/patches/0001-Add-guard-to-ONNX_API.patch
new file mode 100644
index 0000000..fffc217
--- /dev/null
+++ b/patches/0001-Add-guard-to-ONNX_API.patch
@@ -0,0 +1,27 @@
+From 8044f5b83b43cd7a3fae796f2991f48860023e8e Mon Sep 17 00:00:00 2001
+From: Vlad-Andrei Badoiu <vlad_andrei.badoiu@xxxxxx>
+Date: Mon, 6 Apr 2020 20:16:23 +0300
+Subject: [PATCH 1/1] Add guard to ONNX_API
+
+Signed-off-by: Vlad-Andrei Badoiu <vlad_andrei.badoiu@xxxxxx>
+---
+ onnx/onnx_pb.h | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/onnx/onnx_pb.h b/onnx/onnx_pb.h
+index 7dc68de..df22f73 100644
+--- a/onnx/onnx_pb.h
++++ b/onnx/onnx_pb.h
+@@ -41,7 +41,9 @@
+ // This solution is similar to
+ // https://github.com/pytorch/pytorch/blob/master/caffe2/core/common.h
+ #if defined(ONNX_BUILD_SHARED_LIBS) || defined(ONNX_BUILD_MAIN_LIB)
++#ifndef ONNX_API
+ #define ONNX_API ONNX_EXPORT
++#endif
+ #else
+ #define ONNX_API ONNX_IMPORT
+ #endif
+-- 
+2.20.1
+
-- 
2.20.1


_______________________________________________
Minios-devel mailing list
Minios-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/minios-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.