Add rpm-macros file, providing packaging macros for lua add-ons (#1447324)
This commit is contained in:
parent
b7447739b8
commit
9774218a76
15
lua.spec
15
lua.spec
@ -6,10 +6,13 @@
|
|||||||
%global bootstrap_major_version 5.2
|
%global bootstrap_major_version 5.2
|
||||||
%global bootstrap_version %{bootstrap_major_version}.3
|
%global bootstrap_version %{bootstrap_major_version}.3
|
||||||
|
|
||||||
|
# Place rpm-macros into proper location.
|
||||||
|
%global macrosdir %(d=%{_rpmconfigdir}/macros.d; [ -d $d ] || d=%{_sysconfdir}/rpm; echo $d)
|
||||||
|
|
||||||
|
|
||||||
Name: lua
|
Name: lua
|
||||||
Version: %{major_version}.4
|
Version: %{major_version}.4
|
||||||
Release: 1%{?dist}
|
Release: 2%{?dist}
|
||||||
Summary: Powerful light-weight programming language
|
Summary: Powerful light-weight programming language
|
||||||
Group: Development/Languages
|
Group: Development/Languages
|
||||||
License: MIT
|
License: MIT
|
||||||
@ -23,6 +26,8 @@ Source2: http://www.lua.org/ftp/lua-%{bootstrap_version}.tar.gz
|
|||||||
Source3: http://www.lua.org/tests/lua-%{version}-tests.tar.gz
|
Source3: http://www.lua.org/tests/lua-%{version}-tests.tar.gz
|
||||||
# multilib
|
# multilib
|
||||||
Source4: luaconf.h
|
Source4: luaconf.h
|
||||||
|
# rpm-macro
|
||||||
|
Source1000: macros.lua.in
|
||||||
Patch0: %{name}-5.3.0-autotoolize.patch
|
Patch0: %{name}-5.3.0-autotoolize.patch
|
||||||
Patch1: %{name}-5.3.0-idsize.patch
|
Patch1: %{name}-5.3.0-idsize.patch
|
||||||
#Patch2: %%{name}-5.3.0-luac-shared-link-fix.patch
|
#Patch2: %%{name}-5.3.0-luac-shared-link-fix.patch
|
||||||
@ -168,6 +173,10 @@ rm -rf $RPM_BUILD_ROOT/installdir
|
|||||||
popd
|
popd
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
|
# Install rpm-macro
|
||||||
|
mkdir -p $RPM_BUILD_ROOT/%{macrosdir}
|
||||||
|
sed -e 's!@major_version@!%{major_version}!g' < %{SOURCE1000} > $RPM_BUILD_ROOT/%{macrosdir}/macros.lua
|
||||||
|
|
||||||
%files
|
%files
|
||||||
%{!?_licensedir:%global license %%doc}
|
%{!?_licensedir:%global license %%doc}
|
||||||
%license mit.txt
|
%license mit.txt
|
||||||
@ -196,12 +205,16 @@ popd
|
|||||||
%{_includedir}/l*.hpp
|
%{_includedir}/l*.hpp
|
||||||
%{_libdir}/liblua.so
|
%{_libdir}/liblua.so
|
||||||
%{_libdir}/pkgconfig/*.pc
|
%{_libdir}/pkgconfig/*.pc
|
||||||
|
%{macrosdir}/macros.lua
|
||||||
|
|
||||||
%files static
|
%files static
|
||||||
%{_libdir}/*.a
|
%{_libdir}/*.a
|
||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Wed May 24 2017 Björn Esser <besser82@fedoraproject.org> - 5.3.4-2
|
||||||
|
- Add rpm-macros file, providing packaging macros for lua add-ons (#1447324)
|
||||||
|
|
||||||
* Thu Feb 9 2017 Tom Callaway <spot@fedoraproject.org> 5.3.4-1
|
* Thu Feb 9 2017 Tom Callaway <spot@fedoraproject.org> 5.3.4-1
|
||||||
- update to 5.3.4
|
- update to 5.3.4
|
||||||
|
|
||||||
|
14
macros.lua.in
Normal file
14
macros.lua.in
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
%luaver @major_version@
|
||||||
|
%luanext %(echo '%{luaver}' | %{__awk} '{ sum = $1 + 0.1; print sum }')
|
||||||
|
|
||||||
|
%lualibdir %{_libdir}/lua/%{luaver}
|
||||||
|
%luapkgdir %{_datadir}/lua/%{luaver}
|
||||||
|
|
||||||
|
%lua_requires \
|
||||||
|
%if 0%{?fedora} || 0%{?rhel} >= 7 \
|
||||||
|
Requires: lua(abi) = %{luaver} \
|
||||||
|
%else \
|
||||||
|
Requires: lua >= %{luaver} \
|
||||||
|
Requires: lua < %{luanext} \
|
||||||
|
%endif \
|
||||||
|
%{nil}
|
Loading…
Reference in New Issue
Block a user