%define luaver 5.1 %define lualibdir %{_libdir}/lua/%{luaver} %define luapkgdir %{_datadir}/lua/%{luaver} Name: lua-coxpcall Version: 1.13.0 Release: 1%{?dist} Summary: Coroutine safe xpcall and pcall versions for Lua Group: Development/Libraries License: MIT URL: http://coxpcall.luaforge.net/ Source0: http://luaforge.net/frs/download.php/3406/coxpcall-1.13.0.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch BuildRequires: lua >= %{luaver}, lua-devel >= %{luaver} Requires: lua >= %{luaver} %description Coxpcall encapsulates the protected calls with a coroutine based loop, so errors can be handled without the usual pcall/xpcall issues with coroutines. Using Coxpcall usually consists in simply loading the module and then replacing Lua pcall and xpcall by copcall and coxpcall. %prep %setup -q -n coxpcall-%{version} %build %install rm -rf %{buildroot} mkdir -p %{buildroot}%{luapkgdir} make install LUA_DIR=%{buildroot}%{luapkgdir} %clean rm -rf %{buildroot} %files %defattr(-,root,root,-) %doc README doc/us/* %{luapkgdir}/* %changelog * Wed Oct 20 2010 Tim Niemueller - 1.13.0-1 - Initial package