bsf/java-11-fixes.patch
2020-07-20 21:59:04 +02:00

118 lines
6.1 KiB
Diff

diff --git a/build-properties.xml b/build-properties.xml
new file mode 100644
index 0000000..18d14cc
--- /dev/null
+++ b/build-properties.xml
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="utf-8"?>
+<project name="props">
+ <property name="project.name" value="bsf"/>
+ <property name="project.fullName" value="Bean Scripting Framework"/>
+ <property name="project.version" value="2.4.0"/>
+ <property name="project.debug" value="on"/>
+ <property name="project.deprecation" value="on"/>
+
+ <property name="build.file" value="build.xml"/>
+ <property name="build.dir" value="build"/>
+ <property name="build.dest" value="build/classes"/>
+ <property name="build.lib" value="build/lib"/>
+ <property name="build.lib.win32" value="build/lib/win32"/>
+ <property name="build.samples" value="build/samples"/>
+ <property name="build.samples.calc" value="build/samples/calc"/>
+ <property name="build.samples.scriptedui" value="build/samples/scriptedui"/>
+ <property name="build.samples.xsl" value="build/samples/xsl"/>
+ <property name="build.javadocs" value="build/javadocs"/>
+ <property name="build.tests" value="build/testcases" />
+
+ <property name="dist.dir" value="dist"/>
+ <property name="dist.dir.root" value="${dist.dir}/${project.name}-${project.version}"/>
+ <property name="dist.bin.file" value="${dist.dir}/${project.name}-bin-${project.version}"/>
+ <property name="dist.src.file" value="${dist.dir}/${project.name}-src-${project.version}"/>
+
+ <property name="packages" value="org.apache.*"/>
+
+ <property name="samples.dir" value="samples"/>
+
+ <property name="site.src" location="xdocs"/>
+ <property name="site.dest" location="docs"/>
+ <property name="site.projectFile" value="stylesheets/project.xml"/>
+
+ <property name="source.level" value="1.8" />
+ <property name="target.level" value="1.8" />
+
+ <property name="src.dir" value="src"/>
+
+ <property name="templ.path" location="xdocs/stylesheets"/>
+
+ <property name="tests.dir" value="test"/>
+
+ <property name="velocity.props" location="${site.src}/velocity.properties"/>
+</project>
diff --git a/build.xml b/build.xml
index 39d31e1..1792f70 100644
--- a/build.xml
+++ b/build.xml
@@ -102,7 +102,7 @@ Copyright:
<pathelement location="${build.tests}"/>
</path>
- <target name="init" depends="clean">
+ <target name="init">
<tstamp />
@@ -134,11 +134,13 @@ Copyright:
<available property="junit.present" classname="junit.framework.TestCase" />
+ <!--
<uptodate property="javac.notRequired" targetfile="${build.lib}/${project.name}.jar">
<srcfiles dir="${src.dir}">
<patternset refid="javac.source.files" />
</srcfiles>
</uptodate>
+ -->
<uptodate property="javadoc.required" targetfile="${build.lib}/${project.name}.jar">
<srcfiles dir="${build.dir}" includes="**/*.html" />
@@ -214,7 +216,7 @@ Copyright:
<!-- =================================================================== -->
<target name="compile" description="Compiles the BSF *.java files." depends="prepare">
<mkdir dir="${build.dest}"/>
- <javac srcdir="${src.dir}" destdir="${build.dest}" debug="${project.debug}" deprecation="${project.deprecation}" source="${source.level}">
+ <javac srcdir="${src.dir}" destdir="${build.dest}" debug="${project.debug}" deprecation="${project.deprecation}" source="${source.level}" target="${target.level}">
<classpath>
<fileset dir="lib">
<include name="*.jar"/>
@@ -256,9 +258,9 @@ Copyright:
<copy todir="${build.samples}">
<fileset dir="${samples.dir}" />
</copy>
- <javac srcdir="${build.samples.calc}" destdir="${build.samples.calc}" classpath="${build.lib}/${project.name}.jar" debug="${project.debug}" deprecation="${project.deprecation}" source="${source.level}" />
- <javac srcdir="${build.samples.scriptedui}" destdir="${build.samples.scriptedui}" classpath="${build.lib}/${project.name}.jar" debug="${project.debug}" deprecation="${project.deprecation}" source="${source.level}" />
- <javac srcdir="${build.samples.xsl}" destdir="${build.samples.xsl}" classpath="${build.lib}/${project.name}.jar" debug="${project.debug}" deprecation="${project.deprecation}" source="${source.level}" />
+ <javac srcdir="${build.samples.calc}" destdir="${build.samples.calc}" classpath="${build.lib}/${project.name}.jar" debug="${project.debug}" deprecation="${project.deprecation}" source="${source.level}" target="${target.level}" />
+ <javac srcdir="${build.samples.scriptedui}" destdir="${build.samples.scriptedui}" classpath="${build.lib}/${project.name}.jar" debug="${project.debug}" deprecation="${project.deprecation}" source="${source.level}" target="${target.level}" />
+ <javac srcdir="${build.samples.xsl}" destdir="${build.samples.xsl}" classpath="${build.lib}/${project.name}.jar" debug="${project.debug}" deprecation="${project.deprecation}" source="${source.level}" target="${target.level}" />
</target>
<!-- =================================================================== -->
@@ -268,7 +270,7 @@ Copyright:
<mkdir dir="${build.javadocs}" />
<!-- FIXME: Excluding some packages temporarily -->
<javadoc packagenames="${packages}" failonerror="true" excludepackagenames="org.apache.bsf.engines.java, org.apache.bsf.engines.javaclass" destdir="${build.javadocs}" author="true" version="false" use="true" windowtitle="${project.fullName} API" doctitle="${project.fullName}" source="${source.level}">
- <classpath refid="compile.classpath" />
+ <arg value="-Xdoclint:none" />
<fileset dir="${src.dir}">
<patternset refid="java.source.files"></patternset>
</fileset>
@@ -375,7 +377,7 @@ Copyright:
<!-- =================================================================== -->
<target name="compile-test" if="junit.present" depends="compile">
<mkdir dir="${build.tests}" />
- <javac srcdir="${tests.dir}" destdir="${build.tests}" classpath="${build.dest}" source="${source.level}" />
+ <javac srcdir="${tests.dir}" destdir="${build.tests}" classpath="${build.dest}" source="${source.level}" target="${target.level}" />
</target>
<!-- =================================================================== -->