]>
Commit | Line | Data |
---|---|---|
7947fc2e | 1 | # |
2 | # Conditional build | |
e0264d10 | 3 | %bcond_with tests # perform "make check" |
7947fc2e | 4 | # |
35f10266 | 5 | Summary: Embeded HTTP server library |
7947fc2e | 6 | Summary(pl.UTF-8): Biblioteka wbudowanego serwera HTTP |
35f10266 | 7 | Name: libmicrohttpd |
ff59dc04 | 8 | Version: 1.0.1 |
9ea36d8f | 9 | Release: 1 |
82e599ef | 10 | License: LGPL v2.1+ |
35f10266 | 11 | Group: Libraries |
e89d6a51 | 12 | Source0: https://ftp.gnu.org/gnu/libmicrohttpd/%{name}-%{version}.tar.gz |
ff59dc04 | 13 | # Source0-md5: b41c83799a478ea9c774e50ed22446bc |
e0264d10 | 14 | Patch0: %{name}-info.patch |
35f10266 | 15 | URL: http://www.gnu.org/software/libmicrohttpd/ |
9ea36d8f | 16 | BuildRequires: autoconf >= 2.64 |
71b1fb6b | 17 | BuildRequires: automake >= 1:1.11 |
c282e8af | 18 | BuildRequires: gettext-tools >= 0.20.2 |
458781c7 | 19 | BuildRequires: gnutls-devel >= 2.8.6 |
35f10266 | 20 | BuildRequires: libgcrypt-devel >= 1.2.4 |
f6457725 | 21 | BuildRequires: libmagic-devel |
035db06f | 22 | BuildRequires: libtool >= 2:2.4.0 |
6fc60a3e | 23 | BuildRequires: pkgconfig |
e0264d10 | 24 | BuildRequires: texinfo |
35f10266 | 25 | %if %{with tests} |
e0264d10 | 26 | BuildRequires: curl-devel >= 7.16.4 |
35f10266 | 27 | %endif |
458781c7 JB |
28 | Requires: gnutls >= 2.8.6 |
29 | Requires: libgcrypt >= 1.2.4 | |
35f10266 AF |
30 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
31 | ||
32 | %description | |
7947fc2e | 33 | GNU libmicrohttpd is a small C library that is supposed to make it |
34 | easy to run an HTTP server as part of another application. | |
35 | ||
36 | %description -l pl.UTF-8 | |
37 | GNU libmicrohttpd jest małą biblioteką C, w założeniu umożliwiającą | |
e0264d10 | 38 | uruchomienie serwera HTTP jako części innej aplikacji. |
35f10266 AF |
39 | |
40 | %package devel | |
41 | Summary: Header files to develop libmicrohttpd applications | |
5deb6f41 | 42 | Summary(pl.UTF-8): Pliki nagłówkowe do rozwijania aplikacji używających libmicrohttpd |
35f10266 AF |
43 | Group: Development/Libraries |
44 | Requires: %{name} = %{version}-%{release} | |
458781c7 | 45 | Requires: gnutls-devel >= 2.8.6 |
31c2f099 | 46 | Requires: libgcrypt-devel >= 1.2.4 |
e72faf06 | 47 | Requires: openssl-devel |
35f10266 AF |
48 | |
49 | %description devel | |
50 | Header files to develop libmicrohttpd applications. | |
51 | ||
7947fc2e | 52 | %description devel -l pl.UTF-8 |
5deb6f41 | 53 | Pliki nagłówkowe do rozwijania aplikacji używających libmicrohttpd. |
7947fc2e | 54 | |
35f10266 AF |
55 | %package static |
56 | Summary: Static libmicrohttpd libraries | |
57 | Summary(pl.UTF-8): Biblioteka statyczna libmicrohttpd | |
58 | Group: Development/Libraries | |
59 | Requires: %{name}-devel = %{version}-%{release} | |
60 | ||
61 | %description static | |
62 | Static libmicrohttpd libraries. | |
63 | ||
64 | %description static -l pl.UTF-8 | |
65 | Biblioteka statyczna libmicrohttpd. | |
66 | ||
67 | %prep | |
68 | %setup -q | |
e0264d10 | 69 | %patch0 -p1 |
35f10266 AF |
70 | |
71 | %build | |
72 | %{__libtoolize} | |
73 | %{__aclocal} -I m4 | |
74 | %{__autoconf} | |
75 | %{__autoheader} | |
76 | %{__automake} | |
77 | %configure \ | |
78 | %if %{with tests} | |
79 | --enable-curl \ | |
80 | --enable-client-side \ | |
81 | %endif | |
82 | --enable-https \ | |
7947fc2e | 83 | --disable-messages |
35f10266 AF |
84 | |
85 | %{__make} | |
86 | %if %{with tests} | |
87 | %{__make} check | |
88 | %endif | |
89 | ||
90 | %install | |
91 | rm -rf $RPM_BUILD_ROOT | |
92 | ||
93 | %{__make} install \ | |
94 | DESTDIR=$RPM_BUILD_ROOT | |
95 | ||
337f2221 JB |
96 | # obsoleted by pkg-config |
97 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/libmicro*.la | |
e72faf06 | 98 | |
35f10266 AF |
99 | %clean |
100 | rm -rf $RPM_BUILD_ROOT | |
101 | ||
102 | %post -p /sbin/ldconfig | |
103 | %postun -p /sbin/ldconfig | |
104 | ||
105 | %post devel -p /sbin/postshell | |
106 | -/usr/sbin/fix-info-dir -c %{_infodir} | |
107 | ||
108 | %postun devel -p /sbin/postshell | |
109 | -/usr/sbin/fix-info-dir -c %{_infodir} | |
110 | ||
111 | %files | |
112 | %defattr(644,root,root,755) | |
7947fc2e | 113 | %doc AUTHORS ChangeLog NEWS README |
35f10266 | 114 | %attr(755,root,root) %{_libdir}/libmicrohttpd.so.*.*.* |
24840d21 | 115 | %attr(755,root,root) %ghost %{_libdir}/libmicrohttpd.so.12 |
35f10266 AF |
116 | |
117 | %files devel | |
118 | %defattr(644,root,root,755) | |
119 | %attr(755,root,root) %{_libdir}/libmicrohttpd.so | |
35f10266 | 120 | %{_includedir}/microhttpd.h |
458781c7 JB |
121 | %{_infodir}/libmicrohttpd.info* |
122 | %{_infodir}/libmicrohttpd-tutorial.info* | |
af043302 | 123 | %{_infodir}/libmicrohttpd_performance_data.png |
35f10266 AF |
124 | %{_mandir}/man3/libmicrohttpd.3* |
125 | %{_pkgconfigdir}/libmicrohttpd.pc | |
126 | ||
127 | %files static | |
128 | %defattr(644,root,root,755) | |
129 | %{_libdir}/libmicrohttpd.a |