367c220a4299cab0ec006729568792263ff6a7cb
[fedora-mingw.git] / gnutls / mingw32-gnutls.spec
1 %define __strip %{_mingw32_strip}
2 %define __objdump %{_mingw32_objdump}
3 %define _use_internal_dependency_generator 0
4 %define __find_requires %{_mingw32_findrequires}
5 %define __find_provides %{_mingw32_findprovides}
6
7 Name:           mingw32-gnutls
8 Version:        2.6.3
9 Release:        5%{?dist}
10 Summary:        MinGW Windows GnuTLS TLS/SSL encryption library
11
12 License:        GPLv3+ and LGPLv2+
13 Group:          Development/Libraries
14 URL:            http://www.gnutls.org/
15 #Source0:        ftp://ftp.gnutls.org/pub/gnutls/gnutls-%{version}.tar.bz2
16 # XXX patent tainted SRP code removed.
17 Source0:        gnutls-%{version}-nosrp.tar.bz2
18 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
19
20 BuildArch:      noarch
21
22 Patch1:         gnutls-2.6.2-nosrp.patch
23
24 # MinGW-specific patches.
25 Patch1000:      mingw32-gnutls-2.6.3-certtool-build.patch
26
27 BuildRequires:  mingw32-filesystem >= 40
28 BuildRequires:  mingw32-gcc
29 BuildRequires:  mingw32-gcc-c++
30 BuildRequires:  mingw32-binutils
31 BuildRequires:  mingw32-dlfcn
32 BuildRequires:  mingw32-libgpg-error
33 BuildRequires:  mingw32-libgcrypt >= 1.2.2
34 BuildRequires:  mingw32-gettext
35 BuildRequires:  mingw32-iconv
36 BuildRequires:  mingw32-readline
37 BuildRequires:  mingw32-zlib
38
39 BuildRequires:  autoconf
40 BuildRequires:  automake
41 BuildRequires:  libtool
42
43 # Yes, really ...
44 BuildRequires:  pkgconfig
45
46 # For native /usr/bin/msgfmt etc.
47 BuildRequires:  gettext
48
49 Requires:       pkgconfig
50
51
52 %description
53 MinGW Windows GnuTLS TLS/SSL encryption library.
54
55
56 %prep
57 %setup -q -n gnutls-%{version}
58
59 %patch1 -p1 -b .nosrp
60
61 %patch1000 -p1 -b .mingw32
62
63 for i in auth_srp_rsa.c auth_srp_sb64.c auth_srp_passwd.c auth_srp.c gnutls_srp.c ext_srp.c; do
64     touch lib/$i
65 done
66
67 %if 0%{?fedora} > 10
68 libtoolize --force --copy
69 aclocal
70 autoreconf
71 %endif
72
73
74 %build
75 PATH="%{_mingw32_bindir}:$PATH" \
76 %{_mingw32_configure} \
77   --with-included-libtasn1 \
78   --disable-srp-authentication \
79   --disable-static
80 # %{?_smp_mflags} doesn't build correctly.
81 make
82
83
84 %install
85 rm -rf $RPM_BUILD_ROOT
86
87 make DESTDIR=$RPM_BUILD_ROOT install
88 rm -f $RPM_BUILD_ROOT%{_mingw32_datadir}/info/dir
89
90 # Remove info and man pages which duplicate stuff in Fedora already.
91 rm -rf $RPM_BUILD_ROOT%{_mingw32_infodir}
92 rm -rf $RPM_BUILD_ROOT%{_mingw32_mandir}
93
94 %find_lang gnutls
95
96
97 %clean
98 rm -rf $RPM_BUILD_ROOT
99
100
101 %files -f gnutls.lang
102 %defattr(-,root,root)
103 %doc COPYING COPYING.LIB
104 %{_mingw32_bindir}/certtool.exe
105 %{_mingw32_bindir}/gnutls-cli-debug.exe
106 %{_mingw32_bindir}/gnutls-cli.exe
107 %{_mingw32_bindir}/gnutls-serv.exe
108 %{_mingw32_bindir}/libgnutls-26.def
109 %{_mingw32_bindir}/libgnutls-26.dll
110 %{_mingw32_bindir}/libgnutls-config
111 %{_mingw32_bindir}/libgnutls-extra-26.def
112 %{_mingw32_bindir}/libgnutls-extra-26.dll
113 %{_mingw32_bindir}/libgnutls-extra-config
114 %{_mingw32_bindir}/libgnutls-openssl-26.def
115 %{_mingw32_bindir}/libgnutls-openssl-26.dll
116 %{_mingw32_bindir}/psktool.exe
117 %{_mingw32_libdir}/libgnutls-extra.dll.a
118 %{_mingw32_libdir}/libgnutls-extra.la
119 %{_mingw32_libdir}/libgnutls-openssl.dll.a
120 %{_mingw32_libdir}/libgnutls-openssl.la
121 %{_mingw32_libdir}/libgnutls.dll.a
122 %{_mingw32_libdir}/libgnutls.la
123 %{_mingw32_libdir}/pkgconfig/gnutls-extra.pc
124 %{_mingw32_libdir}/pkgconfig/gnutls.pc
125 %{_mingw32_includedir}/gnutls/
126 %{_mingw32_datadir}/aclocal/libgnutls-extra.m4
127 %{_mingw32_datadir}/aclocal/libgnutls.m4
128
129
130 %changelog
131 * Fri Feb 20 2009 Richard W.M. Jones <rjones@redhat.com> - 2.6.3-5
132 - Rebuild for mingw32-gcc 4.4
133
134 * Thu Feb 19 2009 Richard W.M. Jones <rjones@redhat.com> - 2.6.3-4
135 - +BR mingw32-gcc-c++
136
137 * Fri Feb  6 2009 Richard W.M. Jones <rjones@redhat.com> - 2.6.3-3
138 - Include license.
139
140 * Fri Jan 23 2009 Richard W.M. Jones <rjones@redhat.com> - 2.6.3-2
141 - Rebase to native Fedora version 2.6.3.
142 - Enable C++ library.
143 - Use find_lang macro.
144 - Don't build static library.
145 - Rebase MinGW patch to 2.6.3.
146 - +BR mingw32-dlfcn.
147 - +BR mingw32-readline.
148 - Force rebuild of libtool.
149
150 * Tue Jan 13 2009 Richard W.M. Jones <rjones@redhat.com> - 2.4.2-4
151 - Requires pkgconfig.
152
153 * Thu Nov 13 2008 Richard W.M. Jones <rjones@redhat.com> - 2.4.2-3
154 - fix chain verification issue CVE-2008-4989 (#470079)
155 - separate out the MinGW-specific patch from the others
156
157 * Wed Sep 24 2008 Richard W.M. Jones <rjones@redhat.com> - 2.4.2-2
158 - Rename mingw -> mingw32.
159
160 * Wed Sep 24 2008 Richard W.M. Jones <rjones@redhat.com> - 2.4.2-1
161 - New native version.
162
163 * Mon Sep 22 2008 Daniel P. Berrange <berrange@redhat.com> - 2.4.1-9
164 - Switch to source tar.bz2 with SRP stuff removed
165
166 * Sun Sep 21 2008 Richard W.M. Jones <rjones@redhat.com> - 2.4.1-8
167 - Remove duplicate manpages and info files.
168
169 * Thu Sep 11 2008 Daniel P. Berrange <berrange@redhat.com> - 2.4.1-7
170 - Add BR on autoconf, automake and libtool
171
172 * Wed Sep 10 2008 Richard W.M. Jones <rjones@redhat.com> - 2.4.1-6
173 - Need to run autoreconf after patching src/Makefile.am.
174 - Remove static libs.
175
176 * Fri Sep  5 2008 Richard W.M. Jones <rjones@redhat.com> - 2.4.1-5
177 - Add patch to build certtool.exe because of missing dep of gnulib on intl.
178 - BuildArch is noarch.
179
180 * Thu Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 2.4.1-3
181 - Use mingw-filesystem RPM macros.
182 - Depends on mingw-iconv, mingw-gettext.
183
184 * Tue Sep  2 2008 Daniel P. Berrange <berrange@redhat.com> - 2.4.1-2
185 - List files explicitly and use custom CFLAGS
186
187 * Mon Jul  7 2008 Richard W.M. Jones <rjones@redhat.com> - 2.4.1-1
188 - Initial RPM release, largely based on earlier work from several sources.