%define luaver 5.1 %define lualibdir %{_libdir}/lua/%{luaver} %define luapkgdir %{_datadir}/lua/%{luaver} Name: lua-filesystem Version: 1.4.0 Release: 3%{?dist} Summary: File System Library for the Lua Programming Language Group: Development/Libraries License: MIT URL: http://www.keplerproject.org/luafilesystem/ Source0: http://luaforge.net/frs/download.php/3158/luafilesystem-1.4.0.tar.gz Patch0: luafilesystem-1.4.0-includefix.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: lua >= %{luaver}, lua-devel >= %{luaver} Requires: lua >= %{luaver} %description LuaFileSystem is a Lua library developed to complement the set of functions related to file systems offered by the standard Lua distribution. LuaFileSystem offers a portable way to access the underlying directory structure and file attributes. %prep %setup -q -n luafilesystem-%{version} %patch0 -p1 -b includefix %build make %{?_smp_mflags} PREFIX=%{_prefix} LUA_LIBDIR=%{lualibdir} CFLAGS="%{optflags} -fPIC" %install rm -rf $RPM_BUILD_ROOT make install PREFIX=$RPM_BUILD_ROOT%{_prefix} LUA_LIBDIR=$RPM_BUILD_ROOT%{lualibdir} %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root,-) %doc doc/us/* %doc README %{lualibdir}/* %changelog * Sat Apr 05 2008 Tim Niemueller - 1.4.0-3 - Add patch to add missing include of stdlib.h * Sat Apr 05 2008 Tim Niemueller - 1.4.0-2 - Pass correct CFLAGS to make to produce proper debuginfo * Fri Apr 04 2008 Tim Niemueller - 1.4.0-1 - Initial package