Link errors while building gstremaer 1 sample for android with Android Studio

suspension manusha1980 at gmail.com
Mon Sep 7 02:55:27 PDT 2015


In case any one gets in to the same issue...
Changing the order of link libraries made it link successfully. Here is the
final build.gradle file.. which works with Android Studio 1.2.

apply plugin: 'com.android.model.application'
model {
    android {
        compileSdkVersion = 23
        buildToolsVersion = "23.0.0"

        sourceCompatibility = JavaVersion.VERSION_1_7
        targetCompatibility = JavaVersion.VERSION_1_7


        defaultConfig.with  {
            applicationId = "xxx"
            minSdkVersion.apiLevel = 15
            targetSdkVersion.apiLevel = 23
            versionCode = 1
            versionName = "1.0"

            buildConfigFields.with {
                create() {
                    type = "int"
                    name = "VALUE"
                    value = "1"
                }
            }
        }
    }

    android.ndk {
        moduleName = "gts_player"
//        toolchain = "gcc"
//        toolchainVersion = "4.9"

        cppFlags +=
"-I/home/manusha/development/gstreamer-1.0-android-armv7-1.5.2/include/gstreamer-1.0/"
        cppFlags +=
"-I/home/manusha/development/gstreamer-1.0-android-armv7-1.5.2/include/glib-2.0/"
        cppFlags +=
"-I/home/manusha/development/gstreamer-1.0-android-armv7-1.5.2/lib/gstreamer-1.0/include/"
        cppFlags +=
"-I/home/manusha/development/gstreamer-1.0-android-armv7-1.5.2/lib/glib-2.0/include/"
        cppFlags +=
"-I/home/manusha/development/gstreamer-1.0-android-armv7-1.5.2/include/libxml2/"
        cppFlags +=
"-I/home/manusha/development/gstreamer-1.0-android-armv7-1.5.2/include"

        ldFlags +=
"-L/home/manusha/development/gstreamer-1.0-android-armv7-1.5.2/lib/"
        ldLibs += ["glib-2.0", "log","xml2", "iconv", "gstreamer-1.0",
"gobject-2.0","gmodule-2.0","gthread-2.0","glib-2.0", "gio-2.0", "ffi",
"intl"]

        //stl = "stlport_static"
    }

    android.buildTypes {
        release {
            minifyEnabled = false
            proguardFiles += file('proguard-rules.pro')
        }
    }

    android.productFlavors {
        create ("arm7") {
            ndk.abiFilters += "armeabi-v7a"
        }

    }
}

dependencies {
    compile fileTree(include: ['*.jar'], dir: 'libs')
    compile files('libs/gson-2.3.1.jar')
    compile 'com.android.support:appcompat-v7:22.2.0' 
}




--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/Link-errors-while-building-gstremaer-1-sample-for-android-with-Android-Studio-tp4673412p4673516.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.


More information about the gstreamer-devel mailing list