- Java 双重比较
- java - 比较器与 Apache BeanComparator
- Objective-C 完成 block 导致额外的方法调用?
- database - RESTful URI 是否应该公开数据库主键?
我正在 Beaglebone Black 上做一个项目,我已经在上面移植了 Android KitKat。现在我需要一个 android 应用程序来帮助我访问 beaglebone 上的那些 gpios 以进行项目。
所以我正在使用 android studio 1.3.1 为我的项目创建我的应用程序,因此要通过 android 访问硬件引脚,我必须为此使用 NDK。现在,当我尝试将 gradle 2.2.1 与我的 NDK 文件同步时,它会打印一条错误,我应该设置 android.useDeprecatedNdk=true。现在,当我这样做时,它再次显示未定义 DeprecatedNdk() 的错误。虽然我已经从 android 开发者网站下载了最新版本的 NDK,即 android-ndk-r10e,但错误仍然存在。以下是模块中的 build.gradle 文件。
apply plugin: 'com.android.application'
android {
compileSdkVersion 19
buildToolsVersion "19.1.0"
defaultConfig {
applicationId "com.packt.gpio"
minSdkVersion 19
targetSdkVersion 19
ndk {
moduleName "packtHAL"
}
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
}
}
}
dependencies {
compile 'com.android.support:support-v4:19.+'
}
另外它显示的错误是:
Error:(14, 0) Error: NDK integration is deprecated in the current plugin.
Consider trying the new experimental plugin. For details, see http://tools.android.com/tech-docs/new-build-system/gradle-experimental.
Set "android.useDeprecatedNdk=true" in gradle.properties to continue using the current NDK integration.
如果我将属性添加到文件中,则会显示以下错误:
Error:(6, 0) Gradle DSL method not found: 'useDeprecatedNdk()'
Possible causes:The project 'gpio' may be using a version of Gradle that does not contain the method.
The build file may be missing a Gradle plugin.
如果有人知道对此应该做什么。请分享您的想法。
谢谢
最佳答案
请检查新文档:http://tools.android.com/tech-docs/android-ndk-preview
以下是最新的项目设置说明:http://tools.android.com/tech-docs/new-build-system/gradle-experimental
关于android - NDK 文件不与 Gradle Android 同步,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32064787/
我想使用 ndk 构建一个 3rd 方库 avahi。 avahi 已经有 android 端口(带有有效的 Android.mk)。 我做了什么: 我已经成功创建了一个项目并将所有源代码复制到 jn
由于不再需要Android NDK,因此我尝试将其卸载。在Eclipse中找到的路径似乎已损坏。我应该如何清理这个烂摊子?我尝试了brew,但它说未安装NDK。 (它甚至告诉我未安装SDK!也许不是通
我是 Android Studio 和 Android NDK 的新手。我正在尝试使用 android NDK 为类分配编译一个简单的 hello.c 程序。我已按照以下项目说明进行操作,但出现错误:
当我尝试执行 NDK 构建时,我收到以下错误列表...有人知道吗? encies\FreeImage/D:/Projects.CPP/Engine5/svn/trunk/Dependencies/Fr
我正在使用 android-ndk-profiler-3.1 为我的项目进行 NDK 分析。我在 Android.mk 中进行了如下更改... LOCAL_PATH := $(call my-dir)
我需要使用 cutils 库和头文件在我的 NDK 项目中实现 ashmem,但我在我的系统中找不到与 cutils 相关的任何内容。它位于何处或从何处获得? 最佳答案 Android“cutils”
我有两个独立的项目,一个项目用于构建 Boost 库,另一个项目从构建的 boost 库中调用。 Boost 项目编译良好并生成 libboost.a 文件。我想要实现的是将此库添加到我的其他 NDK
我在ndk-build clean上遇到以下错误 mo@mo-Toshiba ~/Workspace/AndroidApp/jni/android_programming_driver $ ndk-b
已结束。此问题正在寻求书籍、工具、软件库等的推荐。它不满足Stack Overflow guidelines 。目前不接受答案。 我们不允许提出寻求书籍、工具、软件库等推荐的问题。您可以编辑问题,以便
我正在尝试使用 NDK(又使用开放 SLES)在 Android 上创建一个基于流的音频应用程序。我已经完成了基本的流媒体设置。我需要知道 Android 中如何处理欠载(或重载)?错误回调是如何实现
我的 Application.mk 设置为构建 arm 以及 x86 共享库: APP_ABI :- armeabi-v7a x86 我有预建的 openssl 静态库: libcrypto_v7a.
我的 $NDK_HOME 文件夹包含标准库的不同实现。 qdii@nomada /opt/android-ndk/platforms $ ls -l total 24 drwxr-xr-x 5 roo
如何安装android-ndk。我已经为 ndk 设置了路径,但在执行“ndk-build”命令时仍然出现错误。 fya 我正在使用 Windows 操作系统。 最佳答案 它对我有用: 打开命令提示符
构建 Android-ndk 时出现以下错误 请帮助我。 Cygwin.bat @echo off set IS_UNIX= set DEV_ROOT=C:/iliu-Android-NDK-Fibo
我开始使用 android ndk (r8c),为此我安装了新版本的 Ubuntu 12.10 (32bit) 问题,无论我尝试构建什么,我都会遇到让我发疯的怪异错误...... ~/workspac
我正在尝试向我的 Android 项目添加 Crashlytics 支持,该项目使用 NDK 和 gradle CMake。这意味着我的共享项目需要符号。所以如果我想为发布版本创建符号,我会调用 gr
我想知道是否有人设法使用 Android NDK(r8d) 的工具链构建了新的 SDL2。 SDL2 似乎非常接近发布(从昨天开始,它不再是“正在 build 中:http://hg.libsdl.o
我试图在“ndk-build”过程中禁用所有警告,以编译与 Android 上的 JNI 一起使用的 CPP 代码。 我正在使用 LOCAL_CFLAGS := -Wno-error没有成功。 有任何
谁能告诉我如何在android(ndk-build)中建立C-ares库 最佳答案 这是使用NDK standalone toolchain将其构建为ARMv7的静态库的方法: export NDK=
我正在尝试从我的 native 代码中读取一个简单的文本文件。 我把file.txt放在assets文件夹下 在我的事件中,我正在创建 Assets 管理器:assetManager = getAss
我是一名优秀的程序员,十分优秀!