blob: 73185ba35340ff2a87ac0148d2d0d5c8495226e3 [file] [log] [blame]
Brian Silverman8fce7482020-01-05 13:18:21 -08001apply plugin: 'java'
2
3ext {
4 useJava = true
5 useCpp = false
6 skipDev = true
7}
8
9apply from: "${rootDir}/shared/opencv.gradle"
10
11
12
13dependencies {
14 implementation project(':wpilibj')
15
Austin Schuh1e69f942020-11-14 15:06:14 -080016 implementation project(':wpimath')
Brian Silverman8fce7482020-01-05 13:18:21 -080017 implementation project(':hal')
18 implementation project(':wpiutil')
19 implementation project(':ntcore')
20 implementation project(':cscore')
21 implementation project(':cameraserver')
22 implementation project(':wpilibOldCommands')
23 implementation project(':wpilibNewCommands')
24}
25
26if (!project.hasProperty('skipPMD')) {
27 apply plugin: 'pmd'
28
29 pmd {
30 consoleOutput = true
31 reportsDir = file("$project.buildDir/reports/pmd")
32 ruleSetFiles = files(new File(rootDir, "styleguide/pmd-ruleset.xml"))
33 ruleSets = []
34 }
35}
36
37gradle.projectsEvaluated {
38 tasks.withType(JavaCompile) {
39 options.compilerArgs << "-Xlint:unchecked" << "-Xlint:deprecation" << "-Werror"
40 }
41}
42
43tasks.register('buildDesktopJava') {
44 it.dependsOn tasks.withType(JavaCompile)
45}
46
47apply from: 'publish.gradle'
48
49ext {
50 templateDirectory = new File("$projectDir/src/main/java/edu/wpi/first/wpilibj/templates/")
51 templateFile = new File("$projectDir/src/main/java/edu/wpi/first/wpilibj/templates/templates.json")
52 exampleDirectory = new File("$projectDir/src/main/java/edu/wpi/first/wpilibj/examples/")
53 exampleFile = new File("$projectDir/src/main/java/edu/wpi/first/wpilibj/examples/examples.json")
54 commandDirectory = new File("$projectDir/src/main/java/edu/wpi/first/wpilibj/commands/")
55 commandFile = new File("$projectDir/src/main/java/edu/wpi/first/wpilibj/commands/commands.json")
56}
57
58ext {
59 isCppCommands = false
60}
61apply from: "${rootDir}/shared/examplecheck.gradle"