Added some missing build files.
This commit is contained in:
parent
ada1c7f6ae
commit
b6e6dce9f0
8
lib/bin/build_libjson-c-android
Executable file
8
lib/bin/build_libjson-c-android
Executable file
@ -0,0 +1,8 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
source "${BASH_SOURCE%/*}/build_lib"
|
||||||
|
|
||||||
|
autoreconf() {
|
||||||
|
command autoreconf -Iautoconf-archive/m4 "$@"
|
||||||
|
}
|
||||||
|
|
||||||
|
build libjson-c android
|
23
platform-android/CMakeLists.txt
Normal file
23
platform-android/CMakeLists.txt
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
project( mpw-core C )
|
||||||
|
cmake_minimum_required( VERSION 3.0.0 )
|
||||||
|
|
||||||
|
add_library( mpw SHARED
|
||||||
|
"${PROJECT_SOURCE_DIR}/../platform-independent/c/core/src/base64.c"
|
||||||
|
"${PROJECT_SOURCE_DIR}/../platform-independent/c/core/src/aes.c"
|
||||||
|
"${PROJECT_SOURCE_DIR}/../platform-independent/c/core/src/mpw-algorithm.c"
|
||||||
|
"${PROJECT_SOURCE_DIR}/../platform-independent/c/core/src/mpw-types.c"
|
||||||
|
"${PROJECT_SOURCE_DIR}/../platform-independent/c/core/src/mpw-util.c"
|
||||||
|
"${PROJECT_SOURCE_DIR}/../platform-independent/c/core/src/mpw-marshal-util.c"
|
||||||
|
"${PROJECT_SOURCE_DIR}/../platform-independent/c/core/src/mpw-marshal.c" )
|
||||||
|
|
||||||
|
add_library( sodium SHARED IMPORTED )
|
||||||
|
set_target_properties( sodium PROPERTIES IMPORTED_LOCATION "${PROJECT_SOURCE_DIR}/../lib/libsodium/build-android~/out/lib/${ANDROID_ABI}/libsodium.so" )
|
||||||
|
target_include_directories( mpw PRIVATE "${PROJECT_SOURCE_DIR}/../lib/libsodium/build-android~/out" )
|
||||||
|
target_compile_definitions( mpw PRIVATE -DMPW_SODIUM=1 )
|
||||||
|
target_link_libraries( mpw PRIVATE sodium )
|
||||||
|
|
||||||
|
add_library( json-c SHARED IMPORTED )
|
||||||
|
set_target_properties( json-c PROPERTIES IMPORTED_LOCATION "${PROJECT_SOURCE_DIR}/../lib/libjson-c/build-android~/out/lib/${ANDROID_ABI}/libjson-c.so" )
|
||||||
|
target_include_directories( mpw PRIVATE "${PROJECT_SOURCE_DIR}/../lib/libjson-c/build-android~/out" )
|
||||||
|
target_compile_definitions( mpw PRIVATE -DMPW_JSON=1 )
|
||||||
|
target_link_libraries( mpw PRIVATE json-c )
|
@ -8,7 +8,7 @@
|
|||||||
|
|
||||||
JNIEXPORT jint JNI_OnLoad(JavaVM* vm, void* reserved) {
|
JNIEXPORT jint JNI_OnLoad(JavaVM* vm, void* reserved) {
|
||||||
JNIEnv* env;
|
JNIEnv* env;
|
||||||
if (vm->GetEnv(&env, JNI_VERSION_1_6) != JNI_OK)
|
if ((*vm)->GetEnv( vm, (void **)&env, JNI_VERSION_1_6 ) != JNI_OK)
|
||||||
return -1;
|
return -1;
|
||||||
|
|
||||||
return JNI_VERSION_1_6;
|
return JNI_VERSION_1_6;
|
||||||
|
@ -16,7 +16,7 @@ dependencies {
|
|||||||
api group: 'com.google.code.findbugs', name: 'jsr305', version: '3.0.2'
|
api group: 'com.google.code.findbugs', name: 'jsr305', version: '3.0.2'
|
||||||
api group: 'com.google.code.findbugs', name: 'findbugs-annotations', version: '3.0.1'
|
api group: 'com.google.code.findbugs', name: 'findbugs-annotations', version: '3.0.1'
|
||||||
|
|
||||||
//lib project( path: ':masterpassword-core', configuration: 'default' )
|
lib project( path: ':masterpassword-core', configuration: 'default' )
|
||||||
}
|
}
|
||||||
|
|
||||||
processResources {
|
processResources {
|
||||||
|
Loading…
Reference in New Issue
Block a user