mirror of
https://github.com/google/flatbuffers.git
synced 2026-06-27 17:38:06 +00:00
Added android static library target for text parsing/generation etc.
Change-Id: If24e3eea90cef2a0d6a9d98fb503d2e3ec34ceed Tested: on Linux.
This commit is contained in:
@@ -19,26 +19,33 @@ LOCAL_PATH := $(call my-dir)/../..
|
|||||||
include $(LOCAL_PATH)/android/jni/include.mk
|
include $(LOCAL_PATH)/android/jni/include.mk
|
||||||
LOCAL_PATH := $(call realpath-portable,$(LOCAL_PATH))
|
LOCAL_PATH := $(call realpath-portable,$(LOCAL_PATH))
|
||||||
|
|
||||||
# Empty static library so that other projects can include FlatBuffers as a
|
# Empty static library so that other projects can include just the basic
|
||||||
# module.
|
# FlatBuffers headers as a module.
|
||||||
include $(CLEAR_VARS)
|
include $(CLEAR_VARS)
|
||||||
LOCAL_MODULE := flatbuffers
|
LOCAL_MODULE := flatbuffers
|
||||||
LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH)/include
|
LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH)/include
|
||||||
LOCAL_EXPORT_CPPFLAGS := -std=c++11 -fexceptions -Wall -Wno-literal-suffix
|
LOCAL_EXPORT_CPPFLAGS := -std=c++11 -fexceptions -Wall -Wno-literal-suffix
|
||||||
include $(BUILD_STATIC_LIBRARY)
|
include $(BUILD_STATIC_LIBRARY)
|
||||||
|
|
||||||
|
# static library that additionally includes text parsing/generation/reflection
|
||||||
|
# for projects that want richer functionality.
|
||||||
|
include $(CLEAR_VARS)
|
||||||
|
LOCAL_MODULE := flatbuffers_extra
|
||||||
|
LOCAL_SRC_FILES := src/idl_parser.cpp \
|
||||||
|
src/idl_gen_text.cpp \
|
||||||
|
src/reflection.cpp
|
||||||
|
LOCAL_STATIC_LIBRARIES := flatbuffers
|
||||||
|
include $(BUILD_STATIC_LIBRARY)
|
||||||
|
|
||||||
# FlatBuffers test
|
# FlatBuffers test
|
||||||
include $(CLEAR_VARS)
|
include $(CLEAR_VARS)
|
||||||
LOCAL_MODULE := FlatBufferTest
|
LOCAL_MODULE := FlatBufferTest
|
||||||
LOCAL_SRC_FILES := android/jni/main.cpp \
|
LOCAL_SRC_FILES := android/jni/main.cpp \
|
||||||
tests/test.cpp \
|
tests/test.cpp \
|
||||||
src/idl_parser.cpp \
|
|
||||||
src/idl_gen_text.cpp \
|
|
||||||
src/idl_gen_fbs.cpp \
|
src/idl_gen_fbs.cpp \
|
||||||
src/idl_gen_general.cpp \
|
src/idl_gen_general.cpp
|
||||||
src/reflection.cpp
|
|
||||||
LOCAL_LDLIBS := -llog -landroid
|
LOCAL_LDLIBS := -llog -landroid
|
||||||
LOCAL_STATIC_LIBRARIES := android_native_app_glue flatbuffers
|
LOCAL_STATIC_LIBRARIES := android_native_app_glue flatbuffers_extra
|
||||||
LOCAL_ARM_MODE := arm
|
LOCAL_ARM_MODE := arm
|
||||||
include $(BUILD_SHARED_LIBRARY)
|
include $(BUILD_SHARED_LIBRARY)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user