From 11a6cf74f5e21b7af66c24f51f3909c00de86435 Mon Sep 17 00:00:00 2001 From: Jakub Bogusz Date: Tue, 28 Jan 2003 21:59:28 +0000 Subject: [PATCH] - moved data to /usr/share/bison (too many files for /usr/share/misc) - added unused patch - "__attribute__((__unused__))" was harmful for g++ - release 3 Changed files: bison-unused.patch -> 1.1 bison.spec -> 1.62 --- bison-unused.patch | 14 ++++++++++++++ bison.spec | 14 +++++++++----- 2 files changed, 23 insertions(+), 5 deletions(-) create mode 100644 bison-unused.patch diff --git a/bison-unused.patch b/bison-unused.patch new file mode 100644 index 0000000..ae4f0cf --- /dev/null +++ b/bison-unused.patch @@ -0,0 +1,14 @@ +--- bison-1.875/data/yacc.c.orig Sat Dec 28 09:36:02 2002 ++++ bison-1.875/data/yacc.c Tue Jan 28 20:57:50 2003 +@@ -1114,7 +1114,11 @@ + /* Suppress GCC warning that yyerrlab1 is unused when no action + invokes YYERROR. */ + #if defined (__GNUC_MINOR__) && 2093 <= (__GNUC__ * 1000 + __GNUC_MINOR__) ++ /* but it's harmful in C++ code ++ * (gcc 3.2.1 complained about erroneous yylerrsp declaration) */ ++# ifndef __cplusplus + __attribute__ ((__unused__)) ++# endif + #endif + + ]b4_location_if([ yylerrsp = yylsp; diff --git a/bison.spec b/bison.spec index f7c2614..c1e5070 100644 --- a/bison.spec +++ b/bison.spec @@ -9,16 +9,19 @@ Summary(tr): GNU ayr Summary(uk): Bison - ÇÅÎÅÒÁÔÏÒ ÐÁÒÓÅÒ¦× GNU Name: bison Version: 1.875 -Release: 2 +Release: 3 License: GPL Group: Development/Tools Source0: ftp://ftp.gnu.org/pub/gnu/%{name}/%{name}-%{version}.tar.bz2 Source1: %{name}.1.pl Patch0: %{name}-info.patch +Patch1: %{name}-unused.patch BuildRequires: texinfo BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) Obsoletes: yacc +%define pkgdatadir %{_datadir}/bison + %description Bison is a general purpose parser generator which converts a grammar description for an LALR context-free grammar into a C program to parse @@ -77,12 +80,13 @@ Bison - %prep %setup -q -%patch -p1 +%patch0 -p1 +%patch1 -p1 %build %configure %{__make} \ - pkgdatadir=%{_datadir}/misc + pkgdatadir=%{pkgdatadir} %install rm -rf $RPM_BUILD_ROOT @@ -90,7 +94,7 @@ install -d $RPM_BUILD_ROOT%{_mandir}/pl/man1 %{__make} install \ DESTDIR=$RPM_BUILD_ROOT \ - pkgdatadir=%{_datadir}/misc + pkgdatadir=%{pkgdatadir} install %{SOURCE1} $RPM_BUILD_ROOT%{_mandir}/pl/man1/bison.1 @@ -108,7 +112,7 @@ rm -rf $RPM_BUILD_ROOT %files -f %{name}.lang %defattr(644,root,root,755) %attr(755,root,root) %{_bindir}/bison -%{_datadir}/misc/* +%{pkgdatadir} %{_libdir}/lib*.a %{_mandir}/man1/* %lang(pl) %{_mandir}/pl/man1/* -- 2.44.0