-
Notifications
You must be signed in to change notification settings - Fork 3
/
build.gradle
101 lines (84 loc) · 1.99 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
plugins {
id 'edu.sc.seis.launch4j' version '2.4.4'
}
apply plugin: 'java'
apply plugin: 'eclipse'
apply plugin: 'application'
archivesBaseName = "GOIN-ldjam42"
version = "v1.0.0"
targetCompatibility = "1.8.0"
mainClassName = "de.gurkenlabs.ldjam42.Program"
repositories {
mavenCentral()
}
dependencies {
compile project(':litiengine')
}
sourceSets {
main.java.srcDir "src"
main.resources.srcDirs = ["sprites", "audio", "maps", "misc"]
// main.resources.includes = ["game.litidata"]
}
jar {
from {
configurations.runtime.collect {
it.isDirectory() ? it : zipTree(it)
}
configurations.compile.collect {
it.isDirectory() ? it : zipTree(it)
}
} {
exclude 'META-INF/services/**'
}
// make sure to only include service providers from the litiengine when directly referencing the project
from ("${project(':litiengine').projectDir}/resources/") {
include 'META-INF/services/**'
}
from(sourceSets.main.allSource)
{
include '**/*'
}
exclude '**/*.dll'
exclude '**/*.jnilib'
exclude '**/*.dylib'
exclude '**/*.so'
exclude 'junit**/**'
from 'game.litidata'
manifest {
attributes 'Class-Path': ".",
'Main-Class': mainClassName
}
}
launch4j {
mainClassName = project.mainClassName
icon = 'game.ico'
outputDir = 'libs'
outfile = archivesBaseName +'.exe'
companyName = 'gurkenlabs.de'
version = '1.0.0'
textVersion = 'v1.0.0'
copyright = '2018 gurkenlabs.de'
bundledJrePath = 'jre'
jvmOptions = ['-Xms256m', '-Xmx1024m']
cmdLine = '-release'
}
task copyDistributionFiles(type: Copy) {
def buildFolder = new File(buildDir, 'libs')
from('litiengine/build/libs') {
include '**/*'
exclude '**/*.jar'
exclude '**/*.zip'
exclude 'LICENSE'
exclude 'lib/**'
}
from('dist'){
include 'game.ico'
include 'config.properties'
include 'jre/**'
}
into buildFolder
}
jar.dependsOn copyDistributionFiles
tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
}