%define staticdevelname %mklibname bison -d -s %define bootstrap 0 %{?_without_bootstrap: %global bootstrap 0} %{?_with_bootstrap: %global bootstrap 1} Summary: A GNU general-purpose parser generator Name: bison Version: 2.4.3 Release: %mkrel 2 License: GPL Group: Development/Other URL: http://www.gnu.org/software/bison/bison.html Source0: ftp://ftp.gnu.org/pub/gnu/bison/bison-%{version}.tar.bz2 Patch0: bison-1.32-extfix.patch Requires(post): info-install Requires(preun):info-install Requires: m4 >= 1.4 BuildRequires: help2man %if !%bootstrap %ifnarch %mips %arm BuildRequires: java-1.6.0-openjdk-devel %endif %endif BuildRequires: m4 >= 1.4 Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot %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 that grammar. Bison can be used to develop a wide range of language parsers, from ones used in simple desk calculators to complex programming languages. Bison is upwardly compatible with Yacc, so any correctly written Yacc grammar should work with Bison without any changes. If you know Yacc, you shouldn't have any trouble using Bison (but you do need to be very proficient in C programming to be able to use Bison). Many programs use Bison as part of their build process. Bison is only needed on systems that are used for development. If your system will be used for C development, you should install Bison since it is used to build many C programs. %package -n %{staticdevelname} Summary: Static development library for using Bison-generated parsers Group: Development/C Requires: bison = %{version} Provides: bison-devel-static = %{version} %description -n %{staticdevelname} This package contains the static -ly library sometimes used by programs using Bison-generated parsers. If you are developing programs using Bison, you might want to link with this library. This library is not required by all Bison-generated parsers, but may be employed by simple programs to supply minimal support for the generated parsers. %prep %setup -q %patch0 -p1 -b .extfix %build %configure2_5x %make %check %make check %install rm -rf %{buildroot} %makeinstall_std mv %{buildroot}%{_bindir}/yacc %{buildroot}%{_bindir}/yacc.bison %find_lang %{name} %find_lang %{name}-runtime cat %name-runtime.lang >> %name.lang %post %_install_info %{name}.info %{_sbindir}/update-alternatives --install %{_bindir}/yacc yacc %{_bindir}/yacc.bison 10 %preun %_remove_install_info %{name}.info if [ $1 -eq 0 ]; then %{_sbindir}/update-alternatives --remove yacc %{_bindir}/yacc.bison fi %clean rm -rf %{buildroot} %files -f %{name}.lang %defattr(-,root,root) %doc COPYING NEWS README %{_bindir}/* %dir %{_datadir}/bison %{_datadir}/bison/* %{_datadir}/aclocal/* %{_infodir}/bison.info* %{_mandir}/man1/* %files -n %{staticdevelname} %defattr(-,root,root) %{_libdir}/liby.a %changelog * Sun Jan 09 2011 blino <blino> 2.4.3-2.mga1 + Revision: 2170 - rebuild with java * Sat Jan 08 2011 blino <blino> 2.4.3-1.mga1 + Revision: 404 - bootstrap bison - add bootstrap flag - remove obsolete stuff - imported package bison * Fri Aug 06 2010 Funda Wang <fwang@mandriva.org> 2.4.3-1mdv2011.0 + Revision: 567145 - New version 2.4.3 * Sun Mar 21 2010 Funda Wang <fwang@mandriva.org> 2.4.2-1mdv2010.1 + Revision: 525959 - output test do not need any more - subpipe patch do not apply - new version 2.4.2 * Sun Mar 14 2010 Oden Eriksson <oeriksson@mandriva.com> 2.4.1-5mdv2010.1 + Revision: 518986 - rebuild * Sun Oct 04 2009 Oden Eriksson <oeriksson@mandriva.com> 2.4.1-4mdv2010.0 + Revision: 453330 - package the static lib (requested by mnaud) * Fri Sep 25 2009 Olivier Blin <oblin@mandriva.com> 2.4.1-3mdv2010.0 + Revision: 448805 - disable java on mips & arm (from Arnaud Patard) * Sun Aug 09 2009 Oden Eriksson <oeriksson@mandriva.com> 2.4.1-2mdv2010.0 + Revision: 413170 - rebuild * Tue Dec 30 2008 Oden Eriksson <oeriksson@mandriva.com> 2.4.1-1mdv2009.1 + Revision: 321329 - 2.4.1 - sync with fedora (P2 + deps) - fix build with -Wformat-security (P3) * Sat Nov 29 2008 Christiaan Welvaart <spturtle@mandriva.org> 2.4-1mdv2009.1 + Revision: 308164 - 2.4 - rediff patch0 - patch1: disable test for not overwriting input file - add buildrequires: help2man * Mon Jun 16 2008 Thierry Vignaud <tv@mandriva.org> 2.3-6mdv2009.0 + Revision: 220482 - rebuild * Sun Jan 06 2008 Stefan van der Eijk <stefan@mandriva.org> 2.3-5mdv2008.1 + Revision: 146027 - rebuild to fix error: unpacking of archive failed on file /usr/bin/bison;4780a23e: cpio: read + Olivier Blin <oblin@mandriva.com> - restore BuildRoot + Thierry Vignaud <tv@mandriva.org> - kill re-definition of %%buildroot on Pixel's request * Mon Mar 19 2007 Thierry Vignaud <tvignaud@mandriva.com> 2.3-4mdv2007.1 + Revision: 146590 - do not package big ChangeLog * Sat Jan 13 2007 Götz Waschk <waschk@mandriva.org> 2.3-3mdv2007.1 + Revision: 108197 - fix pre and preun requires - use check macro - use find-lang + Oden Eriksson <oeriksson@mandriva.com> - bzip2 cleanup * Wed Oct 11 2006 Oden Eriksson <oeriksson@mandriva.com> 2.3-2mdv2007.1 + Revision: 63270 - bunzip patches - Import bison * Fri Jul 21 2006 Emmanuel Andry <eandry@mandriva.org> 2.3-1mdv2007.0 - 2.3 * Sat Jun 03 2006 Rafael Garcia-Suarez <rgarciasuarez@mandriva.com> 2.2-1mdv2007.0 - 2.2 * Tue May 16 2006 Rafael Garcia-Suarez <rgarciasuarez@mandriva.com> 2.1-3mdk - Rebuild (missing binary) * Sat May 13 2006 Stefan van der Eijk <stefan@eijk.nu> 2.1-2mdk - rebuild for sparc * Thu Oct 06 2005 Rafael Garcia-Suarez <rgarciasuarez@mandriva.com> 2.1-1mdk - New version * Fri Aug 12 2005 Nicolas Lécureuil <neoclust@mandriva.org> 2.0-3mdk - fix rpmlint errors (PreReq) * Fri Aug 12 2005 Nicolas Lécureuil <neoclust@mandriva.org> 2.0-2mdk - fix rpmlint errors (PreReq) * Wed Jan 05 2005 Rafael Garcia-Suarez <rgarciasuarez@mandrakesoft.com> 2.0-1mdk - New version - Add docs * Thu Dec 23 2004 Abel Cheung <deaddog@mandrake.org> 1.875e-1mdk - New version - Fix URL - Make it an alternative to byacc - make check * Fri Jul 30 2004 Per Ãyvind Karlsen <peroyvind@linux-mandrake.com> 1.875d-1mdk - 1.875d - drop P1 (fixed upstream) - cosmetics * Wed Jun 02 2004 Robert Vojta <robert.vojta@mandrake.org> 1.875-5mdk - Requires m4 package (#9922)