blob: 10939f68d110c7ed89f311acdfad8907a63426d5 [file] [log] [blame]
Xavier Ducrohet57079352014-01-15 13:47:45 -08001// this applied only to swt/* projects
Raphael Molle2290872013-02-07 13:14:54 -08002subprojects { Project project ->
Xavier Ducrohet57079352014-01-15 13:47:45 -08003 // only configure leaf projects.
4 if (!project.getSubprojects().isEmpty()) return
Raphael Moll2e919cd2013-01-09 17:56:11 -08005
Xavier Ducrohet387a74f2014-05-15 13:26:27 -07006 apply from: "$rootDir/buildSrc/base/baseJava.gradle"
Xavier Ducrohet92378202014-01-23 11:56:56 -08007 apply plugin: 'sdk-java-lib'
Xavier Ducrohet314ab272013-03-07 14:12:14 -08008
Xavier Ducrohetc62de922014-05-21 18:43:20 -07009 version = rootProject.ext.baseVersion
10
Xavier Ducrohet314ab272013-03-07 14:12:14 -080011 // configuration for swt dependency since the packaged jar is platform dependent
12 // but at compile time we don't care. Also we don't want the artifact in the
13 // main repo, so use the provided configuration
14 configurations {
15 swt
16 }
17
18 dependencies{
19 swt "com.android.external.eclipse:swt:3.5.0"
Raphael Moll8029da52013-03-07 13:40:07 -080020 compile 'com.android.external.eclipse:org-eclipse-jface:3.6.2'
Xavier Ducrohet2420d7f2013-03-08 17:07:25 -080021 testCompile "com.android.external.eclipse:swt:3.5.0"
Xavier Ducrohet314ab272013-03-07 14:12:14 -080022 }
23
Xavier Ducrohet61cc9d12013-03-08 14:45:18 -080024 // include swt for compilation
25 sourceSets.main.compileClasspath += configurations.swt
Raphael Moll2e919cd2013-01-09 17:56:11 -080026}
Xavier Ducrohetecb08c42014-02-04 19:16:51 -080027
28apply plugin: 'sdk-files'
29
30sdk {
31 linux {
Xavier Ducrohet2a765072014-05-19 18:36:02 -070032 item("$rootProject.projectDir.parentFile/prebuilts/tools/linux-x86/swt/swt.jar") {
33 into 'lib/x86'
34 notice "$rootProject.projectDir.parentFile/prebuilts/tools/linux-x86/swt/NOTICE"
35 }
36 item("$rootProject.projectDir.parentFile/prebuilts/tools/linux-x86_64/swt/swt.jar") {
37 into 'lib/x86_64'
38 notice "$rootProject.projectDir.parentFile/prebuilts/tools/linux-x86_64/swt/NOTICE"
39 }
Xavier Ducrohetecb08c42014-02-04 19:16:51 -080040 }
41 mac {
Xavier Ducrohet2a765072014-05-19 18:36:02 -070042 item("$rootProject.projectDir.parentFile/prebuilts/tools/darwin-x86/swt/swt.jar") {
43 into 'lib/x86'
44 notice "$rootProject.projectDir.parentFile/prebuilts/tools/darwin-x86/swt/NOTICE"
45 }
46 item("$rootProject.projectDir.parentFile/prebuilts/tools/darwin-x86_64/swt/swt.jar") {
47 into 'lib/x86_64'
48 notice "$rootProject.projectDir.parentFile/prebuilts/tools/darwin-x86_64/swt/NOTICE"
49 }
Xavier Ducrohetecb08c42014-02-04 19:16:51 -080050 }
51 windows {
Xavier Ducrohet2a765072014-05-19 18:36:02 -070052 item("$rootProject.projectDir.parentFile/prebuilts/tools/windows/swt/swt.jar") {
53 into 'lib/x86'
54 notice "$rootProject.projectDir.parentFile/prebuilts/tools/windows/swt/NOTICE"
55 }
56 item("$rootProject.projectDir.parentFile/prebuilts/tools/windows-x86_64/swt/swt.jar") {
57 into 'lib/x86_64'
58 notice "$rootProject.projectDir.parentFile/prebuilts/tools/windows-x86_64/swt/NOTICE"
59 }
Xavier Ducrohetecb08c42014-02-04 19:16:51 -080060 }
61}