Add patches jflex-CharSet_java.patch and jflex-StateSet_java.patch to allow

building with the new gcj
This commit is contained in:
Matt Wringe 2007-04-02 20:02:58 +00:00
parent 5e32cf6b3b
commit adb5449bf0
3 changed files with 51 additions and 2 deletions

21
jflex-CharSet_java.patch Normal file
View File

@ -0,0 +1,21 @@
--- ./src/JFlex/CharSet.java.orig 2007-04-02 11:03:11.000000000 -0400
+++ ./src/JFlex/CharSet.java 2007-04-02 11:03:47.000000000 -0400
@@ -94,14 +94,14 @@
}
public String toString() {
- CharSetEnumerator enum = characters();
+ CharSetEnumerator enumer = characters();
StringBuffer result = new StringBuffer("{");
- if ( enum.hasMoreElements() ) result.append(""+enum.nextElement());
+ if ( enumer.hasMoreElements() ) result.append(""+enumer.nextElement());
- while ( enum.hasMoreElements() ) {
- int i = enum.nextElement();
+ while ( enumer.hasMoreElements() ) {
+ int i = enumer.nextElement();
result.append( ", "+(int)i);
}

21
jflex-StateSet_java.patch Normal file
View File

@ -0,0 +1,21 @@
--- ./src/JFlex/StateSet.java.orig 2007-04-02 11:04:11.000000000 -0400
+++ ./src/JFlex/StateSet.java 2007-04-02 11:04:38.000000000 -0400
@@ -276,14 +276,14 @@
public String toString() {
- StateSetEnumerator enum = states();
+ StateSetEnumerator enumer = states();
StringBuffer result = new StringBuffer("{");
- if ( enum.hasMoreElements() ) result.append(""+enum.nextElement());
+ if ( enumer.hasMoreElements() ) result.append(""+enumer.nextElement());
- while ( enum.hasMoreElements() ) {
- int i = enum.nextElement();
+ while ( enumer.hasMoreElements() ) {
+ int i = enumer.nextElement();
result.append( ", "+i);
}

View File

@ -33,13 +33,15 @@
Summary: Fast Scanner Generator
Name: jflex
Version: 1.3.5
Release: 2jpp.1%{?dist}
Release: 2jpp.2%{?dist}
Epoch: 0
License: GPL
URL: http://jflex.de/
Group: Development/Libraries/Java
Source0: http://downloads.sourceforge.net/jflex/jflex-1.3.5.tar.gz
Patch0: jflex-Makefile.patch
Patch1: jflex-CharSet_java.patch
Patch2: jflex-StateSet_java.patch
BuildRequires: jpackage-utils >= 0:1.5
BuildRequires: make
BuildRequires: java-devel
@ -73,7 +75,8 @@ find . -name "*.class" -exec rm {} \;
%{__sed} -i 's/\r//' COPYRIGHT
%patch0 -b .sav
%patch1 -b .sav
%patch2 -b .sav
%build
pushd src
@ -116,6 +119,10 @@ rm -rf $RPM_BUILD_ROOT
# -----------------------------------------------------------------------------
%changelog
* Mon Apr 02 2007 Matt Wringe <mwringe@redhat.com> - 0:1.3.5-2jpp.2
- Add patches jflex-CharSet_java.patch and jflex-StateSet_java.patch
to allow building with the new gcj
* Mon Feb 12 2007 Matt Wringe <mwringe@redhat.com> - 0:1.3.5-2jpp.1
- Remove javadoc post and postun sections due to new jpp standard
- Update makefile patch to compress jar