Closed binbowang1987 closed 2 years ago
By reviewing the build log, it looks like task javacppBuildCompiler$variantName
is not executed. I don't know why, please help me, thank you.
Executing tasks: [:app:assembleDebug] in project E:\develop\android\sample-projects\gradle-javacpp-android
> Task :app:preBuild UP-TO-DATE
> Task :app:preDebugBuild UP-TO-DATE
> Task :app:mergeDebugNativeDebugMetadata NO-SOURCE
> Task :app:compileDebugAidl NO-SOURCE
> Task :app:compileDebugRenderscript NO-SOURCE
> Task :app:generateDebugBuildConfig UP-TO-DATE
> Task :app:javaPreCompileDebug UP-TO-DATE
> Task :app:checkDebugAarMetadata UP-TO-DATE
> Task :app:generateDebugResValues UP-TO-DATE
> Task :app:generateDebugResources UP-TO-DATE
> Task :app:mergeDebugResources UP-TO-DATE
> Task :app:createDebugCompatibleScreenManifests UP-TO-DATE
> Task :app:extractDeepLinksDebug UP-TO-DATE
> Task :app:processDebugMainManifest UP-TO-DATE
> Task :app:processDebugManifest UP-TO-DATE
> Task :app:processDebugManifestForPackage UP-TO-DATE
> Task :app:processDebugResources UP-TO-DATE
> Task :app:javacppCompileJavaDebug
Hello World javacppCompileJava
> Task :app:javacppBuildParserDebug
Hello World javacppBuildParser
> Task :app:compileDebugJavaWithJavac
E:\develop\android\sample-projects\gradle-javacpp-android\app\src\main\java\com\example\myapplication\NativeLibrary.java:27: warning: [unchecked] position(long) in NativeClass overrides <P>position(long) in Pointer
@Override public NativeClass position(long position) {
^
return type requires unchecked conversion from NativeClass to P
where P is a type-variable:
P extends Pointer declared in method <P>position(long)
E:\develop\android\sample-projects\gradle-javacpp-android\app\src\main\java\com\example\myapplication\NativeLibrary.java:30: warning: [unchecked] getPointer(long) in NativeClass overrides <P>getPointer(long) in Pointer
@Override public NativeClass getPointer(long i) {
^
return type requires unchecked conversion from NativeClass to P
where P is a type-variable:
P extends Pointer declared in method <P>getPointer(long)
2 warnings
> Task :app:mergeDebugShaders UP-TO-DATE
> Task :app:compileDebugShaders NO-SOURCE
> Task :app:generateDebugAssets UP-TO-DATE
> Task :app:mergeDebugAssets UP-TO-DATE
> Task :app:compressDebugAssets UP-TO-DATE
> Task :app:processDebugJavaRes NO-SOURCE
> Task :app:mergeDebugJavaResource UP-TO-DATE
> Task :app:checkDebugDuplicateClasses UP-TO-DATE
> Task :app:desugarDebugFileDependencies UP-TO-DATE
> Task :app:mergeExtDexDebug UP-TO-DATE
> Task :app:mergeLibDexDebug UP-TO-DATE
> Task :app:dexBuilderDebug
> Task :app:configureCMakeDebug[arm64-v8a]
> Task :app:mergeProjectDexDebug
> Task :app:buildCMakeDebug[arm64-v8a]
> Task :app:configureCMakeDebug[armeabi-v7a]
> Task :app:buildCMakeDebug[armeabi-v7a]
> Task :app:configureCMakeDebug[x86]
> Task :app:buildCMakeDebug[x86]
> Task :app:configureCMakeDebug[x86_64]
> Task :app:buildCMakeDebug[x86_64]
> Task :app:externalNativeBuildDebug
> Task :app:mergeDebugJniLibFolders UP-TO-DATE
> Task :app:mergeDebugNativeLibs UP-TO-DATE
> Task :app:stripDebugDebugSymbols UP-TO-DATE
> Task :app:validateSigningDebug UP-TO-DATE
> Task :app:writeDebugAppMetadata UP-TO-DATE
> Task :app:writeDebugSigningConfigVersions UP-TO-DATE
> Task :app:packageDebug
> Task :app:createDebugApkListingFileRedirect UP-TO-DATE
> Task :app:assembleDebug
Deprecated Gradle features were used in this build, making it incompatible with Gradle 8.0.
You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.
See https://docs.gradle.org/7.2/userguide/command_line_interface.html#sec:command_line_warnings
BUILD SUCCESSFUL in 1s
41 actionable tasks: 15 executed, 26 up-to-date
Build Analyzer results available
Please update the task names as per issue #22.
Duplicate of #22
I am refrencing gradle-javacpp-android to use javacpp with android studio. After a bit adjust to
gradle-javacpp-android
, it successfully generatedNativeLibrary
. Butjnijavacpp.cpp
andjniNativeLibrary.cpp
are not generated.