SHA256
10
0
forked from pool/lua-lgi

Factoryauto name detection fix

OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/lua-lgi?expand=0&rev=15
This commit is contained in:
Tomáš Chvátal
2017-07-15 07:33:35 +00:00
committed by Git OBS Bridge
parent 6d8bfbcf5d
commit 630264afd3

View File

@@ -18,15 +18,14 @@
%define flavor @BUILD_FLAVOR@
%define _name lgi
Name: %{flavor}-%{_name}
%define mod_name lgi
Version: 0.9.1
Release: 0
Summary: Lua bindings to GObject libraries
License: MIT
Group: System/Libraries
Url: https://github.com/pavouk/lgi
Source0: https://github.com/pavouk/%{_name}/archive/%{version}.tar.gz#/%{_name}-%{version}.tar.gz
Source0: https://github.com/pavouk/%{mod_name}/archive/%{version}.tar.gz#/%{mod_name}-%{version}.tar.gz
BuildRequires: %{flavor}-devel
BuildRequires: pkgconfig
BuildRequires: pkgconfig(gmodule-2.0)
@@ -34,11 +33,14 @@ BuildRequires: pkgconfig(gobject-introspection-1.0) >= 0.10.8
BuildRequires: pkgconfig(libffi)
Requires: %{flavor}
%if "%{flavor}" == "lua53"
Provides: lua-%{_name} = %{version}
Obsoletes: lua-%{_name} < %{version}
Provides: lua-%{mod_name} = %{version}
Obsoletes: lua-%{mod_name} < %{version}
%endif
%if "%{flavor}" == ""
Name: lua-%{mod_name}
ExclusiveArch: do_not_build
%else
Name: %{flavor}-%{mod_name}
%endif
%description
@@ -56,7 +58,7 @@ using gobject-introspection. Allows using GObject-based libraries
directly from Lua.
%prep
%setup -q -n %{_name}-%{version}
%setup -q -n %{mod_name}-%{version}
%build
make %{?_smp_mflags} \
@@ -71,9 +73,9 @@ make %{?_smp_mflags} \
%files
%doc LICENSE README.md
%{lua_archdir}/%{_name}/
%{lua_noarchdir}/%{_name}.lua
%{lua_noarchdir}/%{_name}/
%{lua_archdir}/%{mod_name}/
%{lua_noarchdir}/%{mod_name}.lua
%{lua_noarchdir}/%{mod_name}/
%files doc
%doc docs samples tools