| apply plugin: 'cpp' |
| apply plugin: 'sdk-files' |
| apply plugin: 'windows-setup' |
| |
| model { |
| components { |
| findJava(NativeExecutableSpec) { |
| sources { |
| cpp { |
| source { |
| srcDir "src/source" |
| include "**/*.cpp" |
| } |
| } |
| } |
| targetPlatform "windows32" |
| targetPlatform "windows64" |
| } |
| } |
| } |
| |
| sdk { |
| windows { |
| item( { getExeName("windows32FindJavaExecutable") } ) { |
| into 'lib' |
| name 'find_java32.exe' |
| builtBy 'windows32FindJavaExecutable' |
| notice 'NOTICE' |
| } |
| item( { getExeName("windows64FindJavaExecutable") } ) { |
| into 'lib' |
| name 'find_java64.exe' |
| builtBy 'windows64FindJavaExecutable' |
| notice 'NOTICE' |
| } |
| item('find_java.bat') { |
| into 'lib' |
| notice 'NOTICE' |
| } |
| } |
| } |
| |
| def getExeName(String name) { |
| return binaries.getByName(name).executableFile |
| } |
| |