lua-socket/lua-socket.spec
Funda Wang 0cdc609241 3.0.0
(cherry picked from commit 04a85f342faeea4d728d4b638ca3f01cbbcdef42)
2024-11-14 16:45:37 +08:00

62 lines
1.8 KiB
RPMSpec

Name: lua-socket
Version: 3.0.0
Release: 1
Summary: Network support for the Lua language
License: MIT
URL: https://lunarmodules.github.io/luasocket/
Source0: https://github.com/lunarmodules/luasocket/archive/refs/tags/v%{version}.tar.gz
BuildRequires: gcc lua lua-devel /usr/bin/iconv
%{?lua_requires}
%description
LuaSocket is a Lua extension library that is composed by two parts: a C core
that provides support for the TCP and UDP transport layers, and a set of Lua
modules that add support for functionality commonly needed by applications
that deal with the Internet.
%package devel
Summary: Development files for %{name}
Requires: %{name} = %{version}-%{release}
%description devel
Header files and libraries for building an extension library for the
Lua using %{name}
%package_help
%prep
%autosetup -n luasocket-%{version} -p1
%build
%make_build LUAV=%lua_version CFLAGS_linux="%{build_cflags} -fPIC -I%{_includedir} -DLUASOCKET_NODEBUG -DLUA_COMPAT_APIINTCASTS" LDFLAGS="%{?__global_ldflags} -shared -o " linux
/usr/bin/iconv -f ISO8859-1 -t UTF8 LICENSE >LICENSE.UTF8
mv -f LICENSE.UTF8 LICENSE
%install
make install-unix OPTFLAGS="%{optflags}" INSTALL_TOP=$RPM_BUILD_ROOT \
INSTALL_TOP_CDIR=$RPM_BUILD_ROOT%{lua_libdir} \
INSTALL_TOP_LDIR=$RPM_BUILD_ROOT%{lua_pkgdir}
install -d $RPM_BUILD_ROOT%{_includedir}/luasocket
install -p src/*.h $RPM_BUILD_ROOT%{_includedir}/luasocket
%files
%license LICENSE
%{lua_libdir}/*
%{lua_pkgdir}/*
%files devel
%{_includedir}/luasocket
%files help
%doc README.md docs/*
%changelog
* Fri Nov 01 2024 Funda Wang <fundawang@yeah.net> - 3.0.0-1
- 3.0.0 final
- rebuild for lua 5.4
* Mon Sep 16 2019 openEuler Buildteam <buildteam@openeuler.org> - 3.0-0.19
- Package init