ndk-build

Android NDK linker Error:error: undefined reference to std::basic_string

吃可爱长大的小学妹 提交于 2019-12-06 05:57:16
I am currently trying to build a static library of some source c++ files requiring boost. I have been following the hello-libs example and have successfully linked the boost static file dependencies as is done in the sample example.Now said that, during while building the module I get these erros : Error:error: undefined reference to 'std::basic_string, std::allocator >::basic_string(char const*, std::allocator const&)' Error:error: undefined reference to 'std::runtime_error::runtime_error(std::string const&)' Error:error: undefined reference to 'std::_Rb_tree_decrement(std::_Rb_tree_node_base

Unable to run React-Native UIExplorer example project

六眼飞鱼酱① 提交于 2019-12-05 10:35:30
I've been trying to run UIExplorer project on Windows. I am getting the following error- ... ... make: *** [D:\react-native\ReactAndroid\build\tmp\buildReactNdkLib/local/ armeabi-v7a/objs/reactnativejni/JExecutorToken.o] Error 2 ... ... What went wrong: Execution failed for task ':ReactAndroid:buildReactNdkLib'. > Process 'command 'C:\android-ndk-r11b\ndk-build.cmd'' finished with non-zero exit value 2 ... ... Caused by: org.gradle.process.internal.ExecException: Process 'command 'C:\android-ndk-r11b\ndk-build.cmd'' finished with non-zero exit value 2 Is there any chance to overcome this issue

Cocos2d-x on Android Studio - New CPP files are not listed

房东的猫 提交于 2019-12-04 20:16:33
Android Studio 2.3.3 (LATEST) Cocos2d-x 3.15.1 (LATEST) It's my first experience with Cocos2d-x Game Engine, I encountered a lot of problems. The first time I tried the latest NDK of Android Studio but there is a bug on this NDK version when I tried to compile my project with : cocos compile -p android --android-studio so I change the NDK version to 13b. When I changed to NDK 13b the compilation was done without any problems and android studio build my project successfully but when I tried to create new CPP FILE or JAVA FILE or anything inside the Classes folder , Android Studio It does not

Android Studio NDK linker error undefined reference to 'cv::_OutputArray::_OutputArray(cv::Mat&)'

筅森魡賤 提交于 2019-12-02 16:14:47
问题 I'm working on an Android project which uses NDK, in which I have used opencv for some capture and image effects stuff. Here's how my Android.mk look like: LOCAL_PATH := $(call my-dir) include $(CLEAR_VARS) include path/to/OpenCV.mk LOCAL_MODULE := Scanner LOCAL_SRC_FILES := scan.cpp LOCAL_LDLIBS += -lz -lm -llog -landroid -ldl -lstdc++ LOCAL_LDFLAGS += -ljnigraphics -fexceptions -std=c++11 -L$(LOCAL_PATH)/sdk/native/jni/libs/armeabi-v7a -L$(LOCAL_PATH)/sdk/native/jni/3rdparty/libs/armeabi

Could not find method cppFlags() arguments() for arguments

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-01 16:13:36
I am trying to use std::function But the compiler throws an error Error:(50, 10) error: no type named 'function' in namespace 'std' I have tried to modify the build.gradle file externalNativeBuild { ndkBuild { path "src/main/jni/Android.mk" } cmake { cppFlags "-std=c++11" arguments "-DANDROID_STL=gnustl_static" path 'src/main/jni/CMakeLists.txt' } } But it doesn't accept arguments other than path and throws the following errors Error:(28, 0) Could not find method arguments() for arguments [-DANDROID_STL=gnustl_static] on object of type com.android.build.gradle.internal.dsl.CmakeOptions. Please

Could not find method cppFlags() arguments() for arguments

喜夏-厌秋 提交于 2019-12-01 14:54:01
问题 I am trying to use std::function But the compiler throws an error Error:(50, 10) error: no type named 'function' in namespace 'std' I have tried to modify the build.gradle file externalNativeBuild { ndkBuild { path "src/main/jni/Android.mk" } cmake { cppFlags "-std=c++11" arguments "-DANDROID_STL=gnustl_static" path 'src/main/jni/CMakeLists.txt' } } But it doesn't accept arguments other than path and throws the following errors Error:(28, 0) Could not find method arguments() for arguments [

windows下配置android-NDK环境

给你一囗甜甜゛ 提交于 2019-12-01 06:15:29
第一步,下载安装cygwin,(模拟Linux 的编译环境),我们可以到Cygwin的官方网站下载Cygwin的安装程序,地址是: http://www.cygwin.com/ ; 开始安装Cygwin,安装教程 http://jingyan.baidu.com/article/48a42057accae3a92525045a.html 第二部,下载ndk, http://developer.android.com/tools/sdk/ndk/index.html ;下载完成,解压; 第三步,在Cygwin的安装目录的etc的文件夹下,找到profile的文件: 在profile中配置ndk的环境变量: # Setup some default paths. Note that this order will allow user installed # software to override 'system' software. # Modifying these default path settings can be done in different ways. # To learn more about startup files, refer to your shell's man page. PATH="/usr/local/bin:/usr/bin:

APP_ABI ignored

丶灬走出姿态 提交于 2019-11-29 15:25:28
I used android-ndk-r13b, I downloaded it from Android website directly (not from SDK manager) and set the path from Project Structure in the Android Studio. It able to detect my Android.mk and Application.mk (both in my jni folder), I saw it from console log. In my Application.mk, I define this : APP_ABI:=armeabi-v7a But from the console log, I could see that everytime it execute ndk-build, there is always APP_ABI:=mips64 as the parameter. So, there is always an error. (I guess it is because of this wrong parameter, I got error "linker command failed...", because I compiled the .a and .so for

How to resolve Android ndk build command faild?

喜夏-厌秋 提交于 2019-11-29 12:27:35
I am developing simple ndk sample example using android ndk in android studio. While running my app studio shows below errors. Build command failed. Error while executing process D:\Sdk\cmake\3.6.4111459\bin\cmake.exe with arguments {--build D:\Android Studio\Workspace\NDKSample\app\.externalNativeBuild\cmake\debug\arm64-v8a --target native-lib} [1/2] Building CXX object CMakeFiles/native-lib.dir/src/main/cpp/native-lib.cpp.oFAILED: D:\Sdk\ndk-bundle\toolchains\llvm\prebuilt\windows-x86_64\bin\clang++.exe --target=aarch64-none-linux-android --gcc-toolchain=D:/Sdk/ndk-bundle/toolchains/aarch64

Unable to build GStreamer tutorials using Android Studio

纵然是瞬间 提交于 2019-11-29 07:35:42
I am trying to build the tutorials that are bundled with gstreamer-sdk-android-arm-debug-2013.6 . The Android.mk file in the src/jni directory (tutorial 1 project) references environment variables such as GSTREAMER_SDK_ROOT . From what I have read, Android Studio does not use/pass environment variables to the build scripts. Is there a best practice for modifying makefiles and for defining/retrieving the key/value pairs required by the build scripts? Ok, I have a working solution. You CAN pass environment variables to ndk-build (or any other process spawned by gradle Exec). In my case, I wanted