It's very pleasant to see Google finally release this.

First it's still quite sad that there is no mechanism to use older library 
builds with pre-existing .mk files.  I get around this as I always have by 
creating own task that calls ndk-build.

Anyway, something I wanted to point out: 
 http://tools.android.com/tech-docs/new-build-system/gradle-experimental 
says as an example to use toolchainVersion = 3.4 for clang and r10e for the 
ndk is required.  There is no 3.4 toolchain version of clang in r10e.

Next, should mention that if users wish to use more than one srcDir for 
jni, use the srcDirs property and an arrayList. (i.e. 
android.sources {
        main {
            jni {
                source {
                    srcDirs = [file('../../Android').absolutePath, 
file('../../../Common').absolutePath ]
                }
            }
        }
    }

Also, apply plugin: 'com.android.model.library' should be somewhere in 
there as an option in the docs.

CFlags and cppFlags have very similar oddities:
cppFlags += " -I" + file('../../../Common').absolutePath
will result in compiler errors that the file or directory <path>/Common is 
not found and it wont compile.  However, remove the space prior to the -I 
flag and it's all good.  I had to remove all spaces on front and back of 
all cflags and do a separate flag per line with cppFlags += <newFlag>

I can get gradlew to run the compiler, but the GUI doesn't actually run the 
ndk build task.  If I run the gradle task from the GUI :app:build then it 
does build the ndk build task but F9 gives me everything but.

armeabi-v7 should be armeabi-v7a

android.buildTypes { } should include isDebuggable = true and 
isJniDebuggable = true.

For the life of me I couldn't get cppFlags += 
"-DVERSION=\"${rootProject.getVersion().toString()}\"" to work.  Am I doing 
something wrong with it?

splits should now be android.splits <-- not listed.  It would be nice to 
have a better way of defining abiFilters to only include what's asked for 
(i.e. set universalAPK to false elsewhere).  Also should note that setting 
abiFilters has no barring on what will be compiled.  The NDK will try to 
compile all abiFilters no matter what.

That's as far as I could test.  Going back to deprecated ndk scheme until 
the next version.  Thought I'd give feedback.

-- 
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