diff --git a/_multibuild b/_multibuild index a01285a..8711cd1 100644 --- a/_multibuild +++ b/_multibuild @@ -1,4 +1,5 @@ lua51 lua53 +test diff --git a/lua-loadkit.spec b/lua-loadkit.spec index 90c2340..a0b7521 100644 --- a/lua-loadkit.spec +++ b/lua-loadkit.spec @@ -33,16 +33,22 @@ Group: Development/Libraries/Other URL: https://github.com/leafo/loadkit Source: https://github.com/leafo/%{mod_name}/archive/v%{version}.tar.gz#/%{mod_name}-%{version}.tar.gz BuildRequires: %{flavor}-moonscript -BuildRequires: %{flavor}-busted BuildRequires: %{flavor}-devel Requires: %{flavor} +%if %{with test} +BuildRequires: %{flavor}-busted +%endif BuildArch: noarch %if "%{flavor}" == "" Name: lua-loadkit ExclusiveArch: do_not_build %else +%if %{with test} +Name: %{flavor}-loadkit-test +%else Name: %{flavor}-loadkit %endif +%endif %description Loadkit lets you register new file extension handlers that @@ -53,16 +59,22 @@ of any extension using the current search path. %setup -q -n %{mod_name}-%{version} %build -# moonc loadkit.moon ... missing alt_getopt +moonc loadkit.moon %install +%if ! %{with test} install -v -D -m 0644 -t %{buildroot}%{lua_noarchdir} -p loadkit.lua +%endif %check +%if %{with test} busted +%endif +%if ! %{with test} %files %doc README.md %{lua_noarchdir}/%{mod_name}* +%endif %changelog