mirror of
https://abf.rosa.ru/djam/libtgvoip.git
synced 2025-02-24 02:12:52 +00:00
76 lines
2 KiB
RPMSpec
76 lines
2 KiB
RPMSpec
%define debug_package %{nil}
|
|
|
|
%define major 2.2
|
|
%define libname %mklibname tgvoip %{major}
|
|
%define develname %mklibname -d tgvoip
|
|
|
|
Name: libtgvoip
|
|
Version: 2.2
|
|
Release: 1
|
|
Summary: VoIP library for Telegram clients
|
|
Source0: %{url}/archive/%{version}.tar.gz
|
|
Patch0: fix_gyp.patch
|
|
License: Public Domain
|
|
Group: Networking/Instant messaging
|
|
Url: https://github.com/grishka/%{name}
|
|
BuildRequires: libalsa-devel
|
|
BuildRequires: openssl-devel
|
|
BuildRequires: opus-devel
|
|
BuildRequires: pulseaudio-devel
|
|
BuildRequires: cmake
|
|
BuildRequires: make
|
|
BuildRequires: gyp
|
|
|
|
%description
|
|
%{summary}
|
|
|
|
#--------------------------------------------------------
|
|
|
|
%package -n %{libname}
|
|
Summary: VoIP library for Telegram clients
|
|
Group: System/Libraries
|
|
|
|
%description -n %{libname}
|
|
VoIP library for Telegram clients
|
|
|
|
%files -n %{libname}
|
|
%doc UNLICENSE
|
|
%{_libdir}/*.so*
|
|
|
|
#--------------------------------------------------------
|
|
|
|
%package -n %{develname}
|
|
Summary: VoIP library for Telegram clients
|
|
Group: System/Libraries
|
|
|
|
%description -n %{develname}
|
|
This package provides headers files for development.
|
|
|
|
%files -n %{develname}
|
|
%doc UNLICENSE
|
|
%{_includedir}/%{name}
|
|
|
|
#--------------------------------------------------------
|
|
|
|
%prep
|
|
%setup -q
|
|
%patch0 -p0
|
|
|
|
%build
|
|
export VERSION="%{version}"
|
|
gyp --format=cmake --depth=. --generator-output=. -Goutput_dir=out -Gconfig=Release %{name}.gyp
|
|
|
|
cd out/Release
|
|
cmake .
|
|
%make
|
|
cd ../..
|
|
|
|
%install
|
|
mkdir --parents %{buildroot}%{_libdir}
|
|
install --mode 0755 -p out/Release/lib.target/%{name}.so.%{version} %{buildroot}%{_libdir}
|
|
ln --symbolic %{name}.so.%{version} %{buildroot}%{_libdir}/%{name}.so.2
|
|
|
|
mkdir --parents "%{buildroot}%{_includedir}/%{name}/audio"
|
|
find . -maxdepth 1 -type f -name "*.h" -exec install --mode 0644 --preserve-timestamps '{}' %{buildroot}%{_includedir}/%{name} \;
|
|
find audio -maxdepth 1 -type f -name "*.h" -exec install --mode 0644 --preserve-timestamps '{}' %{buildroot}%{_includedir}/%{name}/audio \;
|
|
|