diff options
author | Xavier Ducrohet <xav@google.com> | 2015-02-13 00:34:54 +0000 |
---|---|---|
committer | android-build-merger <android-build-merger@google.com> | 2015-02-13 00:34:54 +0000 |
commit | 3b7b0b509b4077688f38f3eab3e80e0db19dc643 (patch) | |
tree | 6015ffd3940dedacfbaa33ad0a0165358bf35785 | |
parent | 95fc7621288e7bd695b41a8b0c4ec589d94c86d8 (diff) | |
parent | 2c0581045e20439c54ff5aec76681e4429389f8b (diff) | |
download | sdk-3b7b0b509b4077688f38f3eab3e80e0db19dc643.zip sdk-3b7b0b509b4077688f38f3eab3e80e0db19dc643.tar.gz sdk-3b7b0b509b4077688f38f3eab3e80e0db19dc643.tar.bz2 |
Merge "Revert "Add targetPlatform for executable binaries"" into studio-1.2-dev
automerge: 2c05810
* commit '2c0581045e20439c54ff5aec76681e4429389f8b':
Revert "Add targetPlatform for executable binaries"
-rw-r--r-- | avdlauncher/build.gradle | 30 | ||||
-rw-r--r-- | emulator/mksdcard/build.gradle | 28 | ||||
-rw-r--r-- | find_java/build.gradle | 27 | ||||
-rw-r--r-- | sdklauncher/build.gradle | 30 |
4 files changed, 60 insertions, 55 deletions
diff --git a/avdlauncher/build.gradle b/avdlauncher/build.gradle index b0e2c90..c280642 100644 --- a/avdlauncher/build.gradle +++ b/avdlauncher/build.gradle @@ -2,33 +2,35 @@ apply plugin: 'c' apply plugin: 'sdk-files' apply plugin: 'windows-setup' -model { - components { - avdLauncher(NativeExecutableSpec) { - sources { - c { - source { - srcDir "src/source" - include "**/*.c" - } - } +executables { + avdLauncher {} +} + +sources { + avdLauncher { + c { + source { + srcDir "src/source" + include "**/*.c" } - targetPlatform "windows32" } } } sdk { windows { - item( { getExeName("avdLauncherExecutable") } ) { + item( { getExeName("windows32AvdLauncherExecutable") } ) { into 'lib' name 'AVD Manager.exe' - builtBy 'avdLauncherExecutable' + builtBy 'windows32AvdLauncherExecutable' } } } def getExeName(String name) { - return binaries.getByName(name).executableFile + // binaries will return a set of binaries + def binaries = executables.avdLauncher.binaries.matching { it.name == name } + // calling .exeFile on the set returns an array with the result from each item in the set... + return binaries.executableFile.get(0) } diff --git a/emulator/mksdcard/build.gradle b/emulator/mksdcard/build.gradle index bd029b2..677f763 100644 --- a/emulator/mksdcard/build.gradle +++ b/emulator/mksdcard/build.gradle @@ -2,20 +2,17 @@ apply plugin: 'c' apply plugin: 'sdk-files' apply plugin: 'native-setup' -model { - components { - mksdcard(NativeExecutableSpec) { - sources { - c { - source { - srcDir "src/source" - include "**/*.c" - } - } +executables { + mksdcard {} +} + +sources { + mksdcard { + c { + source { + srcDir "src/source" + include "**/*.c" } - targetPlatform "darwin" - targetPlatform "linux" - targetPlatform "windows32" } } } @@ -46,6 +43,9 @@ sdk { } def getExeName(String platform) { - return binaries.getByName("${platform}MksdcardExecutable").executableFile + // binaries will return a set of binaries + def binaries = executables.mksdcard.binaries.matching { it.name == "${platform}MksdcardExecutable" } + // calling .exeFile on the set returns an array with the result from each item in the set... + return binaries.executableFile.get(0) } diff --git a/find_java/build.gradle b/find_java/build.gradle index 8c1ed43..b359e0a 100644 --- a/find_java/build.gradle +++ b/find_java/build.gradle @@ -2,19 +2,17 @@ apply plugin: 'cpp' apply plugin: 'sdk-files' apply plugin: 'windows-setup' -model { - components { - findJava(NativeExecutableSpec) { - sources { - cpp { - source { - srcDir "src/source" - include "**/*.cpp" - } - } +executables { + findJava {} +} + +sources { + findJava { + cpp { + source { + srcDir "src/source" + include "**/*.cpp" } - targetPlatform "windows32" - targetPlatform "windows64" } } } @@ -41,6 +39,9 @@ sdk { } def getExeName(String name) { - return binaries.getByName(name).executableFile + // binaries will return a set of binaries + def binaries = executables.findJava.binaries.matching { it.name == name } + // calling .exeFile on the set returns an array with the result from each item in the set... + return binaries.executableFile.get(0) } diff --git a/sdklauncher/build.gradle b/sdklauncher/build.gradle index b04ee05..6c64f6d 100644 --- a/sdklauncher/build.gradle +++ b/sdklauncher/build.gradle @@ -2,33 +2,35 @@ apply plugin: 'c' apply plugin: 'sdk-files' apply plugin: 'windows-setup' -model { - components { - sdkLauncher(NativeExecutableSpec) { - sources { - c { - source { - srcDir "src/source" - include "**/*.c" - } - } +executables { + sdkLauncher {} +} + +sources { + sdkLauncher { + c { + source { + srcDir "src/source" + include "**/*.c" } - targetPlatform "windows32" } } } sdk { windows { - item( { getExeName("sdkLauncherExecutable") } ) { + item( { getExeName("windows32SdkLauncherExecutable") } ) { into 'lib' name 'SDK Manager.exe' - builtBy 'sdkLauncherExecutable' + builtBy 'windows32SdkLauncherExecutable' } } } def getExeName(String name) { - return binaries.getByName(name).executableFile + // binaries will return a set of binaries + def binaries = executables.sdkLauncher.binaries.matching { it.name == name } + // calling .exeFile on the set returns an array with the result from each item in the set... + return binaries.executableFile.get(0) } |