initial version of compiler and parser gradle module

This commit is contained in:
Ferenc Boldog 2019-01-29 12:08:21 +01:00
parent b3df3c999d
commit de777b1308
3 changed files with 44 additions and 0 deletions

21
compiler/build.gradle Normal file
View File

@ -0,0 +1,21 @@
plugins {
id "org.jetbrains.kotlin.jvm" version "1.3.20"
}
repositories {
mavenCentral()
jcenter()
}
def kotlinVersion = '1.3.20'
dependencies {
implementation project(':parser')
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlinVersion"
runtime "org.jetbrains.kotlin:kotlin-reflect:$kotlinVersion"
testImplementation "org.jetbrains.kotlin:kotlin-test-junit5:$kotlinVersion"
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.3.2'
testImplementation 'org.hamcrest:hamcrest-junit:2.0.0.0'
}

21
parser/build.gradle Normal file
View File

@ -0,0 +1,21 @@
plugins {
id 'antlr'
id 'java'
}
repositories {
mavenCentral()
}
dependencies {
antlr 'org.antlr:antlr4:4.7.2'
}
compileJava {
dependsOn tasks.withType(AntlrTask)
}
generateGrammarSource {
outputDirectory = file("src/prog8/parser")
arguments += ["-no-listener","-no-visitor"]
}

2
settings.gradle Normal file
View File

@ -0,0 +1,2 @@
include ':parser'
include ':compiler'