java {
    sourceCompatibility = JavaVersion.VERSION_1_8
    targetCompatibility = JavaVersion.VERSION_1_8
}
sourceSets {
    demo {
        java {
            srcDirs = ["src/demo/kotlin"]
            compileClasspath += main.getCompileClasspath()
            runtimeClasspath += main.getRuntimeClasspath()
        }
    }
    wrapgen {
        java {
            srcDirs = ["src/wrapgen/kotlin"]
            compileClasspath += main.getCompileClasspath()
            runtimeClasspath += main.getRuntimeClasspath()
        }
    }
}

compileWrapgenKotlin {
    sourceCompatibility = JavaVersion.VERSION_1_8
    targetCompatibility = JavaVersion.VERSION_1_8

    kotlinOptions {
        jvmTarget = "1.8"
        apiVersion = "1.4"
        languageVersion = "1.4"
    }
}


dependencies {
    implementation "com.google.code.gson:gson:$gsonVersion"
    demoImplementation("org.openrndr:openrndr-application:$openrndrVersion")


    demoRuntimeOnly(project(":orx-jvm:orx-tensorflow-natives-$openrndrOS"))
    demoRuntimeOnly("org.openrndr:openrndr-gl3:$openrndrVersion")
    demoRuntimeOnly("org.openrndr:openrndr-gl3-natives-$openrndrOS:$openrndrVersion")
    demoRuntimeOnly("org.openrndr:openrndr-extensions:$openrndrVersion")
    demoImplementation("org.openrndr:openrndr-ffmpeg:$openrndrVersion")
    demoRuntimeOnly("org.openrndr:openrndr-ffmpeg-natives-$openrndrOS:$openrndrVersion")
    demoImplementation(project(":orx-fx"))
    demoImplementation(sourceSets.getByName("main").output)
    api("org.tensorflow:tensorflow-core-api:$tensorflowVersion")

    // -- wrapgen
    wrapgenImplementation 'com.github.javaparser:javaparser-core:3.15.21'
}


