]> git.pld-linux.org Git - packages/libupnp.git/blob - libupnp.spec
add apidocs bcond
[packages/libupnp.git] / libupnp.spec
1 #
2 # Conditional build:
3 %bcond_without  apidocs         # API documentation
4 %bcond_without  static_libs     # static libraries
5
6 Summary:        The Universal Plug and Play (UPnP) SDK for Linux
7 Summary(pl.UTF-8):      Pakiet programistyczny Universal Plug and Play (UPnP) dla Linuksa
8 Name:           libupnp
9 Version:        1.14.19
10 Release:        1
11 License:        BSD
12 Group:          Libraries
13 Source0:        https://downloads.sourceforge.net/pupnp/%{name}-%{version}.tar.bz2
14 # Source0-md5:  349638d6cfd07e4475488ad089927bd6
15 Patch0:         %{name}-opt.patch
16 Patch1:         %{name}-openssl.patch
17 URL:            http://pupnp.sourceforge.net/
18 BuildRequires:  autoconf >= 2.60
19 BuildRequires:  automake >= 1:1.8
20 %{?with_apidocs:BuildRequires:  doxygen}
21 BuildRequires:  libtool >= 2:1.5
22 BuildRequires:  openssl-devel >= 0.9.8b
23 BuildRequires:  pkgconfig
24 BuildRequires:  rpm-build >= 4.6
25 BuildRequires:  rpmbuild(macros) >= 1.752
26 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
27
28 %description
29 The Linux SDK for UPnP Devices (libupnp) provides developers with an
30 API and open source code for building control points, devices, and
31 bridges that are compliant with Version 1.0 of the Universal Plug and
32 Play Device Architecture Specification.
33
34 %description -l pl.UTF-8
35 Linuksowy pakiet programistyczny dla urządzeń UPnP (libupnp) dostarcza
36 programistom API i kod z otwartymi źródłami służące do tworzenia
37 punktów kontrolnych, urządzeń i mostków kompatybilnych z wersją 1.0
38 specyfikacji architektury urządzeń Universal Plug and Play.
39
40 %package devel
41 Summary:        Header files for libupnp
42 Summary(pl.UTF-8):      Pliki nagłówkowe libupnp
43 Group:          Development/Libraries
44 Requires:       %{name} = %{version}-%{release}
45 Requires:       openssl-devel >= 0.9.8b
46 Conflicts:      libupnp1.6-devel
47
48 %description devel
49 This package contains header files for the Linux SDK for UPnP Devices
50 (libupnp).
51
52 %description devel -l pl.UTF-8
53 Ten pakiet zawiera pliki nagłówkowe dla linuksowego pakietu
54 programistycznego do urządzeń UPnP (libupnp).
55
56 %package static
57 Summary:        Static upnp libraries
58 Summary(pl.UTF-8):      Statyczne biblioteki upnp
59 Group:          Development/Libraries
60 Requires:       %{name}-devel = %{version}-%{release}
61 Conflicts:      libupnp1.6-static
62
63 %description static
64 Static upnp libraries.
65
66 %description static -l pl.UTF-8
67 Statyczne biblioteki upnp.
68
69 %package apidocs
70 Summary:        API documentation for upnp libraries
71 Summary(pl.UTF-8):      Dokumentacja API bibliotek upnp
72 Group:          Documentation
73 BuildArch:      noarch
74
75 %description apidocs
76 API documentation for upnp libraries.
77
78 %description apidocs -l pl.UTF-8
79 Dokumentacja API bibliotek upnp.
80
81 %prep
82 %setup -q
83 %patch0 -p1
84 %patch1 -p1
85
86 # LFS is required in library clients (including examples)
87 %{__sed} -i -e '/^Cflags/ s/$/ -D_FILE_OFFSET_BITS=64/' libupnp.pc.in
88 %{__sed} -i -e '/^AM_CPPFLAGS =/ s/= /= -D_FILE_OFFSET_BITS=64 /' upnp/sample/Makefile.am
89
90 %build
91 %{__libtoolize}
92 %{__aclocal} -I m4
93 %{__autoconf}
94 %{__autoheader}
95 %{__automake}
96 %configure \
97         %{?debug:--enable-debug} \
98         --enable-open-ssl \
99         --disable-silent-rules \
100         %{__enable_disable static_libs static}
101 %{__make}
102 %{?with_apidocs:%{__make} -C docs docs}
103
104 %install
105 rm -rf $RPM_BUILD_ROOT
106
107 %{__make} install \
108         DESTDIR=$RPM_BUILD_ROOT
109
110 %clean
111 rm -rf $RPM_BUILD_ROOT
112
113 %post   -p /sbin/ldconfig
114 %postun -p /sbin/ldconfig
115
116 %files
117 %defattr(644,root,root,755)
118 %doc COPYING ChangeLog THANKS
119 %attr(755,root,root) %{_libdir}/libixml.so.*.*.*
120 %attr(755,root,root) %ghost %{_libdir}/libixml.so.11
121 %attr(755,root,root) %{_libdir}/libupnp.so.*.*.*
122 %attr(755,root,root) %ghost %{_libdir}/libupnp.so.17
123
124 %files devel
125 %defattr(644,root,root,755)
126 %attr(755,root,root) %{_libdir}/libixml.so
127 %attr(755,root,root) %{_libdir}/libupnp.so
128 %{_libdir}/libixml.la
129 %{_libdir}/libupnp.la
130 %{_includedir}/upnp
131 %{_pkgconfigdir}/libupnp.pc
132
133 %if %{with static_libs}
134 %files static
135 %defattr(644,root,root,755)
136 %{_libdir}/libixml.a
137 %{_libdir}/libupnp.a
138 %endif
139
140 %if %{with apidocs}
141 %files apidocs
142 %defattr(644,root,root,755)
143 %doc docs/doxygen/html/*.{html,js,css,png}
144 %endif
This page took 0.11226 seconds and 3 git commands to generate.