7a8b1309d2fb7c19c8430662b86d58c213782fa0
[platform/upstream/adns.git] / packaging / adns.spec
1 Name:           adns
2 %define lname   libadns
3 Version:        1.4
4 Release:        0
5 License:        GPL-2.0+
6 Summary:        Advanced Easy-to-Use Asynchronous-Capable DNS Utilities
7 Url:            http://www.chiark.greenend.org.uk/~ian/adns/
8 Group:          Productivity/Networking/DNS/Utilities
9 Source:         %{name}-%{version}.tar.bz2
10 Source1:        README.SUSE
11 Source2:        baselibs.conf
12 Patch0:         %{name}-%{version}-destdir.patch
13 Patch1:         %{name}-%{version}-configure.patch
14 Patch2:         %{name}-%{version}-ipv6.patch
15 Patch3:         adns-visibility.patch
16 Patch4:         adns-ocloexec.patch
17 BuildRequires:  autoconf
18 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
19
20 %description
21 adns includes a collection of useful DNS resolver utilities.
22
23 %package -n %lname
24 Summary:        Advanced DNS resolver client library
25 Group:          System/Libraries
26 Provides:       libadns = %{version}
27
28 %description -n %lname
29 Libadns is an advanced, easy to use, asynchronous-capable DNS resolver
30 client library for C (and C++) programs.
31
32 %package -n libadns-devel
33 Summary:        Libraries and header files to develop programs with libadns support
34 Group:          Development/Languages/C and C++
35 Requires:       %lname = %{version}
36 Requires:       glibc-devel
37
38 %description -n libadns-devel
39 Libadns-devel includes the header file and static library to develop
40 programs with libads support.
41
42 %prep
43 %setup -q
44 %patch0
45 %patch1
46 %patch2
47 %patch3
48 %patch4
49 cp %{SOURCE1} .
50
51 %build
52 autoreconf -fiv
53 %configure
54 make %{?_smp_mflags} all
55
56 %install
57 %make_install
58
59
60 %files
61 %defattr(-,root,root)
62 %doc COPYING GPL-vs-LGPL LICENCE.WAIVERS
63 %{_bindir}/adns*
64
65 %files -n %lname
66 %defattr(-,root,root)
67 %{_libdir}/libadns.so.1*
68
69 %files -n libadns-devel
70 %defattr(-,root,root)
71 %{_includedir}/adns.h
72 %{_libdir}/libadns.so
73
74 %post -n %lname -p /sbin/ldconfig
75
76 %postun -n %lname -p /sbin/ldconfig
77
78 %changelog