-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathbuild.gradle
87 lines (69 loc) · 2.03 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
buildscript {
repositories {
mavenCentral()
}
}
plugins {
id 'net.researchgate.release' version '2.4.1'
}
apply plugin: 'java'
apply plugin: 'eclipse'
apply plugin: 'osgi'
apply plugin: 'maven'
apply plugin: 'signing'
group = 'org.openmucextensions'
sourceCompatibility = 1.8
targetCompatibility = 1.8
// configure the release plugin
release {
git {
requireBranch = ''
}
}
repositories {
mavenLocal()
mavenCentral()
flatDir {
name 'additionalLibraries'
dirs rootDir.getAbsolutePath() + '/lib'
}
}
configurations.create('embed')
configurations.compile.extendsFrom configurations.embed
dependencies {
def openmucversion = '0.16.0'
compile group: 'org.osgi', name: 'osgi_R4_compendium', version: '1.0'
compile group: 'org.slf4j', name: 'slf4j-api', version: '1.7.21'
compile group: 'org.openmuc.framework', name: 'openmuc-core-spi', version: openmucversion
compile group: 'org.openmuc.framework', name: 'openmuc-core-api', version: openmucversion
compile group: 'com.google.code.gson', name: 'gson', version: '2.8.0'
compile 'org.apache.commons:commons-lang3:3.4'
embed group: 'com.serotonin', name: 'BACnet4J', version: '3.2.3-openmucextensions1'
embed group: 'com.google.code.gson', name: 'gson', version: '2.8.0'
embed 'org.apache.commons:commons-lang3:3.4'
testCompile group: 'junit', name: 'junit', version: '4.12'
// testCompile 'org.slf4j:slf4j-simple:1.7.12'
}
jar {
manifest {
name = "OpenMUC-Extensions Driver - BACnet"
instruction 'Bundle-ClassPath', '.'
configurations.embed.each { f ->
instruction 'Bundle-ClassPath', "lib/$f.name"
}
instruction 'Export-Package', ''
instruction 'Import-Package', '!com.serotonin*'
instruction 'Import-Package', '!org.apache.commons*'
instruction 'Import-Package', '!com.google.gson*'
instruction 'Import-Package', '*'
instruction 'Service-Component', 'OSGI-INF/components.xml'
}
}
jar {
into('lib') {
from configurations.embed
}
}
task wrapper(type: Wrapper) {
gradleVersion = '2.1'
}