./build.gradle

Print this page

        

*** 1729,1739 **** exe = true; linkerOptions.addAll(WIN.launcher.linkFlags); doLast { copy { from "$buildDir/native/WinLauncher/WinLauncher.exe" ! into "$buildDir/classes/main/com/sun/javafx/tools/resource/windows" } } } task compileWinLauncherSvc(type: CCTask, group: "Build") { description = "Compiles native sources for the application co-bundle launcher"; --- 1729,1739 ---- exe = true; linkerOptions.addAll(WIN.launcher.linkFlags); doLast { copy { from "$buildDir/native/WinLauncher/WinLauncher.exe" ! into "$buildDir/classes/main/com/oracle/tools/packager/windows" } } } task compileWinLauncherSvc(type: CCTask, group: "Build") { description = "Compiles native sources for the application co-bundle launcher";
*** 1745,1755 **** exe = true; linkerOptions.addAll(WIN.launcher.linkFlags); doLast { copy { from "$buildDir/native/WinLauncherSvc/WinLauncherSvc.exe" ! into "$buildDir/classes/main/com/sun/javafx/tools/resource/windows" } } } task compileIconSwap(type: CCTask, group: "Build") { description = "Compiles native sources for the application co-bundle launcher" --- 1745,1755 ---- exe = true; linkerOptions.addAll(WIN.launcher.linkFlags); doLast { copy { from "$buildDir/native/WinLauncherSvc/WinLauncherSvc.exe" ! into "$buildDir/classes/main/com/oracle/tools/packager/windows" } } } task compileIconSwap(type: CCTask, group: "Build") { description = "Compiles native sources for the application co-bundle launcher"
*** 1761,1782 **** exe = true linkerOptions.addAll(WIN.iconLauncher.linkFlags) doLast { copy { from "$buildDir/native/IconSwap/IconSwap.exe" ! into "$buildDir/classes/main/com/sun/javafx/tools/resource/windows" } } } task compileLauncher(dependsOn: [compileWinLauncher, compileWinLauncherSvc, compileIconSwap]) jar.dependsOn compileLauncher; } else if (COMPILE_FXPACKAGER) { if (IS_MAC) { task compileLauncher(type: CCTask, group: "Build") { description = "Compiles native sources for the application co-bundle launcher" matches = ".*\\.m" ! output(file("$buildDir/classes/main/com/sun/javafx/tools/resource/mac")) params.addAll(MAC.launcher.ccFlags) source file("src/main/native/launcher/mac") compiler = MAC.launcher.compiler eachOutputFile = { f -> return new File(f.getParent(), "JavaAppLauncher") --- 1761,1782 ---- exe = true linkerOptions.addAll(WIN.iconLauncher.linkFlags) doLast { copy { from "$buildDir/native/IconSwap/IconSwap.exe" ! into "$buildDir/classes/main/com/oracle/tools/packager/windows" } } } task compileLauncher(dependsOn: [compileWinLauncher, compileWinLauncherSvc, compileIconSwap]) jar.dependsOn compileLauncher; } else if (COMPILE_FXPACKAGER) { if (IS_MAC) { task compileLauncher(type: CCTask, group: "Build") { description = "Compiles native sources for the application co-bundle launcher" matches = ".*\\.m" ! output(file("$buildDir/classes/main/com/oracle/tools/packager/mac")) params.addAll(MAC.launcher.ccFlags) source file("src/main/native/launcher/mac") compiler = MAC.launcher.compiler eachOutputFile = { f -> return new File(f.getParent(), "JavaAppLauncher")
*** 1795,1878 **** def linkTask = project.task("linkLauncher", type: LinkTask, dependsOn: ccTask, group: "Build") { description = "Creates native dynamic library for the application co-bundle launcher" linker = LINUX.launcher.linker linkParams.addAll(LINUX.launcher.linkFlags) objectDir = file("$buildDir/native/launcher") ! lib = file("$buildDir/classes/main/com/sun/javafx/tools/resource/linux/JavaAppLauncher") } jar.dependsOn linkTask; } } ! // Builds the javafxpackager executable. For everything other than windows, // this is simply moving the existing shell script and ensuring it has proper // permissions. For Windows, this includes compiling the native executable if (IS_WINDOWS && COMPILE_FXPACKAGER){ ! task buildJavaFXPackager(type: CCTask, group: "Build") { ! description = "Compiles native sources for javafxpackager.exe" ! matches = "javafxpackager\\.cpp" params.addAll(WIN.fxpackager.ccFlags) compiler = WIN.fxpackager.compiler ! output(file("$buildDir/native/javafxpackager")) source WIN.fxpackager.nativeSource doFirst { copy { mkdir "$buildDir/native" ! mkdir "$buildDir/native/javafxpackager" ! from file("src/main/native/javafxpackager/win/javafxpackager.manifest") ! into file("$buildDir/native/javafxpackager") filter { line-> line = line.replace("FXVERSION", "${RAW_VERSION}.${HUDSON_BUILD_NUMBER}"); } } } doLast { mkdir "$buildDir/native" exec({ commandLine("$RC", "/nologo", "/l", "0x409", "/r", "/dJFX_DVERSION=8", "/dJFX_VERSION=8", ! "/fo$buildDir/native/javafxpackager/javafxpackager.res", ! "src/main/native/javafxpackager/win/javafxpackager.rc"); environment(WINDOWS_NATIVE_COMPILE_ENVIRONMENT); }); } doLast { ! mkdir "$buildDir/javafxpackager" exec({ commandLine("$WIN.fxpackager.linker", "/nologo", "/opt:REF", "/incremental:no", "/manifest", "kernel32.lib", "advapi32.lib", ! "/out:$buildDir/native/javafxpackager/javafxpackager.exe", ! "$buildDir/native/javafxpackager/javafxpackager.obj", ! "$buildDir/native/javafxpackager/javafxpackager.res") environment(WINDOWS_NATIVE_COMPILE_ENVIRONMENT) }) } doLast { exec({ commandLine("$MC", "-manifest", ! "$buildDir/native/javafxpackager/javafxpackager.manifest", ! "-outputresource:$buildDir/native/javafxpackager/javafxpackager.exe") environment(WINDOWS_NATIVE_COMPILE_ENVIRONMENT) }) copy { ! from file("$buildDir/native/javafxpackager/javafxpackager.exe") ! into file("$buildDir/javafxpackager") } } } } else { ! task buildJavaFXPackager(group: "Build") { enabled = COMPILE_FXPACKAGER doLast { copy { ! from "src/main/native/javafxpackager/shell" ! into "$buildDir/javafxpackager" fileMode = 0755 } } } } ! jar.dependsOn buildJavaFXPackager classes << { // Copy all of the download libraries to libs directory for the sake of the IDEs File libsDir = rootProject.file("build/libs"); File antLib = new File(libsDir, "ant-1.8.2.jar") --- 1795,1889 ---- def linkTask = project.task("linkLauncher", type: LinkTask, dependsOn: ccTask, group: "Build") { description = "Creates native dynamic library for the application co-bundle launcher" linker = LINUX.launcher.linker linkParams.addAll(LINUX.launcher.linkFlags) objectDir = file("$buildDir/native/launcher") ! lib = file("$buildDir/classes/main/com/oracle/tools/packager/linux/JavaAppLauncher") } jar.dependsOn linkTask; } } ! // Builds the javapackager executable. For everything other than windows, // this is simply moving the existing shell script and ensuring it has proper // permissions. For Windows, this includes compiling the native executable if (IS_WINDOWS && COMPILE_FXPACKAGER){ ! task buildJavaPackager(type: CCTask, group: "Build") { ! description = "Compiles native sources for javapackager.exe" ! matches = "javapackager\\.cpp" params.addAll(WIN.fxpackager.ccFlags) compiler = WIN.fxpackager.compiler ! output(file("$buildDir/native/javapackager")) source WIN.fxpackager.nativeSource doFirst { copy { mkdir "$buildDir/native" ! mkdir "$buildDir/native/javapackager" ! from file("src/main/native/javapackager/win/javapackager.manifest") ! into file("$buildDir/native/javapackager") filter { line-> line = line.replace("FXVERSION", "${RAW_VERSION}.${HUDSON_BUILD_NUMBER}"); } } } doLast { mkdir "$buildDir/native" exec({ commandLine("$RC", "/nologo", "/l", "0x409", "/r", "/dJFX_DVERSION=8", "/dJFX_VERSION=8", ! "/fo$buildDir/native/javapackager/javapackager.res", ! "src/main/native/javapackager/win/javapackager.rc"); environment(WINDOWS_NATIVE_COMPILE_ENVIRONMENT); }); } doLast { ! mkdir "$buildDir/javapackager" exec({ commandLine("$WIN.fxpackager.linker", "/nologo", "/opt:REF", "/incremental:no", "/manifest", "kernel32.lib", "advapi32.lib", ! "/out:$buildDir/native/javapackager/javapackager.exe", ! "$buildDir/native/javapackager/javapackager.obj", ! "$buildDir/native/javapackager/javapackager.res") environment(WINDOWS_NATIVE_COMPILE_ENVIRONMENT) }) } doLast { exec({ commandLine("$MC", "-manifest", ! "$buildDir/native/javapackager/javapackager.manifest", ! "-outputresource:$buildDir/native/javapackager/javapackager.exe") environment(WINDOWS_NATIVE_COMPILE_ENVIRONMENT) }) copy { ! from file("$buildDir/native/javapackager/javapackager.exe") ! into file("$buildDir/javapackager") ! } ! copy { ! from file("$buildDir/native/javapackager/javapackager.exe") ! into file("$buildDir/javapackager") ! rename ('javapackager', 'javafxpackager') } } } } else { ! task buildJavaPackager(group: "Build") { enabled = COMPILE_FXPACKAGER doLast { copy { ! from "src/main/native/javapackager/shell" ! into "$buildDir/javapackager" ! fileMode = 0755 ! } ! copy { ! from "src/main/native/javapackager/shell" ! into "$buildDir/javapackager" ! rename ('javapackager', 'javafxpackager') fileMode = 0755 } } } } ! jar.dependsOn buildJavaPackager classes << { // Copy all of the download libraries to libs directory for the sake of the IDEs File libsDir = rootProject.file("build/libs"); File antLib = new File(libsDir, "ant-1.8.2.jar")
*** 2813,2826 **** copy { from "modules/fxpackager/build/man" into "build/${sdkDirName}/man" } ! // Copy over the javafxpackager executable if (t.name == "win" || t.name == "linux" || t.name == "mac") { copy { ! from "modules/fxpackager/build/javafxpackager" into "build/${sdkDirName}/bin" } } } dependsOn(jmxTask); --- 2824,2837 ---- copy { from "modules/fxpackager/build/man" into "build/${sdkDirName}/man" } ! // Copy over the javapackager executable if (t.name == "win" || t.name == "linux" || t.name == "mac") { copy { ! from "modules/fxpackager/build/javapackager" into "build/${sdkDirName}/bin" } } } dependsOn(jmxTask);