mirror of
https://abf.rosa.ru/djam/nghttp3.git
synced 2025-02-22 18:03:07 +00:00
130 lines
3.4 KiB
RPMSpec
130 lines
3.4 KiB
RPMSpec
%define debug %nil
|
|
%define debug_package %nil
|
|
%define major 9
|
|
%define asiomajor 1
|
|
%define libname %mklibname %{name}_ %{major}
|
|
%define devname %mklibname %{name} -d
|
|
%define sdevname %mklibname %{name} -d -s
|
|
%define llvm_ver llvm17
|
|
%define llvm_path /opt/%{llvm_ver}
|
|
|
|
%global optflags %(echo %{optflags} | sed -e 's/-ffat-lto-objects//g' -e 's/-fvar-tracking-assignments//g')
|
|
|
|
#define __noautoprov 'nghttp3.so'
|
|
|
|
Summary: HTTP/3 library written in C
|
|
Name: nghttp3
|
|
Version: 1.8.0
|
|
Release: 1
|
|
License: MIT
|
|
Group: Networking/WWW
|
|
URL: https://nghttp2.org/nghttp3
|
|
Source0: https://github.com/ngtcp2/nghttp3/releases/download/v%{version}/%{name}-%{version}.tar.gz
|
|
BuildRequires: bison
|
|
BuildRequires: cmake >= 3.0
|
|
BuildRequires: libxml2-utils
|
|
%if %{mdvver} >= 201910
|
|
BuildRequires: python3-cython
|
|
BuildRequires: python3-setuptools
|
|
BuildRequires: python3-sphinx
|
|
BuildRequires: pkgconfig(python3)
|
|
%else
|
|
BuildRequires: python-cython
|
|
BuildRequires: python-setuptools
|
|
BuildRequires: python-sphinx
|
|
BuildRequires: pkgconfig(python)
|
|
%endif
|
|
BuildRequires: %{llvm_ver}
|
|
BuildRequires: stdc++-gcc10-devel
|
|
BuildRequires: ruby
|
|
BuildRequires: boost-devel >= 1.54.0
|
|
BuildRequires: jemalloc-devel
|
|
BuildRequires: pkgconfig(cunit) >= 2.1
|
|
BuildRequires: pkgconfig(jansson) >= 2.5
|
|
BuildRequires: pkgconfig(libcares) >= 1.7.5
|
|
BuildRequires: pkgconfig(libev) >= 4.11
|
|
BuildRequires: pkgconfig(libevent) >= 2.0.8
|
|
BuildRequires: pkgconfig(libxml-2.0)
|
|
BuildRequires: pkgconfig(openssl) >= 1.0.1
|
|
BuildRequires: pkgconfig(zlib)
|
|
|
|
%description
|
|
Nghttp3 is a library implementing the Hypertext Transfer Protocol version 3
|
|
(HTTP/3) protocol in C; it implements also the header compression algorithm
|
|
HPACK in C.
|
|
This package contains the HTTP/3 client, server and proxy programs, and also
|
|
the encoder and decoder one.
|
|
|
|
#-----------------------------------------------------------------------------
|
|
|
|
%package -n %{libname}
|
|
Summary: A library implementing the HTTP/3 protocol
|
|
Group: System/Libraries
|
|
|
|
%description -n %{libname}
|
|
Nghttp3 is a library implementing the Hypertext Transfer Protocol version 3
|
|
(HTTP/3) protocol in C.
|
|
This package contains the main library.
|
|
|
|
%files -n %{libname}
|
|
%doc COPYING
|
|
%{_libdir}/libnghttp3.so.%{major}*
|
|
|
|
#-----------------------------------------------------------------------------
|
|
|
|
%package -n %{devname}
|
|
Summary: Files needed for building applications with %{name}
|
|
Group: Development/C
|
|
Requires: %{libname} = %{EVRD}
|
|
Provides: %{name}-devel = %{EVRD}
|
|
|
|
%description -n %{devname}
|
|
The libnghttp3-devel package includes libraries and header files needed
|
|
for building applications with libnghttp3.
|
|
|
|
%files -n %{devname}
|
|
%doc COPYING
|
|
%{_includedir}/%{name}
|
|
%{_libdir}/pkgconfig/*.pc
|
|
%{_libdir}/*.so
|
|
%{_docdir}/%{name}/README.rst
|
|
|
|
|
|
#-----------------------------------------------------------------------------
|
|
|
|
%package -n %{sdevname}
|
|
Summary: Static library from %{name}
|
|
Group: Development/C
|
|
Requires: %{devname} = %{EVRD}
|
|
|
|
%description -n %{sdevname}
|
|
Static library from %{name}
|
|
|
|
|
|
%files -n %{sdevname}
|
|
%doc COPYING
|
|
%{_libdir}/*.a
|
|
|
|
#-----------------------------------------------------------------------------
|
|
|
|
%prep
|
|
%setup -q
|
|
|
|
|
|
%build
|
|
export LDFLAGS="-lstdc++-gcc10"
|
|
export CC=%{llvm_path}/bin/clang
|
|
export CXX=%{llvm_path}/bin/clang++
|
|
export CPP=%{llvm_path}/bin/clang-cpp
|
|
export CFLAGS="-I/usr/include/libstdc++-gcc10 -I/usr/include/libstdc++-gcc10/%{_host}"
|
|
export CXXFLAGS="-I/usr/include/libstdc++-gcc10 -I/usr/include/libstdc++-gcc10/%{_host}"
|
|
|
|
autoreconf -if
|
|
%configure
|
|
%make
|
|
|
|
%install
|
|
%makeinstall_std
|
|
|
|
%check
|
|
%make check
|