]> git.pld-linux.org Git - packages/commoncpp2.git/blame - commoncpp2.spec
- added gnutls bcond
[packages/commoncpp2.git] / commoncpp2.spec
CommitLineData
e5703f90
KK
1#
2# Conditional build:
3%bcond_without static_libs # don't build static library
8dc0ec17 4%bcond_with gnutls # use GnuTLS instead of OpenSSL [needs update: recent gnutls no longer uses libgcrypt]
e5703f90 5#
3ef9580c 6Summary: A GNU package for creating portable C++ programs
8c8acc7d 7Summary(pl.UTF-8): Pakiet GNU do tworzenia przenośnych programów w C++
3ef9580c 8Name: commoncpp2
8fc0cf85
JB
9Version: 1.8.1
10Release: 1
c45a90a3 11License: GPL v2+ with runtime exception
3ef9580c 12Group: Libraries
9cfec48b 13Source0: http://ftp.gnu.org/gnu/commoncpp/%{name}-%{version}.tar.gz
8fc0cf85
JB
14# Source0-md5: 4804b184e609154ba2bc0aa9f61dc6ef
15Patch0: %{name}-netfilter.patch
16Patch1: %{name}-include.patch
17Patch2: %{name}-link.patch
18Patch3: %{name}-info.patch
7c7445ba 19URL: http://www.gnu.org/software/commoncpp/
8fc0cf85 20BuildRequires: autoconf >= 2.50
7c7445ba 21BuildRequires: automake
3ef9580c 22BuildRequires: doxygen
8dc0ec17 23%{?with_gnutls:BuildRequires: gnutls-devel}
3ef9580c 24BuildRequires: libstdc++-devel
8fc0cf85 25BuildRequires: libtool >= 2:1.5
3ef9580c 26BuildRequires: libxml2-devel
8dc0ec17 27%{!?with_gnutls:BuildRequires: openssl-devel}
8fc0cf85 28BuildRequires: texinfo
3ef9580c 29BuildRequires: zlib-devel
30BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
31
32%description
33This is the second major release of GNU Common C++. GNU Common C++ "2"
34is a GNU package which offers portable "abstraction" of system
35services such as threads, networks, and sockets. GNU Common C++ "2"
36also offers individual frameworks generally useful to developing
37portable C++ applications including a object persistance engine, math
38libraries, threading, sockets, etc. GNU Common C++ "2" is small, and
39highly portable. GNU Common C++ "2" will support most Unix operating
1abd0668 40systems as well as Win32, in addition to GNU/Linux.
3ef9580c 41
06c607b2
JR
42%description -l pl.UTF-8
43Drugie główne wydanie GNU Common C++. GNU Common C++ oferuje przenośne
44abstrakcje usług systemowych takich jak wątki, sieci i gniazda.
45Oferuje także poszczególne szkielety użyteczne do rozwijania
46przenośnych aplikacji C++ zawierające silnik trwałych obiektów,
47biblioteki matematyczne, wątków, gniazd itd. GNU Common C++ jest mały
48i przenośny. Oprócz GNU/Linuksa obsługuje także większość uniksowych
49systemów operacyjnych oraz Win32.
17bc0025 50
3ef9580c 51%package devel
52Summary: Header files for commoncpp2 library
8c8acc7d 53Summary(pl.UTF-8): Pliki nagłówkowe biblioteki commoncpp2
3ef9580c 54Group: Development/Libraries
55Requires: %{name} = %{version}-%{release}
8dc0ec17 56%{?with_gnutls:Requires: gnutls-devel}
3ef9580c 57Requires: libstdc++-devel
58Requires: libxml2-devel
8dc0ec17 59%{!?with_gnutls:Requires: openssl-devel}
3ef9580c 60Requires: zlib-devel
61
62%description devel
63Header files for commoncpp2 library.
64
06c607b2
JR
65%description devel -l pl.UTF-8
66Pliki nagłówkowe biblioteki commoncpp2.
3ef9580c 67
68%package static
69Summary: Static commoncpp2 library
8c8acc7d 70Summary(pl.UTF-8): Statyczna biblioteka commoncpp2
3ef9580c 71Group: Development/Libraries
72Requires: %{name}-devel = %{version}-%{release}
73
74%description static
75Static commoncpp2 library.
76
06c607b2 77%description static -l pl.UTF-8
3ef9580c 78Statyczna biblioteka commoncpp2.
79
80%prep
81%setup -q
7a5c4ef4 82%patch0 -p1
54a4a4fa 83%patch1 -p1
8fc0cf85
JB
84%patch2 -p1
85%patch3 -p1
3ef9580c 86
87%build
e131c2a8 88%{__libtoolize}
4a331386 89%{__aclocal} -I m4
4a331386 90%{__autoconf}
e131c2a8 91%{__autoheader}
92%{__automake}
4a331386 93%configure \
e5703f90 94 %{!?with_static_libs:--disable-static} \
8dc0ec17
JB
95 %{?with_gnutls:--with-gnutls} \
96 %{!?with_gnutls:--with-openssl}
8fc0cf85
JB
97
98# ensure netfilter is detected
8dc0ec17 99grep -q 'HAVE_NAT_NETFILTER 1' config.h || exit 1
8fc0cf85 100
54a4a4fa 101%{__make} -j1
3ef9580c 102
103%install
104rm -rf $RPM_BUILD_ROOT
105
106%{__make} install \
107 DESTDIR=$RPM_BUILD_ROOT
108
109%clean
110rm -rf $RPM_BUILD_ROOT
111
112%post -p /sbin/ldconfig
113%postun -p /sbin/ldconfig
114
8fc0cf85 115%post devel -p /sbin/postshell
2485d124 116-/usr/sbin/fix-info-dir -c %{_infodir}
3ef9580c 117
8fc0cf85 118%postun devel -p /sbin/postshell
2485d124 119-/usr/sbin/fix-info-dir -c %{_infodir}
3ef9580c 120
121%files
122%defattr(644,root,root,755)
8fc0cf85
JB
123%doc AUTHORS COPYING.addendum ChangeLog NEWS README SUPPORT THANKS TODO
124%attr(755,root,root) %{_libdir}/libccext2-1.8.so.*.*.*
125%ghost %{_libdir}/libccext2-1.8.so.0
126%attr(755,root,root) %{_libdir}/libccgnu2-1.8.so.*.*.*
127%ghost %{_libdir}/libccgnu2-1.8.so.0
3ef9580c 128
129%files devel
130%defattr(644,root,root,755)
8fc0cf85
JB
131%doc doc/html/*.{css,html,js,png}
132%attr(755,root,root) %{_bindir}/ccgnu2-config
133%attr(755,root,root) %{_libdir}/libccext2.so
134%attr(755,root,root) %{_libdir}/libccgnu2.so
135%{_libdir}/libccext2.la
136%{_libdir}/libccgnu2.la
8bab2ee7 137%{_includedir}/cc++
8fc0cf85
JB
138%{_aclocaldir}/ost_check2.m4
139%{_pkgconfigdir}/libccext2.pc
140%{_pkgconfigdir}/libccgnu2.pc
141%{_infodir}/commoncpp2.info*
3ef9580c 142
e5703f90 143%if %{with static_libs}
3ef9580c 144%files static
145%defattr(644,root,root,755)
8fc0cf85
JB
146%{_libdir}/libccext2.a
147%{_libdir}/libccgnu2.a
e5703f90 148%endif
This page took 0.139232 seconds and 4 git commands to generate.