Android NDK:警告:在此项目中没有要构建的模块 [英] Android NDK: Warning: There are no modules to build in this project
问题描述
我是NDK开发的新用户,当我尝试从cygwin终端调用ndk构建工具时,我目前面临一个问题:
Android NDK:警告:此项目中没有要构建的模块!
我在Windows(x64)下,使用r10d(64位)NDK。
我尝试从我的项目的根目录调用它,它包含一个简单的.c文件和一个Android.mk的jni文件夹:
LOCAL_PATH:= $(call my-dir)
include $(CLEAR_VARS)
这里我们给出我们的模块名称和源文件
LOCAL_MODULE:= mycfile
LOCAL_SRC_FILES:= mycfile.c
APP_PLATFORM:= android-19
感谢您的帮助!
您的 Android.mk 文件缺少告诉ndk实际构建模块的宏。将它添加到文件末尾:
include $(BUILD_SHARED_LIBRARY)
Btw,APP_PLATFORM变量必须放在 Application.mk 而不是 Android.mk / p>
I'm new in NDK development and I'm currently facing a problem, when I try to invoke the ndk build tool from cygwin terminal:
Android NDK: WARNING: There are no modules to build in this project!
I’m under windows (x64) and I use the r10d (64-bit) NDK. I try to invoke it from the root of my project that contains a jni folder with a simple .c file and an Android.mk:
LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
# Here we give our module name and source file(s)
LOCAL_MODULE := mycfile
LOCAL_SRC_FILES := mycfile.c
APP_PLATFORM := android-19
Thank you for your help !
your Android.mk file is missing the macro that tells the ndk to actually build a module. Add this to the end of your file:
include $(BUILD_SHARED_LIBRARY)
Btw, APP_PLATFORM variable has to be put inside Application.mk instead of Android.mk.
这篇关于Android NDK:警告:在此项目中没有要构建的模块的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!