]>
Commit | Line | Data |
---|---|---|
eeff1512 JB |
1 | # |
2 | # Conditional build: | |
b22b36f2 JB |
3 | %bcond_without java # JNI bindings |
4 | %bcond_without kerberos5 # GSSAPI support | |
059c89fa JB |
5 | %bcond_with openssl # OpenSSL instead of GnuTLS (incompatible with some versions) |
6 | %bcond_without oath # OATH-based one-time password authentication | |
b22b36f2 | 7 | %bcond_without pcsc # Yutoken support via PCSC Lite |
059c89fa | 8 | %bcond_without stoken # Software Token authentication |
eeff1512 JB |
9 | %bcond_without static_libs # static library |
10 | # | |
68b16813 AO |
11 | Summary: Client for Cisco's AnyConnect SSL VPN and Pulse Connect Secure |
12 | Summary(pl.UTF-8): Klient Cisco AnyConnect SSL VPN i Pulse Connect Secure | |
8faeaf3f | 13 | Name: openconnect |
68b16813 | 14 | Version: 7.05 |
8faeaf3f | 15 | Release: 1 |
eeff1512 JB |
16 | License: LGPL v2.1 |
17 | Group: Applications/Networking | |
8faeaf3f | 18 | Source0: ftp://ftp.infradead.org/pub/openconnect/%{name}-%{version}.tar.gz |
68b16813 | 19 | # Source0-md5: 10cd4f61e8a11cdf793da2b0fd7a6003 |
d0d38427 | 20 | Patch0: %{name}-am.patch |
8faeaf3f | 21 | URL: http://www.infradead.org/openconnect.html |
63d08877 BZ |
22 | BuildRequires: autoconf >= 2.63 |
23 | BuildRequires: automake >= 1:1.10 | |
059c89fa | 24 | %{!?with_openssl:BuildRequires: gnutls-devel >= 2.12.16} |
b22b36f2 JB |
25 | BuildRequires: groff |
26 | %{?with_kerberos5:BuildRequires: heimdal-devel} | |
27 | %{?with_java:BuildRequires: jdk} | |
14fb1dbd | 28 | BuildRequires: libproxy-devel |
eeff1512 | 29 | BuildRequires: libxml2-devel >= 2.0 |
b22b36f2 | 30 | %{?with_oath:BuildRequires: oath-toolkit-devel >= 2.2.0} |
059c89fa JB |
31 | %{?with_openssl:BuildRequires: openssl-devel} |
32 | %{!?with_openssl:BuildRequires: p11-kit-devel} | |
b22b36f2 | 33 | %{?with_pcsc:BuildRequires: pcsc-lite-devel} |
059c89fa | 34 | BuildRequires: pkgconfig >= 1:0.27 |
b22b36f2 | 35 | BuildRequires: python >= 2 |
059c89fa | 36 | %{?with_stoken:BuildRequires: stoken-devel} |
aa47a45d | 37 | %{!?with_openssl:BuildRequires: trousers-devel} |
eeff1512 | 38 | BuildRequires: zlib-devel |
b22b36f2 | 39 | %{?with_oath:Requires: oath-toolkit >= 2.2.0} |
a550ede0 | 40 | Suggests: vpnc-script |
8faeaf3f MB |
41 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
42 | ||
43 | %description | |
68b16813 AO |
44 | OpenConnect is a client for Cisco's AnyConnect SSL VPN and |
45 | Pulse Connect Secure | |
8faeaf3f | 46 | |
14fb1dbd | 47 | %description -l pl.UTF-8 |
68b16813 AO |
48 | OpenConnect jest klientem Cisco AnyConnect SSL VPN |
49 | i Pulse Connect Secure | |
14fb1dbd MB |
50 | |
51 | %package devel | |
eeff1512 JB |
52 | Summary: Development files for OpenConnect library |
53 | Summary(pl.UTF-8): Pliki programistyczne biblioteki OpenConnect | |
14fb1dbd | 54 | Group: Development/Libraries |
63d08877 | 55 | Requires: %{name} = %{version}-%{release} |
059c89fa | 56 | %{?with_openssl:Requires: gnutls-devel >= 2.12.16} |
14fb1dbd | 57 | Requires: libproxy-devel |
eeff1512 | 58 | Requires: libxml2-devel >= 2.0 |
b22b36f2 | 59 | %{?with_oath:Requires: oath-toolkit-devel >= 2.2.0} |
059c89fa JB |
60 | %{?with_openssl:Requires: openssl-devel} |
61 | %{!?with_openssl:Requires: p11-kit-devel} | |
aa47a45d | 62 | %{?with_stoken:Requires: stoken-devel} |
14fb1dbd MB |
63 | Requires: zlib-devel |
64 | ||
65 | %description devel | |
eeff1512 | 66 | Development files for OpenConnect library. |
14fb1dbd MB |
67 | |
68 | %description devel -l pl.UTF-8 | |
eeff1512 JB |
69 | Pliki programistyczne biblioteki OpenConnect. |
70 | ||
71 | %package static | |
72 | Summary: Static OpenConnect library | |
73 | Summary(pl.UTF-8): Statyczna biblioteka OpenConnect | |
74 | Group: Development/Libraries | |
75 | Requires: %{name}-devel = %{version}-%{release} | |
76 | ||
77 | %description static | |
78 | Static OpenConnect library. | |
79 | ||
80 | %description static -l pl.UTF-8 | |
81 | Statyczna biblioteka OpenConnect. | |
14fb1dbd | 82 | |
b22b36f2 JB |
83 | %package -n java-openconnect |
84 | Summary: JNI wrapper for OpenConnect library | |
85 | Summary(pl.UTF-8): Interfejs JNI do biblioteki OpenConnect | |
86 | Group: Libraries/Java | |
87 | Requires: %{name} = %{version}-%{release} | |
88 | ||
89 | %description -n java-openconnect | |
90 | JNI wrapper for OpenConnect library. | |
91 | ||
92 | %description -n java-openconnect -l pl.UTF-8 | |
93 | Interfejs JNI do biblioteki OpenConnect. | |
94 | ||
8faeaf3f MB |
95 | %prep |
96 | %setup -q | |
d0d38427 | 97 | %patch0 -p1 |
8faeaf3f MB |
98 | |
99 | %build | |
63d08877 | 100 | %{__libtoolize} |
b42ab3fb | 101 | %{__aclocal} -I m4 |
63d08877 | 102 | %{__autoconf} |
b42ab3fb | 103 | %{__autoheader} |
63d08877 | 104 | %{__automake} |
eeff1512 | 105 | %configure \ |
d0d38427 | 106 | --disable-silent-rules \ |
a550ede0 | 107 | %{?with_static_libs:--enable-static} \ |
b22b36f2 JB |
108 | %{!?with_kerberos5:--without-gssapi} \ |
109 | %{?with_java:--with-java} \ | |
059c89fa | 110 | %{!?with_oath:--without-liboath} \ |
b22b36f2 | 111 | %{!?with_pcsc:--without-libpcsclite} \ |
059c89fa | 112 | %{!?with_stoken:--without-stoken} \ |
665494d7 | 113 | --with-system-cafile=/etc/certs/ca-certificates.crt \ |
059c89fa JB |
114 | --with-vpnc-script=/usr/bin/vpnc-script \ |
115 | %{?with_openssl:--without-gnutls} | |
eeff1512 | 116 | %{__make} |
8faeaf3f MB |
117 | |
118 | %install | |
119 | rm -rf $RPM_BUILD_ROOT | |
8faeaf3f | 120 | |
63d08877 | 121 | %{__make} install \ |
8faeaf3f MB |
122 | DESTDIR=$RPM_BUILD_ROOT |
123 | ||
eeff1512 JB |
124 | # obsoleted by pkg-config |
125 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/libopenconnect.la | |
b22b36f2 JB |
126 | # JNI module |
127 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/libopenconnect-wrapper.{la,a} | |
eeff1512 | 128 | |
0e0edc27 JB |
129 | %find_lang %{name} |
130 | ||
8faeaf3f MB |
131 | %clean |
132 | rm -rf $RPM_BUILD_ROOT | |
133 | ||
63d08877 BZ |
134 | %post -p /sbin/ldconfig |
135 | %postun -p /sbin/ldconfig | |
136 | ||
b22b36f2 JB |
137 | %post -n java-openconnect -p /sbin/ldconfig |
138 | %postun -n java-openconnect -p /sbin/ldconfig | |
139 | ||
0e0edc27 | 140 | %files -f %{name}.lang |
8faeaf3f | 141 | %defattr(644,root,root,755) |
63d08877 | 142 | %doc AUTHORS TODO |
70761f3a | 143 | %attr(755,root,root) %{_sbindir}/openconnect |
63d08877 | 144 | %attr(755,root,root) %{_libdir}/libopenconnect.so.*.*.* |
b22b36f2 | 145 | %attr(755,root,root) %ghost %{_libdir}/libopenconnect.so.5 |
8faeaf3f | 146 | %{_mandir}/man8/openconnect.8* |
14fb1dbd MB |
147 | |
148 | %files devel | |
149 | %defattr(644,root,root,755) | |
63d08877 | 150 | %attr(755,root,root) %{_libdir}/libopenconnect.so |
14fb1dbd MB |
151 | %{_includedir}/openconnect.h |
152 | %{_pkgconfigdir}/openconnect.pc | |
059c89fa | 153 | %{_docdir}/openconnect |
eeff1512 JB |
154 | |
155 | %if %{with static_libs} | |
156 | %files static | |
157 | %defattr(644,root,root,755) | |
158 | %{_libdir}/libopenconnect.a | |
159 | %endif | |
b22b36f2 JB |
160 | |
161 | %files -n java-openconnect | |
162 | %defattr(644,root,root,755) | |
163 | %attr(755,root,root) %{_libdir}/libopenconnect-wrapper.so.*.*.* | |
164 | %attr(755,root,root) %ghost %{_libdir}/libopenconnect-wrapper.so.0 | |
165 | %attr(755,root,root) %{_libdir}/libopenconnect-wrapper.so |