summaryrefslogtreecommitdiff
path: root/libbridge
diff options
context:
space:
mode:
Diffstat (limited to 'libbridge')
-rw-r--r--libbridge/CMakeLists.txt5
l---------libbridge/src/main/cpp/wallet2_api.h1
-rw-r--r--libbridge/src/main/cpp/wallet2_api_c.cpp10
3 files changed, 14 insertions, 2 deletions
diff --git a/libbridge/CMakeLists.txt b/libbridge/CMakeLists.txt
index d2f3cfa..620577f 100644
--- a/libbridge/CMakeLists.txt
+++ b/libbridge/CMakeLists.txt
@@ -277,6 +277,11 @@ if(${HOST_ABI} STREQUAL "x86_64-w64-mingw32" OR ${HOST_ABI} STREQUAL "i686-w64-m
set(EXTRA_LIBS_WINDOWS wsock32 ws2_32 iconv iphlpapi crypt32 hidapi)
endif()
+if (${MONERO_FLAVOR} STREQUAL "monero")
+ target_compile_definitions(wallet2_api_c PRIVATE FLAVOR_MONERO)
+elseif(${MONERO_FLAVOR} STREQUAL "wownero")
+ target_compile_definitions(wallet2_api_c PRIVATE FLAVOR_WOWNERO)
+endif()
target_link_libraries( wallet2_api_c
diff --git a/libbridge/src/main/cpp/wallet2_api.h b/libbridge/src/main/cpp/wallet2_api.h
deleted file mode 120000
index 6d9c48d..0000000
--- a/libbridge/src/main/cpp/wallet2_api.h
+++ /dev/null
@@ -1 +0,0 @@
-../../../../monero/src/wallet/api/wallet2_api.h \ No newline at end of file
diff --git a/libbridge/src/main/cpp/wallet2_api_c.cpp b/libbridge/src/main/cpp/wallet2_api_c.cpp
index d5da3e1..9208765 100644
--- a/libbridge/src/main/cpp/wallet2_api_c.cpp
+++ b/libbridge/src/main/cpp/wallet2_api_c.cpp
@@ -1,11 +1,19 @@
#include <inttypes.h>
#include "wallet2_api_c.h"
-#include "wallet2_api.h"
#include <unistd.h>
#include "helpers.hpp"
#include <cstring>
#include <thread>
+#ifdef FLAVOR_MONERO
+#include "../../../../monero/src/wallet/api/wallet2_api.h"
+#endif
+
+#ifdef FLAVOR_WOWNERO
+#include "../../../../wownero/src/wallet/api/wallet2_api.h"
+#endif
+
+
#ifdef __cplusplus
extern "C"
{