2019-01-29 11:08:21 +00:00
|
|
|
plugins {
|
|
|
|
id 'antlr'
|
|
|
|
id 'java'
|
|
|
|
}
|
|
|
|
|
|
|
|
repositories {
|
|
|
|
mavenCentral()
|
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
2019-03-02 21:41:21 +00:00
|
|
|
antlr('org.antlr:antlr4:4.7.2') {
|
|
|
|
exclude group: 'com.ibm.icu', module: 'icu4j'
|
|
|
|
}
|
2019-01-29 11:08:21 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
compileJava {
|
|
|
|
dependsOn tasks.withType(AntlrTask)
|
|
|
|
}
|
|
|
|
|
|
|
|
generateGrammarSource {
|
|
|
|
outputDirectory = file("src/prog8/parser")
|
|
|
|
arguments += ["-no-listener","-no-visitor"]
|
|
|
|
}
|
2019-01-29 11:09:39 +00:00
|
|
|
|
2019-01-29 11:09:18 +00:00
|
|
|
sourceSets {
|
|
|
|
main {
|
|
|
|
java {
|
|
|
|
srcDirs = ["${project.projectDir}/src"]
|
|
|
|
}
|
2019-01-29 11:09:39 +00:00
|
|
|
antlr {
|
|
|
|
srcDirs = ["${project.projectDir}/antlr"]
|
|
|
|
}
|
2019-01-29 11:09:18 +00:00
|
|
|
}
|
2019-03-02 21:41:21 +00:00
|
|
|
}
|