Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update embedded jsoncpp from unk version to 0.10.6 + move libs to lib/ instead of src/ #5473

Merged
merged 9 commits into from
Apr 2, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,7 @@ endif()
# Subdirectories
# Be sure to add all relevant definitions above this

add_subdirectory(lib)
add_subdirectory(src)


Expand Down
66 changes: 33 additions & 33 deletions build/android/jni/Android.mk
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,8 @@ endif
LOCAL_C_INCLUDES := \
jni/src \
jni/src/script \
jni/src/lua/src \
jni/src/jsoncpp \
jni/lib/lua/src \
jni/lib/jsoncpp \
jni/src/cguittfont \
deps/irrlicht/include \
deps/libiconv/include \
Expand Down Expand Up @@ -334,36 +334,36 @@ LOCAL_SRC_FILES += jni/src/cguittfont/xCGUITTFont.cpp

# Lua
LOCAL_SRC_FILES += \
jni/src/lua/src/lapi.c \
jni/src/lua/src/lauxlib.c \
jni/src/lua/src/lbaselib.c \
jni/src/lua/src/lcode.c \
jni/src/lua/src/ldblib.c \
jni/src/lua/src/ldebug.c \
jni/src/lua/src/ldo.c \
jni/src/lua/src/ldump.c \
jni/src/lua/src/lfunc.c \
jni/src/lua/src/lgc.c \
jni/src/lua/src/linit.c \
jni/src/lua/src/liolib.c \
jni/src/lua/src/llex.c \
jni/src/lua/src/lmathlib.c \
jni/src/lua/src/lmem.c \
jni/src/lua/src/loadlib.c \
jni/src/lua/src/lobject.c \
jni/src/lua/src/lopcodes.c \
jni/src/lua/src/loslib.c \
jni/src/lua/src/lparser.c \
jni/src/lua/src/lstate.c \
jni/src/lua/src/lstring.c \
jni/src/lua/src/lstrlib.c \
jni/src/lua/src/ltable.c \
jni/src/lua/src/ltablib.c \
jni/src/lua/src/ltm.c \
jni/src/lua/src/lundump.c \
jni/src/lua/src/lvm.c \
jni/src/lua/src/lzio.c \
jni/src/lua/src/print.c
jni/lib/lua/src/lapi.c \
jni/lib/lua/src/lauxlib.c \
jni/lib/lua/src/lbaselib.c \
jni/lib/lua/src/lcode.c \
jni/lib/lua/src/ldblib.c \
jni/lib/lua/src/ldebug.c \
jni/lib/lua/src/ldo.c \
jni/lib/lua/src/ldump.c \
jni/lib/lua/src/lfunc.c \
jni/lib/lua/src/lgc.c \
jni/lib/lua/src/linit.c \
jni/lib/lua/src/liolib.c \
jni/lib/lua/src/llex.c \
jni/lib/lua/src/lmathlib.c \
jni/lib/lua/src/lmem.c \
jni/lib/lua/src/loadlib.c \
jni/lib/lua/src/lobject.c \
jni/lib/lua/src/lopcodes.c \
jni/lib/lua/src/loslib.c \
jni/lib/lua/src/lparser.c \
jni/lib/lua/src/lstate.c \
jni/lib/lua/src/lstring.c \
jni/lib/lua/src/lstrlib.c \
jni/lib/lua/src/ltable.c \
jni/lib/lua/src/ltablib.c \
jni/lib/lua/src/ltm.c \
jni/lib/lua/src/lundump.c \
jni/lib/lua/src/lvm.c \
jni/lib/lua/src/lzio.c \
jni/lib/lua/src/print.c

# SQLite3
LOCAL_SRC_FILES += deps/sqlite/sqlite3.c
Expand All @@ -376,7 +376,7 @@ LOCAL_SRC_FILES += \
jni/src/threading/thread.cpp

# JSONCPP
LOCAL_SRC_FILES += jni/src/jsoncpp/json/jsoncpp.cpp
LOCAL_SRC_FILES += jni/lib/jsoncpp/jsoncpp.cpp

LOCAL_SHARED_LIBRARIES := iconv openal ogg vorbis gmp
LOCAL_STATIC_LIBRARIES := Irrlicht freetype curl ssl crypto android_native_app_glue $(PROFILER_LIBS)
Expand Down
8 changes: 5 additions & 3 deletions cmake/Modules/FindGMP.cmake
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@

option(ENABLE_SYSTEM_GMP "Use GMP from system" TRUE)
mark_as_advanced(GMP_LIBRARY GMP_INCLUDE_DIR)
set(USE_SYSTEM_GMP FALSE)
set(USE_SYSTEM_GMP FALSE PARENT_SCOPE)

if(ENABLE_SYSTEM_GMP)
find_library(GMP_LIBRARY NAMES libgmp.so)
Expand All @@ -10,6 +9,7 @@ if(ENABLE_SYSTEM_GMP)
if(GMP_LIBRARY AND GMP_INCLUDE_DIR)
message (STATUS "Using GMP provided by system.")
set(USE_SYSTEM_GMP TRUE)
set(USE_SYSTEM_GMP TRUE PARENT_SCOPE)
else()
message (STATUS "Detecting GMP from system failed.")
endif()
Expand All @@ -19,8 +19,10 @@ endif()

if(NOT USE_SYSTEM_GMP)
message(STATUS "Using bundled mini-gmp library.")
set(GMP_INCLUDE_DIR ${PROJECT_SOURCE_DIR}/gmp)
set(GMP_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/gmp)
set(GMP_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/gmp PARENT_SCOPE)
set(GMP_LIBRARY gmp)
set(GMP_LIBRARY gmp PARENT_SCOPE)
add_subdirectory(gmp)
endif()

Expand Down
7 changes: 3 additions & 4 deletions cmake/Modules/FindJson.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@ endif()

if(NOT JSONCPP_FOUND)
message(STATUS "Using bundled JSONCPP library.")
set(JSON_INCLUDE_DIR ${PROJECT_SOURCE_DIR}/jsoncpp)
set(JSON_LIBRARY jsoncpp)
add_subdirectory(jsoncpp/json)
set(JSON_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/jsoncpp PARENT_SCOPE)
set(JSON_LIBRARY jsoncpp PARENT_SCOPE)
add_subdirectory(jsoncpp)
endif()

23 changes: 23 additions & 0 deletions lib/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# LuaJIT
option(ENABLE_LUAJIT "Enable LuaJIT support" TRUE)
set(USE_LUAJIT FALSE PARENT_SCOPE)
if(ENABLE_LUAJIT)
find_package(LuaJIT)
if(LUAJIT_FOUND)
set(USE_LUAJIT TRUE)
set(USE_LUAJIT TRUE PARENT_SCOPE)
message (STATUS "Using LuaJIT provided by system.")
endif(LUAJIT_FOUND)
else()
message (STATUS "LuaJIT detection disabled! (ENABLE_LUAJIT=0)")
endif()

if(NOT USE_LUAJIT)
message(STATUS "LuaJIT not found, using bundled Lua.")
set(LUA_LIBRARY lua PARENT_SCOPE)
set(LUA_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/lua/src PARENT_SCOPE)
add_subdirectory(lua)
endif()

find_package(GMP REQUIRED)
find_package(Json REQUIRED)
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loading