Summary: public domain Berkeley LALR Yacc parser generator %global AppVersion 2.0 %global AppPatched 20240109 %global AltProgram byacc2 %global UseProgram yacc # Id: byacc.spec,v 1.75 2024/01/09 08:48:00 tom Exp Name: byacc Version: %{AppVersion}.%{AppPatched} Release: 1 License: Public Domain, MIT URL: https://invisible-island.net/%{name}/ Source0: https://invisible-mirror.net/archives/%{name}/%{name}-%{AppPatched}.tgz %description This package provides a parser generator utility that reads a grammar specification from a file and generates an LR(1) parser for it. The parsers consist of a set of LALR(1) parsing tables and a driver routine written in the C programming language. It has a public domain license which includes the generated C. %package -n byacc2 Summary: public domain Berkeley LALR Yacc parser generator with backtracking %description -n byacc2 This package provides a parser generator utility that reads a grammar specification from a file and generates an LR(1) parser for it. The parsers consist of a set of LALR(1) parsing tables and a driver routine written in the C programming language. It has a public domain license which includes the generated C. This package has the backtracking extension. %prep %global debug_package %{nil} %setup -q -n %{name}-%{AppPatched} %build %define my_srcdir .. %define CFG_OPTS \\\ --verbose \\\ --disable-echo \\\ --enable-stdnoreturn \\\ --target %{_target_platform} \\\ --prefix=%{_prefix} \\\ --srcdir=%{my_srcdir} \\\ --bindir=%{_bindir} \\\ --libdir=%{_libdir} \\\ --mandir=%{_mandir} %global _configure ../configure mkdir BUILD-byacc pushd BUILD-byacc CONFIGURE_TOP=%{my_srcdir} \ %configure %{CFG_OPTS} \ --program-prefix=b \ make popd mkdir BUILD-byacc2 pushd BUILD-byacc2 CONFIGURE_TOP=%{my_srcdir} \ %configure %{CFG_OPTS} \ --enable-btyacc \ --program-transform-name='s,\