1 2description = "PerfMark Java7 API" 3ext.moduleName = "io.perfmark.javaseven" 4ext.jdkVersion = JavaVersion.VERSION_1_7 5 6compileJava { 7 sourceCompatibility = jdkVersion 8 targetCompatibility = jdkVersion 9 10 options.compilerArgs.add("-Xlint:-options") 11} 12 13sourceSets { 14 jmh {} 15} 16 17 18compileJmhJava { 19 sourceCompatibility = JavaVersion.VERSION_11 20 targetCompatibility = JavaVersion.VERSION_11 21 javaCompiler = javaToolchains.compilerFor({ 22 languageVersion = JavaLanguageVersion.of("11") 23 }) 24 options.errorprone.excludedPaths.set(".*/build/generated/sources/annotationProcessor/.*") 25} 26 27dependencies { 28 implementation project(':perfmark-impl') 29 compileOnly libs.jsr305 30 31 jmhImplementation project(':perfmark-api'), 32 project(':perfmark-impl'), 33 project(':perfmark-java7'), 34 project(':perfmark-testing') 35 jmhImplementation libs.junit 36 jmhImplementation libs.jmhcore 37 jmhAnnotationProcessor libs.jmhanno 38} 39 40javadoc { 41 exclude 'io/perfmark/java7**' 42} 43 44jar { 45 exclude 'io/perfmark/java7/Internal*' 46} 47 48tasks.register('jmh', Test) { 49 description = 'Runs integration tests.' 50 group = 'stress' 51 52 testClassesDirs = sourceSets.jmh.output.classesDirs 53 classpath = sourceSets.jmh.runtimeClasspath 54 55 javaLauncher = javaToolchains.launcherFor({ 56 languageVersion = JavaLanguageVersion.of("16") 57 }) 58 //shouldRunAfter test 59}