ragel/ragel.spec

87 lines
2.3 KiB
RPMSpec
Raw Normal View History

2020-06-22 14:50:57 +08:00
%bcond_with bootstrap
Name: ragel
Version: 7.0.4
Release: 1
2020-06-22 14:50:57 +08:00
Summary: Finite state machine compiler
# aapl/ is the LGPLv2+
License: MIT and LGPLv2+
URL: http://www.colm.net/open-source/%{name}/
Source0: https://www.colm.net/files/%{name}/%{name}-%{version}.tar.gz
Patch0: ragel-fallback-no-la.patch
Patch1: ragel-use-libdir.patch
2020-06-22 14:50:57 +08:00
BuildRequires: gcc
BuildRequires: gcc-c++
BuildRequires: autoconf
BuildRequires: automake
BuildRequires: libtool
BuildRequires: make
%if %{with bootstrap}
BuildRequires: kelbt
BuildRequires: ragel
%endif
2020-06-23 10:09:48 +08:00
BuildRequires: colm-devel
2020-06-22 14:50:57 +08:00
# Unfortunately, upstream doesn't exist and not possible to find version
Provides: bundled(aapl)
%description
Ragel compiles executable finite state machines from regular languages.
Ragel targets C, C++ and ASM. Ragel state machines can not only recognize
byte sequences as regular expression machines do, but can also execute code
at arbitrary points in the recognition of a regular language. Code embedding
is done using inline operators that do not disrupt the regular language syntax.
%package devel
Summary: Development libraries header files for %{name}
Requires: %{name}%{?_isa} = %{?epoch:%{epoch}:}%{version}-%{release}
%description devel
%{summary}.
%prep
%autosetup -p1
2020-06-22 14:50:57 +08:00
# Do not pollute with docs
sed -i -e "/dist_doc_DATA/d" Makefile.am
%build
autoreconf -vfi
%configure --disable-static --with-colm=%{_prefix} --disable-manual
2020-06-22 14:50:57 +08:00
%make_build
%install
%make_install
find %{buildroot}%{_libdir} -type f -name '*.la' -print -delete
install -p -m 0644 -D %{name}.vim %{buildroot}%{_datadir}/vim/vimfiles/syntax/%{name}.vim
%ldconfig_scriptlets
%files
%license COPYING
%{_bindir}/%{name}
%{_bindir}/%{name}-*
%{_mandir}/man1/%{name}.1*
%{_libdir}/libragel.so.*
%{_datarootdir}/%{name}.lm
%{_datarootdir}/out-go.lm
2020-06-22 14:50:57 +08:00
%dir %{_datadir}/vim
%dir %{_datadir}/vim/vimfiles
%dir %{_datadir}/vim/vimfiles/syntax
%{_datadir}/vim/vimfiles/syntax/%{name}.vim
%files devel
%{_libdir}/libragel.so
%changelog
* Thu Sep 14 2023 xu_ping <707078654@qq.com> - 7.0.4-1
- Upgrade version to 7.0.4
2020-09-21 20:41:51 +08:00
* Mon Sep 21 2020 Guoshuai Sun <sunguoshuai@huawei.com> - 7.0.0.12-2
- Fix ragel-d ragel-go ragel-java eg. command segfault
2020-06-22 14:50:57 +08:00
* Mon Jun 22 2020 Yikun Jiang <yikunkero@gmail.com> - 7.0.0.12-1
- Package init