3

I've 3 modules in my project:

Lib - apply plugin: 'com.android.library'
Proj A - apply plugin: 'com.android.application'
Proj B - apply plugin: 'com.android.application'

Both project inport the lib in their build.gradle file:
compile project(path: ':lib-module')

The settings.gradle imports it to:
include ':projectA-module', ':projectB-module', ':lib-module'

The gradle builds correctly, and I can import my lib classes inside my projects and navigate through the code. The only problem appears in compile time where I get this kind of errors showing that the lib classes and packages cannot be found:

Error:Gradle: Execution failed for task ':projectA-module:compileDebugJavaWithJavac'. Compilation failed; see the compiler error output for details. .../Class.java Error:(27, 42) Gradle: error: package com.mylib.somepackage does not exist

What's happening?

GuilhE
  • 10,723
  • 13
  • 63
  • 94

0 Answers0