Hallo zusammen,
hab da mal ne Frage, ich hoffe mir kann da jemand helfen.
Ich hatte jetzt immer mit Ant ein "Self-Contained Application Packaging" erstellt und mit Java 8,
jetzt wollte ich auf Java 9 umsteigen und da bekomme ich die Fehlermeldung.
Hat da schon jemand Erfahrung mit dem Problem?
Hier noch meine build.xml
hab da mal ne Frage, ich hoffe mir kann da jemand helfen.
Ich hatte jetzt immer mit Ant ein "Self-Contained Application Packaging" erstellt und mit Java 8,
jetzt wollte ich auf Java 9 umsteigen und da bekomme ich die Fehlermeldung.
Code:
BUILD FAILED
H:\Apps\Java\Workspace Oxygen\HT .-. OE7\build\build.xml:148: fx:platform doesn't support the "basedir" attribute
Hat da schon jemand Erfahrung mit dem Problem?
Hier noch meine build.xml
HTML:
<?xml version="1.0" encoding="UTF-8"?>
<project name="Build" default="do-deploy" basedir="." xmlns:fx="javafx:com.sun.javafx.tools.ant">
<property name="erstelle.shortcut" value="true"/>
<property name="projektOrdner" value="Build"/>
<property name="publisher" value=""/>
<property name="native.Bundles" value="all"/>
<property name="titel" value="App"/>
<property name="version" value="1.0.0"/>
<property name="main.Class" value="application.DemoStage"/>
<!-- <property name="welche.Java.Version" value="jdk1.8.0_151"/> -->
<property name="welche.Java.Version" value="jdk-9.0.4"/>
<!-- Pfade -->
<property name="projekt.Pfad" value="H:\Apps\Java\Workspace\App"/>
<property name="lib.Pfad" value="${projekt.Pfad}\lib"/>
<target name="init-fx-tasks">
<path id="fxant">
<filelist>
<file name="C:\Program Files\Java\${welche.Java.Version}\lib\ant-javafx.jar"/>
<file name="C:\Program Files\Java\${welche.Java.Version}\jre\lib\ext\jfxrt.jar"/>
<file name="${basedir}"/>
</filelist>
</path>
<taskdef resource="com/sun/javafx/tools/ant/antlib.xml"
uri="javafx:com.sun.javafx.tools.ant"
classpathref="fxant"/>
</target>
<target name="setup-staging-area">
<delete dir="externalLibs" />
<delete dir="project" />
<delete dir="projectRefs" />
<mkdir dir="externalLibs" />
<mkdir dir="project" />
<mkdir dir="projectRefs" />
<copy todir="project">
<fileset dir="${projekt.Pfad}">
<include name="src/**" />
</fileset>
</copy>
</target>
<target name='do-compile'>
<delete dir="build" />
<mkdir dir="build/src" />
<mkdir dir="build/libs" />
<mkdir dir="build/classes" />
<copydir src="${lib.Pfad}"
dest="${basedir}\build\libs"
includes="**/*.jar"
excludes="**/Test.java"
/>
<copy todir="build/libs">
<fileset dir="externalLibs">
<include name="**/*.jar" />
</fileset>
</copy>
<!-- Copy project sources itself -->
<copy todir="build/src">
<fileset dir="project/src">
<include name="**/*"/>
</fileset>
</copy>
<javac includeantruntime="false" source="9" target="9" srcdir="build/src" destdir="build/classes" encoding="Cp1252">
<classpath>
<fileset dir="build/libs">
<include name="*"/>
</fileset>
</classpath>
</javac>
<!-- Copy over none Java-Files -->
<copy todir="build/classes">
<fileset dir="project/src">
<exclude name="**/*.java"/>
</fileset>
</copy>
</target>
<target name="do-deploy" depends="setup-staging-area, do-compile, init-fx-tasks">
<delete file="dist"/>
<delete file="deploy" />
<mkdir dir="dist" />
<mkdir dir="dist/libs" />
<copy todir="dist/libs">
<fileset dir="externalLibs">
<include name="*" />
</fileset>
</copy>
<fx:resources id="appRes">
<fx:fileset dir="dist" includes="${projektOrdner}.jar"/>
<fx:fileset dir="dist" includes="libs/*"/>
<fx:fileset dir="dist" includes="resources/**"/>
</fx:resources>
<fx:application id="fxApplication"
name="${titel}"
mainClass="${main.Class}"
version="${version}"
/>
<mkdir dir="build/classes/META-INF" />
<fx:jar destfile="dist/Build.jar">
<fx:application refid="fxApplication"/>
<fileset dir="build/classes">
</fileset>
<fx:resources refid="appRes"/>
<manifest>
<attribute name="Implementation-Vendor" value="${publisher}"/>
<attribute name="Implementation-Title" value="${titel}"/>
<attribute name="Implementation-Version" value="${version}"/>
<attribute name="JavaFX-Feature-Proxy" value="None"/>
</manifest>
</fx:jar>
<mkdir dir="deploy" />
<!-- Need to use ${basedir} because somehow the ant task is calculating the directory differently -->
<fx:deploy
embedJNLP="false"
extension="false"
includeDT="false"
offlineAllowed="true"
outdir="${basedir}/deploy"
outfile="Build" nativeBundles="${native.Bundles}"
updatemode="background"
verbose="true" >
<fx:platform basedir="C:\Program Files\Java\${welche.Java.Version}"/>
<fx:info title="Build" vendor="${publisher}"/>
<fx:application refId="fxApplication"/>
<fx:resources refid="appRes"/>
</fx:deploy>
</target>
</project>