Separate annotation processors and include in java as provided
Summary: With the current setup, the final aar contains `com.facebook.proguard.annotation.DoNotStrip`. This is not needed (it is only used for proguard), and thus should not get published. We move proguard annotations into its own project for this, and place it into `java/proguard-annotations`. Here we adopt the gradle convention of `src/main` to make for a nice, clean (one line!) gradle script. As a different subproject, we can include this to `:yoga` as a `provided` dependency now, which doesn't include it in the output artifact. Reviewed By: emilsjolander Differential Revision: D4666572 fbshipit-source-id: a0cb26cb6c264065a0bd355b7d72ba02e3759560
This commit is contained in:
committed by
Facebook Github Bot
parent
0405c4f77d
commit
1bf142e048
@@ -4,7 +4,7 @@ JAVA_TARGET = '//java:java'
|
||||
INFER_ANNOTATIONS_TARGET = '//lib/infer-annotations:infer-annotations'
|
||||
JSR_305_TARGET = '//lib/jsr-305:jsr-305'
|
||||
JUNIT_TARGET = '//lib/junit:junit'
|
||||
PROGRUARD_ANNOTATIONS_TARGET = '//java/com/facebook/proguard/annotations:annotations'
|
||||
PROGRUARD_ANNOTATIONS_TARGET = '//java/proguard-annotations/src/main/java/com/facebook/proguard/annotations:annotations'
|
||||
SOLOADER_TARGET = '//lib/soloader:soloader'
|
||||
GTEST_TARGET = '//lib/gtest:gtest'
|
||||
JNI_TARGET = '//lib/jni:jni'
|
||||
|
@@ -44,6 +44,7 @@ preBuild.dependsOn buckBuildAndCopy
|
||||
dependencies {
|
||||
compile(name: 'jsr305')
|
||||
compile(name: 'soloader-0.1.0', ext: 'aar')
|
||||
provided(project(':yoga:proguard-annotations'))
|
||||
}
|
||||
|
||||
task sourcesJar(type: Jar) {
|
||||
|
1
java/proguard-annotations/build.gradle
Normal file
1
java/proguard-annotations/build.gradle
Normal file
@@ -0,0 +1 @@
|
||||
apply plugin: 'java'
|
@@ -1,3 +1,4 @@
|
||||
include ':yoga', ':yoga-layout'
|
||||
include ':yoga', ':yoga-layout', ':yoga:proguard-annotations'
|
||||
project(':yoga').projectDir = file('java')
|
||||
project(':yoga:proguard-annotations').projectDir = file('java/proguard-annotations')
|
||||
project(':yoga-layout').projectDir = file('android')
|
||||
|
Reference in New Issue
Block a user