2015-02-16 09:13:06 +01:00
|
|
|
#
|
|
|
|
# spec file for package nghttp2
|
|
|
|
#
|
|
|
|
# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
|
|
|
|
#
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
|
|
|
|
2015-11-01 20:46:13 +01:00
|
|
|
%define soname libnghttp2
|
|
|
|
%define sover 14
|
|
|
|
%define soname_asio libnghttp2_asio
|
|
|
|
%define sover_asio 1
|
2015-02-16 09:13:06 +01:00
|
|
|
Name: nghttp2
|
2015-12-23 18:53:28 +01:00
|
|
|
Version: 1.6.0
|
2015-02-16 09:13:06 +01:00
|
|
|
Release: 0
|
|
|
|
Summary: Implementation of Hypertext Transfer Protocol version 2 in C
|
|
|
|
License: MIT
|
2015-03-06 19:20:11 +01:00
|
|
|
Group: Development/Libraries/C and C++
|
2015-02-16 09:13:06 +01:00
|
|
|
Url: https://nghttp2.org/
|
|
|
|
Source: https://github.com/tatsuhiro-t/%{name}/releases/download/v%{version}/%{name}-%{version}.tar.xz
|
2015-11-01 20:46:13 +01:00
|
|
|
Source1: baselibs.conf
|
|
|
|
# PATCH-FIX-OPENSUSE nghttp2-remove-python-build.patch
|
|
|
|
Patch0: %{name}-remove-python-build.patch
|
2015-07-16 14:54:32 +02:00
|
|
|
BuildRequires: autoconf
|
|
|
|
BuildRequires: automake
|
2015-02-16 09:13:06 +01:00
|
|
|
BuildRequires: boost-devel
|
|
|
|
BuildRequires: gcc-c++
|
2015-11-16 18:23:15 +01:00
|
|
|
BuildRequires: jemalloc-devel
|
2015-07-16 14:54:32 +02:00
|
|
|
BuildRequires: libtool
|
2015-02-16 09:13:06 +01:00
|
|
|
BuildRequires: pkg-config
|
2015-04-04 19:11:33 +02:00
|
|
|
BuildRequires: python-Cython
|
2015-02-16 09:13:06 +01:00
|
|
|
BuildRequires: python-Sphinx
|
2015-07-16 14:54:32 +02:00
|
|
|
BuildRequires: python-setuptools
|
2015-02-16 09:13:06 +01:00
|
|
|
BuildRequires: pkgconfig(cunit)
|
|
|
|
BuildRequires: pkgconfig(jansson)
|
2015-11-16 18:23:15 +01:00
|
|
|
BuildRequires: pkgconfig(libev)
|
|
|
|
BuildRequires: pkgconfig(libspdylay)
|
2015-02-16 09:13:06 +01:00
|
|
|
BuildRequires: pkgconfig(libxml-2.0)
|
|
|
|
BuildRequires: pkgconfig(openssl)
|
|
|
|
BuildRequires: pkgconfig(python)
|
|
|
|
BuildRequires: pkgconfig(zlib)
|
|
|
|
|
|
|
|
%description
|
2015-11-01 20:46:13 +01:00
|
|
|
This is an implementation of Hypertext Transfer Protocol version 2.
|
2015-02-16 09:13:06 +01:00
|
|
|
|
2015-11-01 20:46:13 +01:00
|
|
|
The framing layer of HTTP/2 is implemented as a form of reusable C
|
|
|
|
library. On top of that, we have implemented HTTP/2 client, server
|
|
|
|
and proxy. We have also developed load test and benchmarking tool
|
|
|
|
for HTTP/2.
|
2015-02-16 09:13:06 +01:00
|
|
|
|
|
|
|
HPACK encoder and decoder are available as public API.
|
|
|
|
|
2015-11-01 20:46:13 +01:00
|
|
|
%package -n %{soname}-%{sover}
|
|
|
|
Summary: Shared library for nghttp2
|
2015-02-16 09:13:06 +01:00
|
|
|
Group: System/Libraries
|
|
|
|
|
2015-11-01 20:46:13 +01:00
|
|
|
%description -n %{soname}-%{sover}
|
|
|
|
Shared C libraries for implementation of
|
|
|
|
Hypertext Transfer Protocol version 2.
|
2015-02-16 09:13:06 +01:00
|
|
|
|
2015-11-01 20:46:13 +01:00
|
|
|
%package -n %{soname_asio}%{sover_asio}
|
|
|
|
Summary: Shared library for nghttp2
|
2015-02-16 09:13:06 +01:00
|
|
|
Group: System/Libraries
|
|
|
|
|
2015-11-01 20:46:13 +01:00
|
|
|
%description -n %{soname_asio}%{sover_asio}
|
|
|
|
Shared librarios for asynchronous implementation of
|
|
|
|
Hypertext Transfer Protocol version 2.
|
2015-02-16 09:13:06 +01:00
|
|
|
|
2015-04-04 19:11:33 +02:00
|
|
|
%package -n python-%{name}
|
2015-11-01 20:46:13 +01:00
|
|
|
Summary: Python bindings for nghttp2
|
2015-04-04 19:11:33 +02:00
|
|
|
Group: Development/Libraries/Python
|
|
|
|
|
|
|
|
%description -n python-%{name}
|
2015-11-01 20:46:13 +01:00
|
|
|
Python bindings for implementation of
|
|
|
|
Hypertext Transfer Protocol version 2.
|
2015-04-04 19:11:33 +02:00
|
|
|
|
2015-11-01 20:46:13 +01:00
|
|
|
%package -n %{soname}-devel
|
|
|
|
Summary: Development files for nghttp2
|
2015-02-16 09:13:06 +01:00
|
|
|
Group: Development/Languages/C and C++
|
2015-11-01 20:46:13 +01:00
|
|
|
Requires: %{soname_asio}%{sover_asio} = %{version}
|
2015-03-06 19:20:11 +01:00
|
|
|
Provides: %{name}-devel
|
2015-02-16 09:13:06 +01:00
|
|
|
|
2015-11-01 20:46:13 +01:00
|
|
|
%description -n %{soname}-devel
|
|
|
|
Development files for usage with libnghttp2, which implements
|
|
|
|
Hypertext Transfer Protocol version 2.
|
2015-02-16 09:13:06 +01:00
|
|
|
|
2015-11-01 20:46:13 +01:00
|
|
|
%package -n %{soname_asio}-devel
|
|
|
|
Summary: Development files for nghttp2
|
2015-02-16 09:13:06 +01:00
|
|
|
Group: Development/Languages/C and C++
|
2015-11-01 20:46:13 +01:00
|
|
|
Requires: %{soname_asio}%{sover_asio} = %{version}
|
2015-02-16 09:13:06 +01:00
|
|
|
|
2015-11-01 20:46:13 +01:00
|
|
|
%description -n %{soname_asio}-devel
|
|
|
|
Development files for usage with libnghttp2_aio, which implements
|
|
|
|
asynchronous Hypertext Transfer Protocol version 2.
|
2015-02-16 09:13:06 +01:00
|
|
|
|
|
|
|
%package doc
|
2015-11-01 20:46:13 +01:00
|
|
|
Summary: Documentation for nghttp2
|
2015-03-18 23:14:18 +01:00
|
|
|
Group: Documentation/HTML
|
2015-02-16 09:13:06 +01:00
|
|
|
|
|
|
|
%description doc
|
2015-11-01 20:46:13 +01:00
|
|
|
Documentation for nghttp2, which includes a shared C library,
|
|
|
|
HTTP/2 client, server and proxy.
|
2015-02-16 09:13:06 +01:00
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -q
|
2015-11-01 20:46:13 +01:00
|
|
|
%patch0 -p1
|
2015-02-16 09:13:06 +01:00
|
|
|
|
|
|
|
%build
|
2015-11-16 18:23:15 +01:00
|
|
|
autoreconf -fiv
|
2015-02-16 09:13:06 +01:00
|
|
|
%configure \
|
2015-11-16 18:23:15 +01:00
|
|
|
--disable-static \
|
|
|
|
--disable-silent-rules \
|
|
|
|
--enable-asio-lib \
|
|
|
|
--enable-app \
|
2015-11-01 20:46:13 +01:00
|
|
|
--enable-python-bindings
|
|
|
|
|
|
|
|
make all html %{?_smp_mflags}
|
2015-07-16 14:54:32 +02:00
|
|
|
pushd python
|
2015-11-01 20:46:13 +01:00
|
|
|
make nghttp2.c %{?_smp_mflags}
|
|
|
|
python2 setup.py build
|
2015-07-16 14:54:32 +02:00
|
|
|
popd
|
2015-02-16 09:13:06 +01:00
|
|
|
|
|
|
|
%install
|
2015-11-01 20:46:13 +01:00
|
|
|
%make_install
|
|
|
|
|
2015-07-16 14:54:32 +02:00
|
|
|
pushd python
|
2015-11-01 20:46:13 +01:00
|
|
|
python2 setup.py install \
|
|
|
|
--root=%{buildroot} --prefix=%{_prefix}
|
2015-07-16 14:54:32 +02:00
|
|
|
popd
|
2015-11-01 20:46:13 +01:00
|
|
|
|
|
|
|
# Move to the correct directory.
|
|
|
|
mkdir -p %{buildroot}%{_docdir}/
|
|
|
|
mv -f %{buildroot}%{_datadir}/doc/%{name}/ %{buildroot}%{_docdir}/%{name}-doc/
|
|
|
|
|
2015-04-04 19:11:33 +02:00
|
|
|
find %{buildroot} -type f -name "*.la" -delete -print
|
2015-02-16 09:13:06 +01:00
|
|
|
|
2015-11-01 20:46:13 +01:00
|
|
|
# None of applications using these man pages are built.
|
|
|
|
rm -rf %{buildroot}%{_mandir}/man1/* \
|
|
|
|
doc/manual/html/.buildinfo
|
2015-02-16 09:13:06 +01:00
|
|
|
|
2015-11-01 20:46:13 +01:00
|
|
|
%check
|
|
|
|
make check %{?_smp_mflags}
|
2015-02-16 09:13:06 +01:00
|
|
|
|
2015-11-01 20:46:13 +01:00
|
|
|
%post -n %{soname}-%{sover} -p /sbin/ldconfig
|
2015-02-16 09:13:06 +01:00
|
|
|
|
2015-11-01 20:46:13 +01:00
|
|
|
%post -n %{soname_asio}%{sover_asio} -p /sbin/ldconfig
|
|
|
|
|
|
|
|
%postun -n %{soname}-%{sover} -p /sbin/ldconfig
|
|
|
|
|
|
|
|
%postun -n %{soname_asio}%{sover_asio} -p /sbin/ldconfig
|
2015-02-16 09:13:06 +01:00
|
|
|
|
|
|
|
%files
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%{_bindir}/deflatehd
|
|
|
|
%{_bindir}/inflatehd
|
2015-11-16 18:23:15 +01:00
|
|
|
%{_bindir}/h2load
|
|
|
|
%{_bindir}/nghttp
|
|
|
|
%{_bindir}/nghttpd
|
|
|
|
%{_bindir}/nghttpx
|
2015-11-01 20:46:13 +01:00
|
|
|
%{_datadir}/%{name}/
|
2015-02-16 09:13:06 +01:00
|
|
|
|
2015-11-01 20:46:13 +01:00
|
|
|
%files -n %{soname}-%{sover}
|
2015-02-16 09:13:06 +01:00
|
|
|
%defattr(-,root,root)
|
2015-03-18 23:14:18 +01:00
|
|
|
%doc COPYING
|
2015-11-01 20:46:13 +01:00
|
|
|
%{_libdir}/%{soname}.so.%{sover}*
|
2015-02-16 09:13:06 +01:00
|
|
|
|
2015-11-01 20:46:13 +01:00
|
|
|
%files -n %{soname_asio}%{sover_asio}
|
2015-02-16 09:13:06 +01:00
|
|
|
%defattr(-,root,root)
|
2015-03-18 23:14:18 +01:00
|
|
|
%doc COPYING
|
2015-11-01 20:46:13 +01:00
|
|
|
%{_libdir}/%{soname_asio}.so.%{sover_asio}*
|
2015-02-16 09:13:06 +01:00
|
|
|
|
2015-04-04 19:11:33 +02:00
|
|
|
%files -n python-%{name}
|
|
|
|
%defattr(-,root,root)
|
2015-07-16 14:54:32 +02:00
|
|
|
%{python_sitearch}/nghttp2.so
|
2015-11-01 20:46:13 +01:00
|
|
|
%{python_sitearch}/python_nghttp2-*
|
2015-04-04 19:11:33 +02:00
|
|
|
|
2015-11-01 20:46:13 +01:00
|
|
|
%files -n %{soname}-devel
|
2015-02-16 09:13:06 +01:00
|
|
|
%defattr(-,root,root)
|
2015-11-01 20:46:13 +01:00
|
|
|
%dir %{_includedir}/%{name}/
|
|
|
|
%{_includedir}/%{name}/%{name}*.h
|
|
|
|
%{_libdir}/%{soname}.so
|
|
|
|
%{_libdir}/pkgconfig/%{soname}.pc
|
|
|
|
|
|
|
|
%files -n %{soname_asio}-devel
|
2015-02-16 09:13:06 +01:00
|
|
|
%defattr(-,root,root)
|
2015-11-01 20:46:13 +01:00
|
|
|
%dir %{_includedir}/%{name}/
|
|
|
|
%{_includedir}/%{name}/asio_http2*.h
|
|
|
|
%{_libdir}/%{soname_asio}.so
|
|
|
|
%{_libdir}/pkgconfig/%{soname_asio}.pc
|
2015-02-16 09:13:06 +01:00
|
|
|
|
|
|
|
%files doc
|
|
|
|
%defattr(-,root,root)
|
2015-11-01 20:46:13 +01:00
|
|
|
%doc AUTHORS ChangeLog doc/manual/html
|
|
|
|
%doc %{_docdir}/%{name}-doc/
|
2015-02-16 09:13:06 +01:00
|
|
|
|
|
|
|
%changelog
|