-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathbuild.gradle
101 lines (80 loc) · 2.55 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
import org.gradle.internal.os.OperatingSystem
apply plugin: 'java'
apply plugin: 'kotlin'
// jitpack
apply plugin: 'maven'
group = 'com.github.kotlin-graphics'
apply plugin: 'com.github.johnrengelman.shadow'
//compileKotlin {
// kotlinOptions {
// jvmTarget = '1.8'
// }
//}
allprojects {
apply plugin: 'java'
sourceCompatibility = 1.8
targetCompatibility = 1.8
apply plugin: 'kotlin'
compileKotlin {
kotlinOptions.jvmTarget = '1.8'
}
}
buildscript {
ext.kotlinVersion = '1.3.0-rc-190'
repositories {
jcenter() // shadow
mavenCentral()
maven { url = 'https://dl.bintray.com/kotlin/kotlin-eap' }
maven { setUrl("https://oss.sonatype.org/content/repositories/snapshots/") }
}
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion"
classpath 'com.github.jengelman.gradle.plugins:shadow:2.0.4'
}
}
dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlinVersion"
ext.kx = 'com.github.kotlin-graphics'
implementation "$kx:assimp:5fe308639a90204dba4bf129386b2b8d430b6a2e"
implementation "$kx:imgui:a715971ed30b51d9c092d3713db283807eb99462"
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-core:1.0.0-RC1"
testCompile 'io.kotlintest:kotlintest:2.0.7'
ext.lwjglVersion = "3.2.1-SNAPSHOT"
switch (OperatingSystem.current()) {
case OperatingSystem.WINDOWS:
ext.lwjglNatives = "natives-windows"
break
case OperatingSystem.LINUX:
ext.lwjglNatives = "natives-linux"
break
case OperatingSystem.MAC_OS:
ext.lwjglNatives = "natives-macos"
break
}
["", "-glfw", "-jemalloc", "-openal", "-opengl", "-stb", "-vulkan"].each {
implementation "org.lwjgl:lwjgl$it:$lwjglVersion"
runtime "org.lwjgl:lwjgl$it:$lwjglVersion:$lwjglNatives"
}
ext.spirvCross = "graphics.scenery:spirvcrossj:0.4.1"
implementation spirvCross
runtime "$spirvCross:$lwjglNatives"
}
repositories {
mavenCentral()
jcenter()
maven { setUrl("https://dl.bintray.com/kotlin/kotlin-eap") }
maven { setUrl("https://oss.sonatype.org/content/repositories/snapshots/") }
maven { setUrl('https://jitpack.io') }
}
task sourcesJar(type: Jar, dependsOn: classes) {
classifier = 'sources'
from sourceSets.main.allSource
}
task javadocJar(type: Jar, dependsOn: javadoc) {
classifier = 'javadoc'
from javadoc.destinationDir
}
artifacts {
archives sourcesJar
archives javadocJar
}