Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3367643
D6722.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
2 KB
Referenced Files
None
Subscribers
None
D6722.diff
View Options
diff --git a/native/android/app/CMakeLists.txt b/native/android/app/CMakeLists.txt
--- a/native/android/app/CMakeLists.txt
+++ b/native/android/app/CMakeLists.txt
@@ -19,6 +19,7 @@
# Gradle automatically packages shared libraries with your APK.
set(PACKAGE_NAME "comm_jni_module")
+find_library(log-lib log)
find_package(fbjni REQUIRED CONFIG)
set(BUILD_TESTING OFF)
@@ -103,7 +104,19 @@
file(GLOB SQLCIPHER
"${_node_modules_dir}/@commapp/sqlcipher-amalgamation/src/*.c"
)
-file(GLOB ANDROID_NATIVE_CODE "./src/cpp/*.cpp")
+
+# Add files which aren't a part of comm-tools
+list(APPEND ANDROID_NATIVE_CODE
+ "./src/cpp/CommSecureStore.cpp"
+ "./src/cpp/DatabaseInitializerJNIHelper.cpp"
+ "./src/cpp/GlobalDBSingleton.cpp"
+ "./src/cpp/Logger.cpp"
+ "./src/cpp/MessageOperationsUtilitiesJNIHelper.cpp"
+ "./src/cpp/PlatformSpecificTools.cpp"
+ "./src/cpp/TerminateApp.cpp"
+ "./src/cpp/ThreadOperationsJNIHelper.cpp"
+ "./src/cpp/jsiInstaller.cpp"
+)
set(GENERATED_NATIVE_CODE "../../cpp/CommonCpp/_generated/commJSI-generated.cpp")
file(GLOB CRYPTO_NATIVE_CODE "../../cpp/CommonCpp/CryptoTools/*.cpp")
@@ -111,7 +124,6 @@
file(GLOB DB_ENTITIES_NATIVE_CODE "../../cpp/CommonCpp/DatabaseManagers/entities/*.cpp")
file(GLOB_RECURSE MODULE_NATIVE_CODE "../../cpp/CommonCpp/NativeModules/**/*.cpp")
file(GLOB MODULE_ROOT_NATIVE_CODE "../../cpp/CommonCpp/NativeModules/*.cpp")
-file(GLOB TOOLS_NATIVE_CODE "../../cpp/CommonCpp/Tools/*.cpp")
file(GLOB NOTIFICATIONS_NATIVE_CODE "../../cpp/CommonCpp/Notifications/**/*.cpp")
add_library(
@@ -178,7 +190,6 @@
../../cpp/CommonCpp/NativeModules/PersistentStorageUtilities/MessageOperationsUtilities
../../cpp/CommonCpp/NativeModules/PersistentStorageUtilities/MessageOperationsUtilities/MessageSpecs
../../cpp/CommonCpp/DatabaseManagers
- ../../cpp/CommonCpp/Tools
../../cpp/CommonCpp/Notifications
../../cpp/CommonCpp/Notifications/BackgroundDataStorage
@@ -194,8 +205,6 @@
-DSQLCIPHER_CRYPTO_OPENSSL
)
-find_library(log-lib log)
-
target_link_libraries(
${PACKAGE_NAME}
fbjni::fbjni
@@ -207,6 +216,7 @@
openssl-crypto
openssl-ssl
comm::native_rust_library
+ comm-tools
)
# add a dummy library which is required by CallInvokerHolderImpl.java
diff --git a/native/cpp/CommonCpp/Tools/CMakeLists.txt b/native/cpp/CommonCpp/Tools/CMakeLists.txt
--- a/native/cpp/CommonCpp/Tools/CMakeLists.txt
+++ b/native/cpp/CommonCpp/Tools/CMakeLists.txt
@@ -4,9 +4,6 @@
include(GNUInstallDirs)
set(TOOLS_HDRS
- "CommSecureStore.h"
- "Logger.h"
- "PlatformSpecificTools.h"
"WorkerThread.h"
)
@@ -15,6 +12,7 @@
)
add_library(comm-tools
+ STATIC
${TOOLS_HDRS}
${TOOLS_SRCS}
)
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Nov 26, 3:23 PM (21 h, 33 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2585343
Default Alt Text
D6722.diff (2 KB)
Attached To
Mode
D6722: [Android] Reference Tools by CMake project
Attached
Detach File
Event Timeline
Log In to Comment