Revert "Merge branch 'upstream' into tizen"
[platform/upstream/nettle.git] / packaging / nettle.spec
1 Name:           nettle
2 Version:        2.7.1
3 Release:        0
4 Summary:        Cryptographic Library
5 License:        LGPL-2.1+ and GPL-2.0+
6 Group:          Security/Crypto Libraries
7 Source0:        https://ftp.gnu.org/gnu/nettle/nettle-%{version}.tar.gz
8 Source1:        baselibs.conf
9 Source1001:     nettle.manifest
10 BuildRequires:  gmp-devel
11 BuildRequires:  pkgconfig
12
13 %description
14 Nettle is a cryptographic library that is designed to fit easily in more or
15 less any context: In crypto toolkits for object-oriented languages (C++,
16 Python, Pike, ...), in applications like LSH or GNUPG, or even in kernel space.
17
18 %package -n libhogweed
19
20 Summary:        Cryptographic Library for Public Key Algorithms
21 License:        LGPL-2.1+
22 Group:          Security/Crypto Libraries
23
24 %description -n libhogweed
25 Nettle is a cryptographic library that is designed to fit easily in more or
26 less any context: In crypto toolkits for object-oriented languages (C++,
27 Python, Pike, ...), in applications like LSH or GNUPG, or even in kernel space.
28
29 The libhogweed library contains public key algorithms to use with libnettle.
30
31 %package -n libnettle-devel
32 Summary:        Cryptographic Library
33 License:        LGPL-2.1+
34 Group:          Development/Libraries
35 Requires:       glibc-devel
36 Requires:       gmp-devel
37 Requires:       libhogweed = %{version}
38 Requires:       libnettle = %{version}
39
40 %description -n libnettle-devel
41 Nettle is a cryptographic library that is designed to fit easily in more or
42 less any context: In crypto toolkits for object-oriented languages (C++,
43 Python, Pike, ...), in applications like LSH or GNUPG, or even in kernel space.
44
45 %package -n libnettle
46
47 Summary:        Cryptographic Tools
48 License:        LGPL-2.1+ and GPL-2.0+
49 Group:          Security/Crypto Libraries
50
51 %description -n libnettle
52 Nettle is a cryptographic library that is designed to fit easily in more or
53 less any context: In crypto toolkits for object-oriented languages (C++,
54 Python, Pike, ...), in applications like LSH or GNUPG, or even in kernel space.
55
56 This package contains a few command-line tools to perform cryptographic
57 operations using the nettle library.
58
59 %prep
60 %setup -q
61 cp %{SOURCE1001} .
62
63 %build
64 %if "%{asan}" == "1"
65 %restore_fcommon
66 %endif
67 #configure --disable-static
68 %configure --enable-shared
69
70 make %{?_smp_mflags}
71
72 %check
73 make check
74
75 %install
76 %make_install
77
78 %post   -n libnettle -p /sbin/ldconfig
79
80 %postun -n libnettle -p /sbin/ldconfig
81
82 %post   -n libhogweed -p /sbin/ldconfig
83
84 %postun -n libhogweed -p /sbin/ldconfig
85
86
87 %files -n libnettle
88 %manifest %{name}.manifest
89 %defattr(-,root,root)
90 %license COPYING*
91 %{_libdir}/libnettle.so.*
92
93 %files -n libhogweed
94 %manifest %{name}.manifest
95 %defattr(-,root,root)
96 %{_libdir}/libhogweed.so.*
97
98 %files -n libnettle-devel
99 %manifest %{name}.manifest
100 %defattr(-,root,root)
101 %{_includedir}/nettle
102 %{_libdir}/libnettle.so
103 %{_libdir}/libhogweed.so
104 %{_libdir}/pkgconfig/hogweed.pc
105 %{_libdir}/pkgconfig/nettle.pc
106
107 %files -n nettle
108 %manifest %{name}.manifest
109 %defattr(-,root,root)
110 %{_bindir}/nettle-lfib-stream
111 %{_bindir}/pkcs1-conv
112 %{_bindir}/sexp-conv
113 %{_bindir}/nettle-hash
114
115 %changelog