Hi there. I'm trying to compile the c-code, following
this answer found on this group.
However, I don't quite understand what the Android.mk file in the jni folder should contain. The poster says:
In jni folder, change the content of Android.mk to the following:
BASE_PATH:= $(call my-dir)
include $(BASE_PATH)/antidote/Android.mk
But I don't have an antidote folder, so I just kept what is in it:
BASE_PATH:= $(call my-dir)
include $(BASE_PATH)/src/communication/plugin/Android.mk
include $(BASE_PATH)/src/communication/plugin/trans/Android.mk
include $(BASE_PATH)/src/communication/plugin/android/Android.mk
include $(BASE_PATH)/src/communication/parser/Android.mk
include $(BASE_PATH)/src/communication/Android.mk
include $(BASE_PATH)/src/specializations/Android.mk
include $(BASE_PATH)/src/util/Android.mk
include $(BASE_PATH)/src/dim/Android.mk
include $(BASE_PATH)/src/api/Android.mk
include $(BASE_PATH)/src/trans/Android.mk
include $(BASE_PATH)/src/trans/plugin/Android.mk
include $(BASE_PATH)/src/Android.mk
include $(BASE_PATH)/apps/Android.mk
When running
../android-ndk-r10d/ndk-build NDK_PROJECT_PATH=.
however, I get an error "cannot find -landroid". I've tested to see which Android.mk file causes this, and it is only when te last one is included ($(BASE_PATH)/apps/Android.mk).
The contents of this Android.mk are not altered from the github repository:
LOCAL_PATH:= $(call my-dir)
include $(CLEAR_VARS)
LOCAL_MODULE:= healthd
LOCAL_MODULE_TAGS := debug eng
LOCAL_CFLAGS:= -Wall
LOCAL_SRC_FILES := healthd_android.c healthd_common.c
LOCAL_CFLAGS := -Wall
LOCAL_C_INCLUDES := $(LOCAL_PATH) $(LOCAL_PATH)/.. $(LOCAL_PATH)/../src
LOCAL_WHOLE_STATIC_LIBRARIES := libantidotemanager
LOCAL_LDLIBS := -llog -landroid
include $(BUILD_SHARED_LIBRARY)
What am I doing wrong?