File nginx-module-rtmp.spec of Package nginx-module-rtmp
%define project_name nginx-module-rtmp
Name: nginx-module-rtmp
Version: 1.2.2
Release: 1%{?dist}
Summary: NGINX-based Media Streaming Server
License: BSD-2-Clause
Group: Productivity/Networking/Web/Servers
URL: https://github.com/arut/nginx-rtmp-module/
Source0: https://github.com/arut/nginx-rtmp-module/archive/refs/tags/v1.2.2.tar.gz
BuildRequires: gettext
BuildRequires: libtool
BuildRequires: nginx-source
%description
Module for a NGINX-based Media Streaming Server
The module provides HLS and MPEG-DASH live streaming capabilities for those who want a lightweight solution based on the HTTP protocol. The stream is published in the MPEG-TS format over HTTP. This makes it possible to use all the power and flexibility of nginx HTTP configurations including SSL, access control, logging, request limiting etc. MPEG-TS is a widely adopted, well known and well documented streaming format.
%prep
mkdir %{project_name}
tar -xf %{SOURCE0} --strip-components=1 -C %{project_name}
cp -r %{_prefix}/src/nginx .
%build
cd nginx
%{ngx_configure} --add-dynamic-module=../%{project_name}
%make_build modules
%install
mkdir -p %{buildroot}%{ngx_module_dir}
install -Dpm0755 nginx/objs/ngx_rtmp_module.so %{buildroot}%{ngx_module_dir}
%files
%license %{project_name}/LICENSE
%doc %{project_name}/doc/*.md
%{ngx_module_dir}/ngx_rtmp_module.so
%changelog
* Wed Jan 11 2023 Atikon <it@atikon.com> 1.2.2-1
- Initial RPM release