Fix build with jdk9

OBS-URL: https://build.opensuse.org/package/show/Java:packages/jsr-305?expand=0&rev=21
This commit is contained in:
Fridrich Strba 2017-09-19 09:49:43 +00:00 committed by Git OBS Bridge
parent 5df4db866f
commit df67701169
3 changed files with 9 additions and 2 deletions

View File

@ -2,7 +2,7 @@
<target name="build" depends="clean,classes,jar,javadoc"/> <target name="build" depends="clean,classes,jar,javadoc"/>
<target name="classes"> <target name="classes">
<mkdir dir="src/main/java"/> <mkdir dir="src/main/java"/>
<javac destdir="src/main/java" source="1.5" debug="on"> <javac destdir="src/main/java" debug="on">
<src path="src/main/java"/> <src path="src/main/java"/>
<classpath> <classpath>
<pathelement location="src/main/java"/> <pathelement location="src/main/java"/>

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Tue Sep 19 09:49:18 UTC 2017 - fstrba@suse.com
- Fix build with jdk9: specify java target and source 1.6
------------------------------------------------------------------- -------------------------------------------------------------------
Fri May 19 10:53:24 UTC 2017 - dziolkowski@suse.com Fri May 19 10:53:24 UTC 2017 - dziolkowski@suse.com

View File

@ -32,6 +32,7 @@ Source1: jsr-305-ri-build.xml
# The URL reffers to New BSD License - used <OWNER> == Bill Pugh, <YEAR> == 2008 # The URL reffers to New BSD License - used <OWNER> == Bill Pugh, <YEAR> == 2008
Source2: license Source2: license
BuildRequires: ant BuildRequires: ant
BuildRequires: fdupes
BuildRequires: java-devel BuildRequires: java-devel
BuildRequires: javapackages-local BuildRequires: javapackages-local
BuildRequires: javapackages-tools BuildRequires: javapackages-tools
@ -64,7 +65,7 @@ cp %{SOURCE2} .
export OPT_JAR_LIST=: export OPT_JAR_LIST=:
export CLASSPATH= export CLASSPATH=
pushd ri pushd ri
%{ant} -Dant.build.javac.source=1.5 -Dant.build.javac.target=1.5 \ %{ant} -Dant.build.javac.source=1.6 -Dant.build.javac.target=1.6 \
-Dversion=%{version} -Djava.javadoc=%{_javadocdir}/java -Dversion=%{version} -Djava.javadoc=%{_javadocdir}/java
popd popd
@ -82,6 +83,7 @@ cp -a ri/pom.xml %{buildroot}%{_mavenpomdir}/JPP-%{name}.pom
# javadoc # javadoc
mkdir -p %{buildroot}%{_javadocdir}/%{name} mkdir -p %{buildroot}%{_javadocdir}/%{name}
cp -a ri/javadoc/* %{buildroot}%{_javadocdir}/%{name} cp -a ri/javadoc/* %{buildroot}%{_javadocdir}/%{name}
%fdupes -s %{buildroot}%{_javadocdir}/%{name}
%files %files
%defattr(0644,root,root,0755) %defattr(0644,root,root,0755)