aboutsummaryrefslogtreecommitdiff
path: root/contrib/byacc/package/byacc.spec
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/byacc/package/byacc.spec')
-rw-r--r--contrib/byacc/package/byacc.spec74
1 files changed, 41 insertions, 33 deletions
diff --git a/contrib/byacc/package/byacc.spec b/contrib/byacc/package/byacc.spec
index 64fea872c68b..6c9e43c4c149 100644
--- a/contrib/byacc/package/byacc.spec
+++ b/contrib/byacc/package/byacc.spec
@@ -1,17 +1,18 @@
-Summary: byacc - public domain Berkeley LALR Yacc parser generator
-%define AppProgram byacc
-%define AltProgram btyacc
-%define AppVersion 20200330
-%define UseProgram yacc
-# $Id: byacc.spec,v 1.49 2020/03/30 23:31:42 tom Exp $
-Name: %{AppProgram}
-Version: %{AppVersion}
+Summary: public domain Berkeley LALR Yacc parser generator
+
+%global AppVersion 2.0
+%global AppPatched 20230201
+
+%global AltProgram byacc2
+%global UseProgram yacc
+
+# $Id: byacc.spec,v 1.70 2023/02/02 00:12:06 tom Exp $
+Name: byacc
+Version: %{AppVersion}.%{AppPatched}
Release: 1
License: Public Domain, MIT
-Group: Applications/Development
-URL: ftp://invisible-island.net/%{AppProgram}
-Source0: %{AppProgram}-%{AppVersion}.tgz
-Packager: Thomas E. Dickey <dickey@invisible-island.net>
+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
@@ -20,10 +21,10 @@ 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 btyacc
-Summary: Curses library with POSIX thread support.
+%package -n byacc2
+Summary: public domain Berkeley LALR Yacc parser generator with backtracking
-%description -n btyacc
+%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
@@ -34,15 +35,16 @@ This package has the backtracking extension.
%prep
-%define debug_package %{nil}
+%global debug_package %{nil}
-%setup -q -n %{AppProgram}-%{AppVersion}
+%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} \\\
@@ -57,18 +59,16 @@ pushd BUILD-byacc
CONFIGURE_TOP=%{my_srcdir} \
%configure %{CFG_OPTS} \
--program-prefix=b \
- --program-transform-name='s,\^,b,'
make
popd
-mkdir BUILD-btyacc
-pushd BUILD-btyacc
+mkdir BUILD-byacc2
+pushd BUILD-byacc2
CONFIGURE_TOP=%{my_srcdir} \
%configure %{CFG_OPTS} \
--enable-btyacc \
- --program-prefix=bt \
- --with-max-table-size=18000 \
- --program-transform-name='s,\^,bt,'
+ --program-transform-name='s,\<yacc,byacc2,g' \
+ --with-max-table-size=123456 \
make
popd
@@ -77,10 +77,10 @@ popd
pushd BUILD-byacc
make install DESTDIR=$RPM_BUILD_ROOT
-( cd $RPM_BUILD_ROOT%{_bindir} && ln -vs %{AppProgram} %{UseProgram} )
+( cd $RPM_BUILD_ROOT%{_bindir} && ln -vs %{name} %{UseProgram} )
popd
-pushd BUILD-btyacc
+pushd BUILD-byacc2
make install DESTDIR=$RPM_BUILD_ROOT
popd
@@ -88,19 +88,27 @@ popd
[ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
%files
-%defattr(-,root,root)
-%{_prefix}/bin/%{AppProgram}
-%{_prefix}/bin/%{UseProgram}
-%{_mandir}/man1/%{AppProgram}.*
-
-%files -n btyacc
-%defattr(-,root,root)
-%{_prefix}/bin/%{AltProgram}
+%doc ACKNOWLEDGEMENTS CHANGES NEW_FEATURES NOTES NO_WARRANTY README
+%license LICENSE
+%{_bindir}/%{name}
+%{_bindir}/%{UseProgram}
+%{_mandir}/man1/%{name}.*
+
+%files -n byacc2
+%doc ACKNOWLEDGEMENTS CHANGES NEW_FEATURES NOTES NO_WARRANTY README README.BTYACC
+%license LICENSE
+%{_bindir}/%{AltProgram}
%{_mandir}/man1/%{AltProgram}.*
%changelog
# each patch should add its ChangeLog entries here
+* Sun Jan 09 2022 Thomas Dickey
+- rpmlint
+
+* Sat Jan 01 2022 Thomas Dickey
+- rename btyacc package to byacc2 to co-exist with traditional btyacc
+
* Fri May 25 2018 Thomas Dickey
- add btyacc package