Mesa (master): gallium/gallivm: enable linking lp_bld_printf function with C++ code

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Tue Jan 21 11:18:59 UTC 2020


Module: Mesa
Branch: master
Commit: a24b3b228a0a9c0bab0de2e024798c85479ef9b4
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=a24b3b228a0a9c0bab0de2e024798c85479ef9b4

Author: Jan Zielinski <jan.zielinski at intel.com>
Date:   Mon Jan 20 13:57:36 2020 +0100

gallium/gallivm: enable linking lp_bld_printf function with C++ code

To enable linking functions declared in lp_bld_printf.h file with C++,
we need to add appropriate macros to the header.

Reviewed-by: Krzysztof Raszkowski <krzysztof.raszkowski at intel.com>
Tested-by: Marge Bot <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3470>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3470>

---

 src/gallium/auxiliary/gallivm/lp_bld_printf.h | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/src/gallium/auxiliary/gallivm/lp_bld_printf.h b/src/gallium/auxiliary/gallivm/lp_bld_printf.h
index ede93cc834e..298b4033f08 100644
--- a/src/gallium/auxiliary/gallivm/lp_bld_printf.h
+++ b/src/gallium/auxiliary/gallivm/lp_bld_printf.h
@@ -28,6 +28,9 @@
 #ifndef LP_BLD_PRINTF_H
 #define LP_BLD_PRINTF_H
 
+#ifdef __cplusplus
+extern "C" {
+#endif
 
 #include "pipe/p_compiler.h"
 #include "lp_bld.h"
@@ -43,5 +46,9 @@ lp_build_print_value(struct gallivm_state *gallivm,
                      const char *msg,
                      LLVMValueRef value);
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif
 



More information about the mesa-commit mailing list