summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXusheng <xusheng@vector35.com>2022-05-06 16:42:38 +0800
committerXusheng <xusheng@vector35.com>2022-05-06 16:42:38 +0800
commita6978c399bc6121cab3cd239afb6948b3f04ee7a (patch)
tree88c49c76b6115372a8ec65c5efb6540ce0579ed6
parentbfeba3302e995fdba373603533fce54bf788adff (diff)
Do not export BN C API functions in demo on Windows
-rw-r--r--binaryninjacore.h11
1 files changed, 8 insertions, 3 deletions
diff --git a/binaryninjacore.h b/binaryninjacore.h
index 39b44921..3eaeb628 100644
--- a/binaryninjacore.h
+++ b/binaryninjacore.h
@@ -52,12 +52,17 @@
#define BINARYNINJAPLUGIN __attribute__((visibility("default")))
#else
#ifdef _MSC_VER
- #ifdef BINARYNINJACORE_LIBRARY
- #define BINARYNINJACOREAPI __declspec(dllexport)
+ #ifndef DEMO_VERSION
+ #ifdef BINARYNINJACORE_LIBRARY
+ #define BINARYNINJACOREAPI __declspec(dllexport)
+ #else
+ #define BINARYNINJACOREAPI
+ #endif
+ #define BINARYNINJAPLUGIN __declspec(dllexport)
#else
#define BINARYNINJACOREAPI
+ #define BINARYNINJAPLUGIN
#endif
- #define BINARYNINJAPLUGIN __declspec(dllexport)
#else
#define BINARYNINJACOREAPI
#endif