From c1f7a45fd5aebfbcfb5f1ebbaff5258a0bb2f261 Mon Sep 17 00:00:00 2001 From: Jonathan Dieter Date: Feb 08 2011 15:52:14 +0000 Subject: Fix FTBFS (bug #631320) for GCC 4.5 using patch from openSUSE --- diff --git a/drgeo-1.1.0-anonymous-type.patch b/drgeo-1.1.0-anonymous-type.patch new file mode 100644 index 0000000..71dfa42 --- /dev/null +++ b/drgeo-1.1.0-anonymous-type.patch @@ -0,0 +1,52 @@ +Index: drgeo-1.1.0/geo/drgeo_dialog.cc +=================================================================== +--- drgeo-1.1.0.orig/geo/drgeo_dialog.cc ++++ drgeo-1.1.0/geo/drgeo_dialog.cc +@@ -38,12 +38,7 @@ static GtkWidget *drgeoEditDialog = NULL + // Used in the style dialod callback, I know it's ugly, but so easy + static drgeoFigure *selected_figure; + +-struct +-{ +- drgeoPoint mouse; +- drgeoFigure *figure; +-} +-drgeoDialogData; ++DialogData drgeoDialogData; + + + static void drgeo_edit_dialog_cb (GtkWidget * dialog, +Index: drgeo-1.1.0/geo/drgeo_dialog.h +=================================================================== +--- drgeo-1.1.0.orig/geo/drgeo_dialog.h ++++ drgeo-1.1.0/geo/drgeo_dialog.h +@@ -34,4 +34,11 @@ extern "C" + } + + #endif /* __cplusplus */ ++ ++typedef struct ++{ ++ drgeoPoint mouse; ++ drgeoFigure *figure; ++} DialogData; ++ + #endif +Index: drgeo-1.1.0/geo/drgeo_figure.cc +=================================================================== +--- drgeo-1.1.0.orig/geo/drgeo_figure.cc ++++ drgeo-1.1.0/geo/drgeo_figure.cc +@@ -48,12 +48,7 @@ + #include "drgeo_dialog.h" + #include "traite.h" + +-extern struct +-{ +- drgeoPoint mouse; +- drgeoFigure *figure; +-} +-drgeoDialogData; ++extern DialogData drgeoDialogData; + + typedef struct drgeoSearchValue + { diff --git a/drgeo.spec b/drgeo.spec index f132a4e..65b236f 100644 --- a/drgeo.spec +++ b/drgeo.spec @@ -1,7 +1,7 @@ Summary: Interactive educational geometry software Name: drgeo Version: 1.1.0 -Release: 17%{?dist} +Release: 18%{?dist} License: GPLv2+ Group: Applications/Engineering URL: http://www.ofset.org/drgeo @@ -9,6 +9,7 @@ URL: http://www.ofset.org/drgeo Source: http://dl.sf.net/ofset/drgeo-%{version}.tar.gz Patch0: drgeo-1.1.0-htmlview.patch Patch1: drgeo.patch +Patch2: drgeo-1.1.0-anonymous-type.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: flex, bison, gmp-devel >= 2.0.2, desktop-file-utils @@ -26,6 +27,7 @@ situation with students from primary or secondary level. %setup -q %patch0 -p1 %patch1 -p1 +%patch2 -p1 %build %configure @@ -63,6 +65,9 @@ rm -rf %{buildroot} %{_datadir}/applications/fedora-drgeo.desktop %changelog +* Tue Feb 08 2011 Jonathan Dieter - 1.1.0-18 +- Fix FTBFS (bug #631320) for GCC 4.5 using patch from openSUSE + * Tue Feb 08 2011 Fedora Release Engineering - 1.1.0-17 - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild