[xbase] fix for gcc 4.7.0

Tom Callaway spot at fedoraproject.org
Thu Jan 5 20:40:51 UTC 2012


commit b169a8b09a3308f642c41879dc9669dc13588486
Author: Tom Callaway <spot at fedoraproject.org>
Date:   Thu Jan 5 15:40:48 2012 -0500

    fix for gcc 4.7.0

 xbase-3.1.2-gcc47.patch   |   21 ++++
 xbase-3.1.2-lesserg.patch |  294 +++++++++++++++++++++++++++++++++++++++++++++
 xbase.spec                |    9 ++-
 3 files changed, 323 insertions(+), 1 deletions(-)
---
diff --git a/xbase-3.1.2-gcc47.patch b/xbase-3.1.2-gcc47.patch
new file mode 100644
index 0000000..7774251
--- /dev/null
+++ b/xbase-3.1.2-gcc47.patch
@@ -0,0 +1,21 @@
+diff -up xbase64-3.1.2/bin/dumprecs.cpp.gcc47 xbase64-3.1.2/bin/dumprecs.cpp
+--- xbase64-3.1.2/bin/dumprecs.cpp.gcc47	2012-01-05 15:36:00.377536998 -0500
++++ xbase64-3.1.2/bin/dumprecs.cpp	2012-01-05 15:36:15.198399295 -0500
+@@ -70,7 +70,7 @@ int main(int ac,char** av)
+     return 1;
+   }
+ 
+-  for(int i=1; i<ac; ++i){
++  for(int i=1; i<ac; ++i){{
+     char* filename = av[i];
+ 
+     xbDbf MyFile( &x );
+@@ -91,7 +91,7 @@ int main(int ac,char** av)
+         x.DisplayError( rc );
+     }
+     MyFile.CloseDatabase();	/* close database */
+-  }
++  }}
+   return 0;
+ }     
+ 
diff --git a/xbase-3.1.2-lesserg.patch b/xbase-3.1.2-lesserg.patch
new file mode 100644
index 0000000..b6eb71e
--- /dev/null
+++ b/xbase-3.1.2-lesserg.patch
@@ -0,0 +1,294 @@
+diff -up xbase64-3.1.2/xbase64/xbase64.cpp.lesserg xbase64-3.1.2/xbase64/xbase64.cpp
+--- xbase64-3.1.2/xbase64/xbase64.cpp.lesserg	2012-01-05 15:31:01.695312436 -0500
++++ xbase64-3.1.2/xbase64/xbase64.cpp	2012-01-05 15:31:01.717312232 -0500
+@@ -38,7 +38,7 @@
+ 
+ */
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+   #pragma implementation "xbase64.h"
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xbase64.h.lesserg xbase64-3.1.2/xbase64/xbase64.h
+--- xbase64-3.1.2/xbase64/xbase64.h.lesserg	2006-07-17 12:54:50.000000000 -0400
++++ xbase64-3.1.2/xbase64/xbase64.h	2012-01-05 15:31:01.718312223 -0500
+@@ -42,7 +42,7 @@
+ #ifndef __XB_XBASE_H__
+ #define __XB_XBASE_H__
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+ #pragma interface
+ #endif
+ 
+@@ -60,7 +60,7 @@
+ // ripped from wxWindows
+ 
+ // _declspec works in BC++ 5 and later, as well as VC++
+-#if defined(__VISUALC__) || defined(__BORLANDC__) || defined(__GNU LesserC__)
++#if defined(__VISUALC__) || defined(__BORLANDC__) || defined(__GNU_LesserC__)
+ #  ifdef XBMAKINGDLL
+ #    define XBDLLEXPORT __declspec( dllexport )
+ #    define XBDLLEXPORT_DATA(type) __declspec( dllexport ) type
+diff -up xbase64-3.1.2/xbase64/xbcdx.h.lesserg xbase64-3.1.2/xbase64/xbcdx.h
+--- xbase64-3.1.2/xbase64/xbcdx.h.lesserg	2012-01-05 15:32:17.398608985 -0500
++++ xbase64-3.1.2/xbase64/xbcdx.h	2012-01-05 15:32:43.051370614 -0500
+@@ -50,7 +50,7 @@ struct CdxInnerNode: public CdxNode
+ {
+   char keys[500];
+ }
+-#ifdef __GNU LesserC__
++#ifdef __GNU_LesserC__
+ 	__attribute__((packed))
+ #endif
+ ;
+@@ -67,7 +67,7 @@ struct CdxLeafNode: public CdxNode
+   char byteCount;
+   char keys[488];
+ } 
+-#ifdef __GNU LesserC__
++#ifdef __GNU_LesserC__
+ 	__attribute__((packed))
+ #endif
+ ;
+diff -up xbase64-3.1.2/xbase64/xbdate.cpp.lesserg xbase64-3.1.2/xbase64/xbdate.cpp
+--- xbase64-3.1.2/xbase64/xbdate.cpp.lesserg	2006-07-17 12:54:42.000000000 -0400
++++ xbase64-3.1.2/xbase64/xbdate.cpp	2012-01-05 15:31:01.719312213 -0500
+@@ -40,7 +40,7 @@
+ 
+ */
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+   #pragma implementation "xbdate.h"
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xbdate.h.lesserg xbase64-3.1.2/xbase64/xbdate.h
+--- xbase64-3.1.2/xbase64/xbdate.h.lesserg	2006-07-17 12:54:50.000000000 -0400
++++ xbase64-3.1.2/xbase64/xbdate.h	2012-01-05 15:31:01.721312195 -0500
+@@ -45,7 +45,7 @@
+ #ifndef __XB_XBDATE_H__
+ #define __XB_XBDATE_H__
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+ #pragma interface
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xbdbf.cpp.lesserg xbase64-3.1.2/xbase64/xbdbf.cpp
+--- xbase64-3.1.2/xbase64/xbdbf.cpp.lesserg	2006-07-17 12:54:42.000000000 -0400
++++ xbase64-3.1.2/xbase64/xbdbf.cpp	2012-01-05 15:31:01.722312185 -0500
+@@ -39,7 +39,7 @@
+ 
+ */
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+   #pragma implementation "xbdbf.h"
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xbdbf.h.lesserg xbase64-3.1.2/xbase64/xbdbf.h
+--- xbase64-3.1.2/xbase64/xbdbf.h.lesserg	2006-07-17 12:54:50.000000000 -0400
++++ xbase64-3.1.2/xbase64/xbdbf.h	2012-01-05 15:31:01.723312175 -0500
+@@ -41,7 +41,7 @@
+ #ifndef __XB_DBF_H__
+ #define __XB_DBF_H__
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+ #pragma interface
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xbexp.cpp.lesserg xbase64-3.1.2/xbase64/xbexp.cpp
+--- xbase64-3.1.2/xbase64/xbexp.cpp.lesserg	2006-07-17 12:54:42.000000000 -0400
++++ xbase64-3.1.2/xbase64/xbexp.cpp	2012-01-05 15:31:01.725312157 -0500
+@@ -38,7 +38,7 @@
+ 
+ */
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+   #pragma implementation "xbexp.h"
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xbexp.h.lesserg xbase64-3.1.2/xbase64/xbexp.h
+--- xbase64-3.1.2/xbase64/xbexp.h.lesserg	2006-07-17 12:54:50.000000000 -0400
++++ xbase64-3.1.2/xbase64/xbexp.h	2012-01-05 15:31:01.726312148 -0500
+@@ -42,7 +42,7 @@
+ #ifndef __XB_EXP_H__
+ #define __XB_EXP_H__
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+ #pragma interface
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xbfile.cpp.lesserg xbase64-3.1.2/xbase64/xbfile.cpp
+--- xbase64-3.1.2/xbase64/xbfile.cpp.lesserg	2006-07-17 12:54:42.000000000 -0400
++++ xbase64-3.1.2/xbase64/xbfile.cpp	2012-01-05 15:31:01.727312139 -0500
+@@ -39,7 +39,7 @@
+ 
+ */
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+   #pragma implementation "xbfile.h"
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xbfile.h.lesserg xbase64-3.1.2/xbase64/xbfile.h
+--- xbase64-3.1.2/xbase64/xbfile.h.lesserg	2006-07-17 12:54:50.000000000 -0400
++++ xbase64-3.1.2/xbase64/xbfile.h	2012-01-05 15:31:01.728312130 -0500
+@@ -45,7 +45,7 @@
+ #ifndef __XB_FILE_H__
+ #define __XB_FILE_H__
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+ #pragma interface
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xbfilter.cpp.lesserg xbase64-3.1.2/xbase64/xbfilter.cpp
+--- xbase64-3.1.2/xbase64/xbfilter.cpp.lesserg	2006-07-17 12:54:42.000000000 -0400
++++ xbase64-3.1.2/xbase64/xbfilter.cpp	2012-01-05 15:31:01.729312120 -0500
+@@ -38,7 +38,7 @@
+ 
+ */
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+   #pragma implementation "xbfilter.h"
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xbfilter.h.lesserg xbase64-3.1.2/xbase64/xbfilter.h
+--- xbase64-3.1.2/xbase64/xbfilter.h.lesserg	2006-07-17 12:54:50.000000000 -0400
++++ xbase64-3.1.2/xbase64/xbfilter.h	2012-01-05 15:31:01.731312101 -0500
+@@ -44,7 +44,7 @@
+ #ifndef __XB_FILTER_H__
+ #define __XB_FILTER_H__
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+ #pragma interface
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xbindex.cpp.lesserg xbase64-3.1.2/xbase64/xbindex.cpp
+--- xbase64-3.1.2/xbase64/xbindex.cpp.lesserg	2006-07-17 12:54:42.000000000 -0400
++++ xbase64-3.1.2/xbase64/xbindex.cpp	2012-01-05 15:31:01.732312092 -0500
+@@ -37,7 +37,7 @@
+        USA
+ */
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+   #pragma implementation "xbindex.h"
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xbindex.h.lesserg xbase64-3.1.2/xbase64/xbindex.h
+--- xbase64-3.1.2/xbase64/xbindex.h.lesserg	2006-07-17 12:54:50.000000000 -0400
++++ xbase64-3.1.2/xbase64/xbindex.h	2012-01-05 15:31:01.733312083 -0500
+@@ -43,7 +43,7 @@
+ #ifndef __XB_INDEX_H__
+ #define __XB_INDEX_H__
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+ #pragma interface
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xblock.cpp.lesserg xbase64-3.1.2/xbase64/xblock.cpp
+--- xbase64-3.1.2/xbase64/xblock.cpp.lesserg	2012-01-05 15:31:01.696312427 -0500
++++ xbase64-3.1.2/xbase64/xblock.cpp	2012-01-05 15:31:01.734312074 -0500
+@@ -42,7 +42,7 @@
+        USA
+ */
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+   #pragma implementation "xblock.h"
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xblock.h.lesserg xbase64-3.1.2/xbase64/xblock.h
+--- xbase64-3.1.2/xbase64/xblock.h.lesserg	2006-07-17 12:54:50.000000000 -0400
++++ xbase64-3.1.2/xbase64/xblock.h	2012-01-05 15:31:01.735312065 -0500
+@@ -44,7 +44,7 @@
+ #ifndef __XB_XBLOCK_H__
+ #define __XB_XBLOCK_H__
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+ #pragma interface
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xbndx.cpp.lesserg xbase64-3.1.2/xbase64/xbndx.cpp
+--- xbase64-3.1.2/xbase64/xbndx.cpp.lesserg	2006-07-17 12:54:42.000000000 -0400
++++ xbase64-3.1.2/xbase64/xbndx.cpp	2012-01-05 15:31:01.737312045 -0500
+@@ -36,7 +36,7 @@
+ 
+ */
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+   #pragma implementation "xbndx.h"
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xbndx.h.lesserg xbase64-3.1.2/xbase64/xbndx.h
+--- xbase64-3.1.2/xbase64/xbndx.h.lesserg	2006-07-17 12:54:50.000000000 -0400
++++ xbase64-3.1.2/xbase64/xbndx.h	2012-01-05 15:31:01.738312036 -0500
+@@ -41,7 +41,7 @@
+ #ifndef __XB_NDX_H__
+ #define __XB_NDX_H__
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+ #pragma interface
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xbntx.cpp.lesserg xbase64-3.1.2/xbase64/xbntx.cpp
+--- xbase64-3.1.2/xbase64/xbntx.cpp.lesserg	2006-07-17 12:54:42.000000000 -0400
++++ xbase64-3.1.2/xbase64/xbntx.cpp	2012-01-05 15:31:01.740312018 -0500
+@@ -40,7 +40,7 @@
+        USA
+ */
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+   #pragma implementation "xbntx.h"
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xbntx.h.lesserg xbase64-3.1.2/xbase64/xbntx.h
+--- xbase64-3.1.2/xbase64/xbntx.h.lesserg	2006-07-17 12:54:50.000000000 -0400
++++ xbase64-3.1.2/xbase64/xbntx.h	2012-01-05 15:31:01.741312009 -0500
+@@ -42,7 +42,7 @@
+ #ifndef __XB_NTX_H__
+ #define __XB_NTX_H__
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+ #pragma interface
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xbstring.cpp.lesserg xbase64-3.1.2/xbase64/xbstring.cpp
+--- xbase64-3.1.2/xbase64/xbstring.cpp.lesserg	2006-07-17 12:54:42.000000000 -0400
++++ xbase64-3.1.2/xbase64/xbstring.cpp	2012-01-05 15:31:01.742312000 -0500
+@@ -38,7 +38,7 @@
+ 
+ */
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+   #pragma implementation "xbstring.h"
+ #endif
+ 
+diff -up xbase64-3.1.2/xbase64/xbstring.h.lesserg xbase64-3.1.2/xbase64/xbstring.h
+--- xbase64-3.1.2/xbase64/xbstring.h.lesserg	2006-07-17 12:54:50.000000000 -0400
++++ xbase64-3.1.2/xbase64/xbstring.h	2012-01-05 15:31:01.743311990 -0500
+@@ -41,7 +41,7 @@
+ #ifndef __XBSTRING_H__
+ #define __XBSTRING_H__
+ 
+-#ifdef __GNU LesserG__
++#ifdef __GNU_LesserG__
+ #pragma interface
+ #endif
+ 
diff --git a/xbase.spec b/xbase.spec
index 3c209c8..dd10206 100644
--- a/xbase.spec
+++ b/xbase.spec
@@ -1,7 +1,7 @@
 Name:		xbase
 Summary: 	XBase compatible database library
 Version: 	3.1.2
-Release: 	2%{?dist}
+Release: 	3%{?dist}
 License: 	LGPLv2+
 Group: 		System Environment/Libraries
 URL:		http://linux.techass.com/projects/xdb/
@@ -10,6 +10,8 @@ Patch0:		xbase-3.1.2-fixconfig.patch
 Patch1:		xbase-3.1.2-gcc44.patch
 Patch2:		xbase-2.0.0-ppc.patch
 Patch3:		xbase-3.1.2-xbnode.patch
+Patch4:		xbase-3.1.2-lesserg.patch
+Patch5:		xbase-3.1.2-gcc47.patch
 BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 BuildRequires:	doxygen, libtool
 Provides:	xbase64 = %{version}-%{release}
@@ -54,6 +56,8 @@ zap (remove all records from a DBF file).
 %patch1 -p1 -b .gcc44
 %patch2 -p1
 %patch3 -p1
+%patch4 -p1 -b .lesserg
+%patch5 -p1 -b .gcc47
 
 %build
 touch AUTHORS README NEWS
@@ -115,6 +119,9 @@ rm -rf $RPM_BUILD_ROOT
 %{_bindir}/dbfutil1
 
 %changelog
+* Thu Jan  5 2012 Tom Callaway <spot at fedoraproject.org> - 3.1.2-3
+- Fix gcc 4.7.0 compile
+
 * Mon Feb 07 2011 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 3.1.2-2
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
 


More information about the scm-commits mailing list