From e9d83a0cc2277fc0876d568672eea6f09f9b82a05dc41372a1c15c2932140a81 Mon Sep 17 00:00:00 2001 From: Fridrich Strba Date: Fri, 15 Sep 2017 11:18:18 +0000 Subject: [PATCH] Remove dependency on java-gcj-compat OBS-URL: https://build.opensuse.org/package/show/Java:packages/java-cup?expand=0&rev=12 --- java-cup-bootstrap.changes | 6 +++++ java-cup-bootstrap.spec | 50 ++++++++++++++------------------------ java-cup.changes | 6 +++++ java-cup.spec | 50 ++++++++++++++------------------------ 4 files changed, 48 insertions(+), 64 deletions(-) diff --git a/java-cup-bootstrap.changes b/java-cup-bootstrap.changes index 67ea46b..244664e 100644 --- a/java-cup-bootstrap.changes +++ b/java-cup-bootstrap.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Fri Sep 15 11:16:58 UTC 2017 - fstrba@suse.com + +- Do not depend on java-gcj-compat +- Fix build with jdk9: specify source and target 1.6 + ------------------------------------------------------------------- Thu Aug 29 07:47:30 UTC 2013 - mvyskocil@suse.com diff --git a/java-cup-bootstrap.spec b/java-cup-bootstrap.spec index dcb53a6..44eb730 100644 --- a/java-cup-bootstrap.spec +++ b/java-cup-bootstrap.spec @@ -1,7 +1,7 @@ # # spec file for package java-cup-bootstrap # -# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -18,10 +18,9 @@ ##### WARNING: please do not edit this auto generated spec file. Use the java-cup.spec! ##### %global with_bootstrap 1 -%bcond_with bootstrap %define cvs_version 11a %define real_name java-cup - +%bcond_with bootstrap Name: java-cup-bootstrap Version: 0.11 Release: 0 @@ -41,11 +40,7 @@ Patch3: java-cup-classpath.patch # Missing symbolFactory initialization in lr_parser, causes sinjdoc to crash Patch4: java-cup-lr_parser-constructor.patch BuildRequires: ant -%if %without bootstrap -BuildRequires: java-cup-bootstrap -BuildRequires: jflex -%endif -BuildRequires: java-1_5_0-gcj-compat-devel +BuildRequires: java-devel BuildRequires: xml-commons-apis-bootstrap BuildRequires: xml-commons-resolver-bootstrap #!BuildIgnore: xml-commons-jaxp-1.3-apis @@ -53,8 +48,10 @@ BuildRequires: xml-commons-resolver-bootstrap Obsoletes: java_cup < %{version}-%{release} Provides: java_cup = %{version}-%{release} BuildArch: noarch -BuildRoot: %{_tmppath}/%{name}-%{version}-build - +%if %without bootstrap +BuildRequires: java-cup-bootstrap +BuildRequires: jflex +%endif # bootstrap variant is just stripped down java-cup, so it conflicts %if %without bootstrap Conflicts: java-cup-bootstrap @@ -74,10 +71,7 @@ java-cup is a LALR Parser Generator in Java. With v0.11, you can: * * have Your own symbol classes - - %if %without bootstrap - %package manual Summary: LALR Parser Generator in Java Group: Development/Libraries/Java @@ -96,8 +90,6 @@ java-cup is a LALR Parser Generator in Java. With v0.11, you can: * * have Your own symbol classes - - %endif %prep @@ -107,12 +99,12 @@ java-cup is a LALR Parser Generator in Java. With v0.11, you can: * %setup -q -T -D -a 2 -n develop %patch2 -p1 %else -%{_bindir}/find . -name '*.jar' | %{_bindir}/xargs %{__rm} +%{_bindir}/find . -name '*.jar' | %{_bindir}/xargs rm %patch3 -p1 %endif %patch4 -p1 -%{__perl} -pi -e 's/1\.2/1.5/g' build.xml -%{__mkdir_p} classes dist +perl -pi -e 's/1\.2/1.6/g' build.xml +mkdir -p classes dist cp %{SOURCE3} license.txt %build @@ -122,31 +114,25 @@ export CLASSPATH= export CLASSPATH=$(build-classpath java-cup jflex) %endif export OPT_JAR_LIST=: -%ant +ant %install # jar -%{__mkdir_p} %{buildroot}%{_javadir} -%{__cp} -a dist/%{real_name}-%{cvs_version}.jar %{buildroot}%{_javadir}/%{real_name}-%{version}.jar -%{__cp} -a dist/%{real_name}-%{cvs_version}-runtime.jar %{buildroot}%{_javadir}/%{real_name}-runtime-%{version}.jar -(cd %{buildroot}%{_javadir} && for jar in *-%{version}*; do %{__ln_s} ${jar} ${jar/-%{version}/}; done) +mkdir -p %{buildroot}%{_javadir} +cp -a dist/%{real_name}-%{cvs_version}.jar %{buildroot}%{_javadir}/%{real_name}-%{version}.jar +cp -a dist/%{real_name}-%{cvs_version}-runtime.jar %{buildroot}%{_javadir}/%{real_name}-runtime-%{version}.jar +(cd %{buildroot}%{_javadir} && for jar in *-%{version}*; do ln -s ${jar} ${jar/-%{version}/}; done) # compatibility symlinks -(cd %{buildroot}%{_javadir} && %{__ln_s} %{real_name}.jar java_cup.jar && %{__ln_s} %{real_name}-runtime.jar java_cup-runtime.jar) -%{__mkdir_p} %{buildroot}%{_bindir} -%{__install} -p -m 755 %{SOURCE1} %{buildroot}%{_bindir}/%{real_name} - -%clean -%{__rm} -rf %{buildroot} +(cd %{buildroot}%{_javadir} && ln -s %{real_name}.jar java_cup.jar && ln -s %{real_name}-runtime.jar java_cup-runtime.jar) +mkdir -p %{buildroot}%{_bindir} +install -p -m 755 %{SOURCE1} %{buildroot}%{_bindir}/%{real_name} %files -%defattr(0644,root,root,0755) %doc changelog.txt license.txt %attr(0755,root,root) %{_bindir}/%{real_name} %{_javadir}/* %if %without bootstrap - %files manual -%defattr(0644,root,root,0755) %doc manual.html %endif diff --git a/java-cup.changes b/java-cup.changes index 67ea46b..244664e 100644 --- a/java-cup.changes +++ b/java-cup.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Fri Sep 15 11:16:58 UTC 2017 - fstrba@suse.com + +- Do not depend on java-gcj-compat +- Fix build with jdk9: specify source and target 1.6 + ------------------------------------------------------------------- Thu Aug 29 07:47:30 UTC 2013 - mvyskocil@suse.com diff --git a/java-cup.spec b/java-cup.spec index 9a021c6..e952785 100644 --- a/java-cup.spec +++ b/java-cup.spec @@ -1,7 +1,7 @@ # # spec file for package java-cup # -# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -17,10 +17,9 @@ %global _without_bootstrap 1 -%bcond_with bootstrap %define cvs_version 11a %define real_name java-cup - +%bcond_with bootstrap Name: java-cup Version: 0.11 Release: 0 @@ -40,11 +39,7 @@ Patch3: java-cup-classpath.patch # Missing symbolFactory initialization in lr_parser, causes sinjdoc to crash Patch4: java-cup-lr_parser-constructor.patch BuildRequires: ant -%if %without bootstrap -BuildRequires: java-cup-bootstrap -BuildRequires: jflex -%endif -BuildRequires: java-1_5_0-gcj-compat-devel +BuildRequires: java-devel BuildRequires: xml-commons-apis-bootstrap BuildRequires: xml-commons-resolver-bootstrap #!BuildIgnore: xml-commons-jaxp-1.3-apis @@ -52,8 +47,10 @@ BuildRequires: xml-commons-resolver-bootstrap Obsoletes: java_cup < %{version}-%{release} Provides: java_cup = %{version}-%{release} BuildArch: noarch -BuildRoot: %{_tmppath}/%{name}-%{version}-build - +%if %without bootstrap +BuildRequires: java-cup-bootstrap +BuildRequires: jflex +%endif # bootstrap variant is just stripped down java-cup, so it conflicts %if %without bootstrap Conflicts: java-cup-bootstrap @@ -73,10 +70,7 @@ java-cup is a LALR Parser Generator in Java. With v0.11, you can: * * have Your own symbol classes - - %if %without bootstrap - %package manual Summary: LALR Parser Generator in Java Group: Development/Libraries/Java @@ -95,8 +89,6 @@ java-cup is a LALR Parser Generator in Java. With v0.11, you can: * * have Your own symbol classes - - %endif %prep @@ -106,12 +98,12 @@ java-cup is a LALR Parser Generator in Java. With v0.11, you can: * %setup -q -T -D -a 2 -n develop %patch2 -p1 %else -%{_bindir}/find . -name '*.jar' | %{_bindir}/xargs %{__rm} +%{_bindir}/find . -name '*.jar' | %{_bindir}/xargs rm %patch3 -p1 %endif %patch4 -p1 -%{__perl} -pi -e 's/1\.2/1.5/g' build.xml -%{__mkdir_p} classes dist +perl -pi -e 's/1\.2/1.6/g' build.xml +mkdir -p classes dist cp %{SOURCE3} license.txt %build @@ -121,31 +113,25 @@ export CLASSPATH= export CLASSPATH=$(build-classpath java-cup jflex) %endif export OPT_JAR_LIST=: -%ant +ant %install # jar -%{__mkdir_p} %{buildroot}%{_javadir} -%{__cp} -a dist/%{real_name}-%{cvs_version}.jar %{buildroot}%{_javadir}/%{real_name}-%{version}.jar -%{__cp} -a dist/%{real_name}-%{cvs_version}-runtime.jar %{buildroot}%{_javadir}/%{real_name}-runtime-%{version}.jar -(cd %{buildroot}%{_javadir} && for jar in *-%{version}*; do %{__ln_s} ${jar} ${jar/-%{version}/}; done) +mkdir -p %{buildroot}%{_javadir} +cp -a dist/%{real_name}-%{cvs_version}.jar %{buildroot}%{_javadir}/%{real_name}-%{version}.jar +cp -a dist/%{real_name}-%{cvs_version}-runtime.jar %{buildroot}%{_javadir}/%{real_name}-runtime-%{version}.jar +(cd %{buildroot}%{_javadir} && for jar in *-%{version}*; do ln -s ${jar} ${jar/-%{version}/}; done) # compatibility symlinks -(cd %{buildroot}%{_javadir} && %{__ln_s} %{real_name}.jar java_cup.jar && %{__ln_s} %{real_name}-runtime.jar java_cup-runtime.jar) -%{__mkdir_p} %{buildroot}%{_bindir} -%{__install} -p -m 755 %{SOURCE1} %{buildroot}%{_bindir}/%{real_name} - -%clean -%{__rm} -rf %{buildroot} +(cd %{buildroot}%{_javadir} && ln -s %{real_name}.jar java_cup.jar && ln -s %{real_name}-runtime.jar java_cup-runtime.jar) +mkdir -p %{buildroot}%{_bindir} +install -p -m 755 %{SOURCE1} %{buildroot}%{_bindir}/%{real_name} %files -%defattr(0644,root,root,0755) %doc changelog.txt license.txt %attr(0755,root,root) %{_bindir}/%{real_name} %{_javadir}/* %if %without bootstrap - %files manual -%defattr(0644,root,root,0755) %doc manual.html %endif