Android new build system (gradle) and aspectj

后端 未结 5 529
再見小時候
再見小時候 2021-01-31 20:30

In Google IO the new build system gradle is announced to replace ant. My project is using aspectj and I would like to use it in my project. I couldn\'t figure out some variabl

5条回答
  •  既然无缘
    2021-01-31 21:17

    In the case of using Android Studio 0.8 or above, it seems that using gradle 0.12.+ is necessary.

    In gradle 0.12.+, exploded aar are extracted in the build folder, not in the exploded-aar folder.

    Therefore, in order to handle aar dependencies, you must use this code:

    tree = fileTree(dir: "${project.buildDir}", include: '**/classes.jar')
    tree.each { jarFile ->
        iajcClasspath += ":" + jarFile
    }
    

提交回复
热议问题