Yes, it's helpful !!!!! Thanks, but how can I use existing *(Android).mk 
files. Problem is that I have project on NDK that consist of some modules 
that have own *.mk file. In your solution, I'll have only one module that 
named is :

 
<https://lh3.googleusercontent.com/-w9BBG62YHso/VceyjHVXDbI/AAAAAAAADWY/Vh7tTP1iEv0/s1600/Screenshot%2Bfrom%2B2015-08-09%2B23%253A03%253A35.png>android.ndk
 {
    moduleName = "some_name"
    .......
}
// But I need something like this
android.ndk {    
    moduleName0 = "some_name0"
    /* some path to libraries 0 */
    moduleName1 = "some_name1"

    /* some path to libraries 1 */

    moduleName2 = "some_name2"

    /* some path to libraries 2 */

    moduleName3 = "some_name3"

    /* some path to libraries 3 */

.......

    moduleNameN = "some_nameN"

    /* some path to libraries N */

}


But I need to compile project then existed modules of *.so files add to 
java by LoadLibrary ... All that in one project. How can I do this ?
My project on the screenshoot.


среда, 29 июля 2015 г., 2:13:36 UTC+3 пользователь Steven Winston написал:
>
> I've had success using the -I cppFlags and CFlags.  I've noticed that 
> currently setting CFlags doesn't also set cppFlags.  So try doing this:
> CFlags += cppFlags
> Then you should have your expected behavior.
>
> On Monday, July 27, 2015 at 11:43:07 AM UTC-7, Денис Котов wrote:
>>
>> I have some trouble! My trouble case is that the gradle build tool can't 
>> find header file:
>>
>>
>> buildscript {
>>     repositories {
>>         maven { url 'https://maven.fabric.io/public' }
>>     }
>>
>>     dependencies {
>>         classpath 'io.fabric.tools:gradle:1.+'
>>     }
>> }
>> apply plugin: 'com.android.model.application'
>> //apply plugin: 'io.fabric'
>>
>> model {
>>     android {
>>         compileSdkVersion = 22
>>         buildToolsVersion = "22.0.1"
>>
>>         defaultConfig.with {
>>             applicationId = "com.collosteam.usbvideorecorder"
>>             minSdkVersion.apiLevel = 18
>>             targetSdkVersion.apiLevel = 22
>>             versionCode = 1
>>             versionName = "1.0"
>>         }
>>     }
>>
>>     android.ndk {
>>         moduleName = "webcam_lib"
>>         cppFlags += "-I${file("src/main/jni/UVCCamera")}".toString()
>>         cppFlags += "-I${file("src/main/jni/libjpeg")}".toString()
>>         cppFlags += "-I${file("src/main/jni/libusb")}".toString()
>>         cppFlags += "-I${file("src/main/jni/libuvc")}".toString()
>>
>>         //ldFlags += "-L/src/main/jni/libuvc/include/libuvc"
>>         //ldLibs += "usb"
>>
>>         // CFlags is configured in similiar way as cppFlags
>>         ldLibs    += 
>> "-L${file("src/main/jni/libuvc/include/libuvc")}".toString()
>>         CFlags    +=  "-I${file("-std=c11 
>> -I${project.buildDir}/../src/main/jni/libuvc/include/libuvc")}".toString()
>>         // CFlags    += 
>> "-I${file("src/main/jni/libuvc/include/libuvc")}".toString()
>>         // CFlags    += 
>> "-I${file("src/main/jni/native_app_glue")}".toString()
>>         // CFlags    += 
>> "-I${file("src/main/jni/native_app_glue")}".toString()
>>         // CFlags    += 
>> "-I${file("src/main/jni/native_app_glue")}".toString()
>>
>>         ldLibs += ["android", "EGL", "GLESv2", "log"]
>>         stl = "stlport_static"
>>     }
>>
>>     android.sources {
>>         main {
>>             java {
>>                 source {
>>                     srcDirs 'src/main/java'
>>                 }
>>             }
>>             jni {
>>                 source {
>>                     srcDirs 'src/main/jni'
>>                 }
>>             }
>>         }
>>     }
>>
>>     android.productFlavors {
>>         create("arm7") {
>>             ndk.abiFilters += "armeabi-v7a"
>>         }
>>         create("arm8") {
>>             ndk.abiFilters += "arm64-v8a"
>>         }
>>         create("x86-32") {
>>             ndk.abiFilters += "x86"
>>         }
>>         // for detailed abiFilter descriptions, refer to "Supported ABIs" @
>>         // https://developer.android.com/ndk/guides/abis.html#sa
>>         // build one including all productFlavors
>>         create("all")
>>     }
>>
>>     android.buildTypes {
>>         release {
>>             isMinifyEnabled = false
>>             //proguardFiles += getDefaultProguardFile('proguard-android.txt')
>>             proguardFiles += file('proguard-rules.pro')
>>         }
>>     }
>> }
>>
>> dependencies {
>>     compile fileTree(dir: 'libs', include: ['*.jar'])
>>     compile 'com.android.support:appcompat-v7:22.2.0'
>>     //compile('com.crashlytics.sdk.android:crashlytics:2.4.0@aar') {
>>     //    transitive = true;
>>     //}
>> }
>>
>>
>> Error:(37, 27) libuvc/libuvc.h: No such file or directory - i had from 
>> studio errors, as you see the trouble is the header path is absence. I'm 
>> googling and found that standard android tools not supporting sets of 
>> header path. How can I resolve it ?
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"adt-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to