This repository has been archived on 2023-08-20. You can view files and clone it, but cannot push or open issues or pull requests.
yap-6.3/packages/swig/android/CMakeLists.txt
Vitor Santos Costa 06485f071a iandroid
2017-11-21 15:44:43 +00:00

56 lines
1.4 KiB
CMake

include (UseSWIG)
INCLUDE_DIRECTORIES(
../../../H
../../../H/generated
../../../OPTYap
../../../include
../../../CXX
.
..
${CMAKE_CURRENT_BINARY_DIR}
${CMAKE_CURRENT_SOURCE_DIR}
)
set_property(GLOBAL
APPEND PROPERTY
COMPILE_DEFINITIONS
-Dmmap=mmap64)
# This is a CMake file for SWIG and Android
FILE( MAKE_DIRECTORY ${YAP_APP_DIR}/src/generated/java/pt/up/yap/lib )
FILE( MAKE_DIRECTORY ${YAP_APP_DIR}/src/generated/assets)
set(CMAKE_SWIG_OUTDIR ${YAP_APP_DIR}/src/generated/java )
set(SWIG_OUTFILE_OUTDIR ${CMAKE_CURRENT_SOURCE_DIR} )
set_property(SOURCE ../yap.i PROPERTY CPLUSPLUS ON)
set_property(SOURCE streamer.i PROPERTY CPLUSPLUS ON)
set( SWIG_MODULE_NAME pt.up.yap.lib )
set (SWIG_SOURCES ../yap.i streamer.i streamer.cpp)
SWIG_ADD_LIBRARY(YAPJava
SHARED # [TYPE <SHARED|MODULE|STATIC|USE_BUILD_SHARED_LIBS>]
LANGUAGE java
SOURCES ../yap.i
)
SWIG_ADD_LIBRARY(YAPStreamer
SHARED # [TYPE <SHARED|MODULE|STATIC|USE_BUILD_SHARED_LIBS>]
LANGUAGE java
SOURCES streamer.i streamer.cpp streamer.h
)
target_link_libraries(YAPJava YAP++ android log)
target_link_libraries(YAPStreamer YAP++ android log)
install(TARGETS YAPJava YAPStreamer
RUNTIME DESTINATION ${dlls}
LIBRARY DESTINATION c{libdir}
ARCHIVE DESTINATION ${libdir}
)