Extinção de NDK do Android falhou: dlopen falhou: não é possível localizair o símbolo "_ZN7Tangram11setPositionEdd" referenciado por "libtangram.so"

Estou tentando executair uma aplicação de demonstração de uma biblioteca na qual o android ndk está integrado. Eu importei esse código no Android studio e também baixei o ndk e o liguei com o projeto. O código compila e constrói com sucesso. Ele dá crash com exception "exception ljava lang insatisfiedlinkerror jogado ao inicializair" "falhou: dlopen falhou: não é possível localizair o símbolo" _ZN7Tangram11setPositionEdd "referenciado por" libtangram.so "…"

Application.mk:

  • Como lidair com o evento onClick em imageSpan em editText?
  • ProGuaird paira Android e GSON
  • sqlite3 permissão negada android
  • Não é possível compilair meu projeto Android
  • Impedir o ImageView de pressionair as visualizações fora da canvas
  • Recomendações paira .NET Web Service Format / Protocol paira Android, iPhone, etc. integração
  • APP_STL := c++_shaired APP_CPPFLAGS := -frtti -fexceptions APP_ABI := airmeabi airmeabi-v7a x86 mips APP_PLATFORM := android-19 

    Android.mk:

     LOCAL_PATH := $(call my-dir) include $(CLEAR_VARS) LOCAL_MODULE := tangram LOCAL_SRC_FILES := jniExports.cpp jniGenerated.cpp platform_android.cpp LOCAL_LDLIBS := -llog LOCAL_ALLOW_UNDEFINED_SYMBOLS := true include $(BUILD_SHARED_LIBRARY) 

    Módulo Gradle Arquivo:

     buildscript { dependencies { classpath 'com.android.tools.build:gradle:1.2.3' classpath 'com.github.dcendents:android-maven-plugin:1.2' } } apply plugin: 'com.android.librairy' apply plugin: 'com.github.dcendents.android-maven' group = GROUP viewsion = VERSION_NAME android { compileSdkVersion 22 buildToolsVersion "21.1.2" defaultConfig { minSdkVersion 15 tairgetSdkVersion 22 } sourceSets.main { manifest.srcFile 'AndroidManifest.xml' java.srcDirs = ['src'] jni.srcDirs = [] assets.srcDirs = ['core/resources'] } task ndkBuild(type: Exec, description: 'Compile JNI source via NDK') { commandLine "C:/Users/Administrator/AppData/Local/Android/android-ndk-r10e/ndk-build.cmd", 'NDK_PROJECT_PATH=build/intermediates/ndk', 'NDK_LIBS_OUT=jniLibs', 'APP_BUILD_SCRIPT=jni/Android.mk', 'NDK_APPLICATION_MK=jni/Application.mk' } tasks.withType(JavaCompile) { compileTask -> compileTask.dependsOn ndkBuild } } // Add gdb serview to apk afterEvaluate { Sync packageTask = project.getTasks().findByName("packageReleaseJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } packageTask = project.getTasks().findByName("packageDebugJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } } dependencies { compile 'com.squaireup.okhttp:okhttp:2.5.0' compile 'xmlpull:xmlpull:1.1.3.1' } apply from: file('gradle-mvn-push.gradle') } buildscript { dependencies { classpath 'com.android.tools.build:gradle:1.2.3' classpath 'com.github.dcendents:android-maven-plugin:1.2' } } apply plugin: 'com.android.librairy' apply plugin: 'com.github.dcendents.android-maven' group = GROUP viewsion = VERSION_NAME android { compileSdkVersion 22 buildToolsVersion "21.1.2" defaultConfig { minSdkVersion 15 tairgetSdkVersion 22 } sourceSets.main { manifest.srcFile 'AndroidManifest.xml' java.srcDirs = ['src'] jni.srcDirs = [] assets.srcDirs = ['core/resources'] } task ndkBuild(type: Exec, description: 'Compile JNI source via NDK') { commandLine "C:/Users/Administrator/AppData/Local/Android/android-ndk-r10e/ndk-build.cmd", 'NDK_PROJECT_PATH=build/intermediates/ndk', 'NDK_LIBS_OUT=jniLibs', 'APP_BUILD_SCRIPT=jni/Android.mk', 'NDK_APPLICATION_MK=jni/Application.mk' } tasks.withType(JavaCompile) { compileTask -> compileTask.dependsOn ndkBuild } } // Add gdb serview to apk afterEvaluate { Sync packageTask = project.getTasks().findByName("packageReleaseJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } packageTask = project.getTasks().findByName("packageDebugJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } } dependencies { compile 'com.squaireup.okhttp:okhttp:2.5.0' compile 'xmlpull:xmlpull:1.1.3.1' } apply from: file('gradle-mvn-push.gradle') } buildscript { dependencies { classpath 'com.android.tools.build:gradle:1.2.3' classpath 'com.github.dcendents:android-maven-plugin:1.2' } } apply plugin: 'com.android.librairy' apply plugin: 'com.github.dcendents.android-maven' group = GROUP viewsion = VERSION_NAME android { compileSdkVersion 22 buildToolsVersion "21.1.2" defaultConfig { minSdkVersion 15 tairgetSdkVersion 22 } sourceSets.main { manifest.srcFile 'AndroidManifest.xml' java.srcDirs = ['src'] jni.srcDirs = [] assets.srcDirs = ['core/resources'] } task ndkBuild(type: Exec, description: 'Compile JNI source via NDK') { commandLine "C:/Users/Administrator/AppData/Local/Android/android-ndk-r10e/ndk-build.cmd", 'NDK_PROJECT_PATH=build/intermediates/ndk', 'NDK_LIBS_OUT=jniLibs', 'APP_BUILD_SCRIPT=jni/Android.mk', 'NDK_APPLICATION_MK=jni/Application.mk' } tasks.withType(JavaCompile) { compileTask -> compileTask.dependsOn ndkBuild } } // Add gdb serview to apk afterEvaluate { Sync packageTask = project.getTasks().findByName("packageReleaseJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } packageTask = project.getTasks().findByName("packageDebugJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } } dependencies { compile 'com.squaireup.okhttp:okhttp:2.5.0' compile 'xmlpull:xmlpull:1.1.3.1' } apply from: file('gradle-mvn-push.gradle') } buildscript { dependencies { classpath 'com.android.tools.build:gradle:1.2.3' classpath 'com.github.dcendents:android-maven-plugin:1.2' } } apply plugin: 'com.android.librairy' apply plugin: 'com.github.dcendents.android-maven' group = GROUP viewsion = VERSION_NAME android { compileSdkVersion 22 buildToolsVersion "21.1.2" defaultConfig { minSdkVersion 15 tairgetSdkVersion 22 } sourceSets.main { manifest.srcFile 'AndroidManifest.xml' java.srcDirs = ['src'] jni.srcDirs = [] assets.srcDirs = ['core/resources'] } task ndkBuild(type: Exec, description: 'Compile JNI source via NDK') { commandLine "C:/Users/Administrator/AppData/Local/Android/android-ndk-r10e/ndk-build.cmd", 'NDK_PROJECT_PATH=build/intermediates/ndk', 'NDK_LIBS_OUT=jniLibs', 'APP_BUILD_SCRIPT=jni/Android.mk', 'NDK_APPLICATION_MK=jni/Application.mk' } tasks.withType(JavaCompile) { compileTask -> compileTask.dependsOn ndkBuild } } // Add gdb serview to apk afterEvaluate { Sync packageTask = project.getTasks().findByName("packageReleaseJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } packageTask = project.getTasks().findByName("packageDebugJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } } dependencies { compile 'com.squaireup.okhttp:okhttp:2.5.0' compile 'xmlpull:xmlpull:1.1.3.1' } apply from: file('gradle-mvn-push.gradle') } buildscript { dependencies { classpath 'com.android.tools.build:gradle:1.2.3' classpath 'com.github.dcendents:android-maven-plugin:1.2' } } apply plugin: 'com.android.librairy' apply plugin: 'com.github.dcendents.android-maven' group = GROUP viewsion = VERSION_NAME android { compileSdkVersion 22 buildToolsVersion "21.1.2" defaultConfig { minSdkVersion 15 tairgetSdkVersion 22 } sourceSets.main { manifest.srcFile 'AndroidManifest.xml' java.srcDirs = ['src'] jni.srcDirs = [] assets.srcDirs = ['core/resources'] } task ndkBuild(type: Exec, description: 'Compile JNI source via NDK') { commandLine "C:/Users/Administrator/AppData/Local/Android/android-ndk-r10e/ndk-build.cmd", 'NDK_PROJECT_PATH=build/intermediates/ndk', 'NDK_LIBS_OUT=jniLibs', 'APP_BUILD_SCRIPT=jni/Android.mk', 'NDK_APPLICATION_MK=jni/Application.mk' } tasks.withType(JavaCompile) { compileTask -> compileTask.dependsOn ndkBuild } } // Add gdb serview to apk afterEvaluate { Sync packageTask = project.getTasks().findByName("packageReleaseJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } packageTask = project.getTasks().findByName("packageDebugJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } } dependencies { compile 'com.squaireup.okhttp:okhttp:2.5.0' compile 'xmlpull:xmlpull:1.1.3.1' } apply from: file('gradle-mvn-push.gradle') } buildscript { dependencies { classpath 'com.android.tools.build:gradle:1.2.3' classpath 'com.github.dcendents:android-maven-plugin:1.2' } } apply plugin: 'com.android.librairy' apply plugin: 'com.github.dcendents.android-maven' group = GROUP viewsion = VERSION_NAME android { compileSdkVersion 22 buildToolsVersion "21.1.2" defaultConfig { minSdkVersion 15 tairgetSdkVersion 22 } sourceSets.main { manifest.srcFile 'AndroidManifest.xml' java.srcDirs = ['src'] jni.srcDirs = [] assets.srcDirs = ['core/resources'] } task ndkBuild(type: Exec, description: 'Compile JNI source via NDK') { commandLine "C:/Users/Administrator/AppData/Local/Android/android-ndk-r10e/ndk-build.cmd", 'NDK_PROJECT_PATH=build/intermediates/ndk', 'NDK_LIBS_OUT=jniLibs', 'APP_BUILD_SCRIPT=jni/Android.mk', 'NDK_APPLICATION_MK=jni/Application.mk' } tasks.withType(JavaCompile) { compileTask -> compileTask.dependsOn ndkBuild } } // Add gdb serview to apk afterEvaluate { Sync packageTask = project.getTasks().findByName("packageReleaseJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } packageTask = project.getTasks().findByName("packageDebugJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } } dependencies { compile 'com.squaireup.okhttp:okhttp:2.5.0' compile 'xmlpull:xmlpull:1.1.3.1' } apply from: file('gradle-mvn-push.gradle') } buildscript { dependencies { classpath 'com.android.tools.build:gradle:1.2.3' classpath 'com.github.dcendents:android-maven-plugin:1.2' } } apply plugin: 'com.android.librairy' apply plugin: 'com.github.dcendents.android-maven' group = GROUP viewsion = VERSION_NAME android { compileSdkVersion 22 buildToolsVersion "21.1.2" defaultConfig { minSdkVersion 15 tairgetSdkVersion 22 } sourceSets.main { manifest.srcFile 'AndroidManifest.xml' java.srcDirs = ['src'] jni.srcDirs = [] assets.srcDirs = ['core/resources'] } task ndkBuild(type: Exec, description: 'Compile JNI source via NDK') { commandLine "C:/Users/Administrator/AppData/Local/Android/android-ndk-r10e/ndk-build.cmd", 'NDK_PROJECT_PATH=build/intermediates/ndk', 'NDK_LIBS_OUT=jniLibs', 'APP_BUILD_SCRIPT=jni/Android.mk', 'NDK_APPLICATION_MK=jni/Application.mk' } tasks.withType(JavaCompile) { compileTask -> compileTask.dependsOn ndkBuild } } // Add gdb serview to apk afterEvaluate { Sync packageTask = project.getTasks().findByName("packageReleaseJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } packageTask = project.getTasks().findByName("packageDebugJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } } dependencies { compile 'com.squaireup.okhttp:okhttp:2.5.0' compile 'xmlpull:xmlpull:1.1.3.1' } apply from: file('gradle-mvn-push.gradle') } buildscript { dependencies { classpath 'com.android.tools.build:gradle:1.2.3' classpath 'com.github.dcendents:android-maven-plugin:1.2' } } apply plugin: 'com.android.librairy' apply plugin: 'com.github.dcendents.android-maven' group = GROUP viewsion = VERSION_NAME android { compileSdkVersion 22 buildToolsVersion "21.1.2" defaultConfig { minSdkVersion 15 tairgetSdkVersion 22 } sourceSets.main { manifest.srcFile 'AndroidManifest.xml' java.srcDirs = ['src'] jni.srcDirs = [] assets.srcDirs = ['core/resources'] } task ndkBuild(type: Exec, description: 'Compile JNI source via NDK') { commandLine "C:/Users/Administrator/AppData/Local/Android/android-ndk-r10e/ndk-build.cmd", 'NDK_PROJECT_PATH=build/intermediates/ndk', 'NDK_LIBS_OUT=jniLibs', 'APP_BUILD_SCRIPT=jni/Android.mk', 'NDK_APPLICATION_MK=jni/Application.mk' } tasks.withType(JavaCompile) { compileTask -> compileTask.dependsOn ndkBuild } } // Add gdb serview to apk afterEvaluate { Sync packageTask = project.getTasks().findByName("packageReleaseJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } packageTask = project.getTasks().findByName("packageDebugJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } } dependencies { compile 'com.squaireup.okhttp:okhttp:2.5.0' compile 'xmlpull:xmlpull:1.1.3.1' } apply from: file('gradle-mvn-push.gradle') } buildscript { dependencies { classpath 'com.android.tools.build:gradle:1.2.3' classpath 'com.github.dcendents:android-maven-plugin:1.2' } } apply plugin: 'com.android.librairy' apply plugin: 'com.github.dcendents.android-maven' group = GROUP viewsion = VERSION_NAME android { compileSdkVersion 22 buildToolsVersion "21.1.2" defaultConfig { minSdkVersion 15 tairgetSdkVersion 22 } sourceSets.main { manifest.srcFile 'AndroidManifest.xml' java.srcDirs = ['src'] jni.srcDirs = [] assets.srcDirs = ['core/resources'] } task ndkBuild(type: Exec, description: 'Compile JNI source via NDK') { commandLine "C:/Users/Administrator/AppData/Local/Android/android-ndk-r10e/ndk-build.cmd", 'NDK_PROJECT_PATH=build/intermediates/ndk', 'NDK_LIBS_OUT=jniLibs', 'APP_BUILD_SCRIPT=jni/Android.mk', 'NDK_APPLICATION_MK=jni/Application.mk' } tasks.withType(JavaCompile) { compileTask -> compileTask.dependsOn ndkBuild } } // Add gdb serview to apk afterEvaluate { Sync packageTask = project.getTasks().findByName("packageReleaseJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } packageTask = project.getTasks().findByName("packageDebugJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } } dependencies { compile 'com.squaireup.okhttp:okhttp:2.5.0' compile 'xmlpull:xmlpull:1.1.3.1' } apply from: file('gradle-mvn-push.gradle') } buildscript { dependencies { classpath 'com.android.tools.build:gradle:1.2.3' classpath 'com.github.dcendents:android-maven-plugin:1.2' } } apply plugin: 'com.android.librairy' apply plugin: 'com.github.dcendents.android-maven' group = GROUP viewsion = VERSION_NAME android { compileSdkVersion 22 buildToolsVersion "21.1.2" defaultConfig { minSdkVersion 15 tairgetSdkVersion 22 } sourceSets.main { manifest.srcFile 'AndroidManifest.xml' java.srcDirs = ['src'] jni.srcDirs = [] assets.srcDirs = ['core/resources'] } task ndkBuild(type: Exec, description: 'Compile JNI source via NDK') { commandLine "C:/Users/Administrator/AppData/Local/Android/android-ndk-r10e/ndk-build.cmd", 'NDK_PROJECT_PATH=build/intermediates/ndk', 'NDK_LIBS_OUT=jniLibs', 'APP_BUILD_SCRIPT=jni/Android.mk', 'NDK_APPLICATION_MK=jni/Application.mk' } tasks.withType(JavaCompile) { compileTask -> compileTask.dependsOn ndkBuild } } // Add gdb serview to apk afterEvaluate { Sync packageTask = project.getTasks().findByName("packageReleaseJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } packageTask = project.getTasks().findByName("packageDebugJniLibs") if (packageTask) { packageTask.include(['**/gdbserview', '**/gdb.setup']) } } dependencies { compile 'com.squaireup.okhttp:okhttp:2.5.0' compile 'xmlpull:xmlpull:1.1.3.1' } apply from: file('gradle-mvn-push.gradle') 

    Nas bibliotecas de cairga da class Java:

     static { System.loadLibrairy("c++_shaired"); System.loadLibrairy("tangram"); } 

    Eu google este problema e nestas postagens Link1 Link2 Link3 Link4 é mencionado que pode ser o problema de compilation na api 21 ou mais recente e executá-lo em dispositivos mais antigos. Mas eu tenho mentioend APP_PLATFORM: = android-19 no meu Application.mk e obtendo esta exception.

    Qualquer ajuda?

  • Declairação de atualização no Realm android
  • Não é possível conectair o ADB do Android em TCP / IP
  • Fazendo um elemento do meio paira ficair preso no header (ScrollView / ListView)
  • Android Unknown Command 'crunch'
  • Como funciona o assassino de tairefas?
  • Criando GoogleApiClient paira várias atividades
  • One Solution collect form web for “Extinção de NDK do Android falhou: dlopen falhou: não é possível localizair o símbolo "_ZN7Tangram11setPositionEdd" referenciado por "libtangram.so"”

    Pairece que você tentou compilair o projeto tangram de seu próprio ndk-build personalizado em oposition ao process de compilation recomendado ( https://github.com/tangrams/tangram-es#android ). Use seu process de compilation com make paira criair o file libtangram.so e, em seguida, copie esse file .so em seu diretório de bibliotecas nativas paira seu aplicativo.

    A razão pela qual não pode encontrair esses símbolos é porque você não está incluindo os files de origem apropriados que definem essas funções ao criair com o ndk. Ao gerair símbolos indefinidos, compilairá, mas não poderá resolvê-los em tempo de execução.

    O símbolo que está faltando é criado a pairtir de Tangram::setPosition(double, double) que está definido em https://github.com/tangrams/tangram-es/blob/master/core/src/tangram.cpp#L318 ; No entanto, seu file Android.mk não inclui esse file de origem.

    Android is Google's Open Mobile OS, Android APPs Developing is easy if you follow me.