]> git.pld-linux.org Git - packages/cipe.git/blame - cipe.spec
- invoke fix-info-dir via /sbin/postshell where possible to avoid extra /bin/sh dep
[packages/cipe.git] / cipe.spec
CommitLineData
b5dd35a8
JB
1#
2# Conditional build:
87c73135 3%bcond_without dist_kernel # without kernel from distribution
b5dd35a8 4#
9d280a4b 5%define _rel 1
859edd7f 6Summary: CIPE - encrypted IP over UDP tunneling
54b389a4 7Summary(pl.UTF-8): CIPE - szyfrowany tunel IP po UDP
859edd7f 8Name: cipe
4d82c0d9 9Version: 1.5.4
9c26f061 10Release: %{_rel}
859edd7f
SZ
11License: GPL
12Group: Networking/Daemons
859edd7f 13Source0: http://sites.inka.de/bigred/sw/%{name}-%{version}.tar.gz
08a813fb 14# Source0-md5: 9d88f2d090fcafcd0e2fa73b018b6e16
6f30e163 15Source1: %{name}.inetd
859edd7f
SZ
16Patch0: %{name}-autoconf.patch
17Patch1: %{name}-makefile.patch
4490780e 18Patch2: %{name}-pk%{name}-real-peer.patch
a3500c07 19Patch3: %{name}-get_fast_time.patch
4a71d78c 20Patch4: %{name}-alpha.patch
fcdbd9eb 21URL: http://sites.inka.de/bigred/devel/cipe.html
da03665e
ER
22BuildRequires: %{kgcc_package}
23BuildRequires: /usr/bin/openssl
cb64961b
SZ
24BuildRequires: autoconf
25BuildRequires: automake
87c73135 26%{?with_dist_kernel:BuildRequires: kernel-headers}
18ddb359 27BuildRequires: openssl-devel >= 0.9.7d
9d280a4b 28BuildRequires: rpmbuild(macros) >= 1.268
859edd7f
SZ
29BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
30
7cf75f44 31%define __cc %{kgcc}
859edd7f
SZ
32
33%description
34CIPE (the name is shortened from *Crypto IP Encapsulation*) is a
35package for an encrypting IP tunnel device. This can be used to build
36encrypting routers for VPN (Virtual Private Networks) and similar
37applications.
38
cf02c4f2
JR
39%description -l pl.UTF-8
40CIPE (nazwa to skrót od *Crypto IP Encapsulation*) to pakiet do
41tworzenia szyfrowanych tuneli IP. Można je wykorzystać do budowania
42routerów szyfrujących w VPNach (Prywatnych Sieciach Wirtualnych) i
859edd7f
SZ
43podobnych zastosowaniach.
44
8a809272 45%package pkcipe-client
6f30e163 46Summary: The PKCIPE public key tool for CIPE
54b389a4 47Summary(pl.UTF-8): PKCIPE - narzędzie do wykorzystania kluczy publicznych w CIPE
6f30e163 48Group: Networking/Daemons
87c73135 49Requires: %{name} = %{version}-%{release}
9d280a4b 50Requires: /usr/bin/openssl
87c73135 51Obsoletes: cipe-pkcipe
6f30e163 52
8a809272 53%description pkcipe-client
6f30e163
SZ
54CIPE (the name is shortened from *Crypto IP Encapsulation*) is a
55package for an encrypting IP tunnel device. This can be used to build
56encrypting routers for VPN (Virtual Private Networks) and similar
d42dcefd 57applications. This package contains PKCIPE, which simplifies setup of
58CIPE tunnels by using autoconfiguration and public/private key
59mechanisms.
6f30e163 60
cf02c4f2
JR
61%description pkcipe-client -l pl.UTF-8
62CIPE (nazwa to skrót od *Crypto IP Encapsulation*) to pakiet do
63tworzenia szyfrowanych tuneli IP. Można je wykorzystać do budowania
64routerów szyfrujących w VPNach (Prywatnych Sieciach Wirtualnych) i
65podobnych zastosowaniach. Ten pakiet zawiera PKCIPE, który uprasza
d42dcefd 66ustawienie tuneli CIPE przez korzystanie z autokonfiguracji oraz
cf02c4f2 67mechanizmów kluczy publicznych/prywatnych.
6f30e163 68
8a809272
SZ
69%package pkcipe-server
70Summary: The PKCIPE public key tool for CIPE - server side
54b389a4 71Summary(pl.UTF-8): PKCIPE - narzędzie do wykorzystania kluczy publicznych w CIPE
8a809272 72Group: Networking/Daemons
87c73135 73Requires: %{name}-pkcipe-client = %{version}-%{release}
8a809272
SZ
74Requires: inetdaemon
75
76%description pkcipe-server
77CIPE (the name is shortened from *Crypto IP Encapsulation*) is a
78package for an encrypting IP tunnel device. This can be used to build
79encrypting routers for VPN (Virtual Private Networks) and similar
4490780e 80applications. This package contains server part PKCIPE, which
81simplifies setup of CIPE tunnels by using autoconfiguration and
82public/private key mechanisms.
8a809272 83
cf02c4f2
JR
84%description pkcipe-server -l pl.UTF-8
85CIPE (nazwa to skrót od *Crypto IP Encapsulation*) to pakiet do
86tworzenia szyfrowanych tuneli IP. Można je wykorzystać do budowania
87routerów szyfrujących w VPNach (Prywatnych Sieciach Wirtualnych) i
88podobnych zastosowaniach. Ten pakiet zawiera PKCIPE do użycia po
89stronie serwera, który uprasza ustawienie tuneli CIPE przez
90korzystanie z autokonfiguracji oraz mechanizmów kluczy
4490780e 91publicznych/prywatnych.
8a809272 92
9c26f061 93%package -n kernel-cipe
859edd7f 94Summary: CIPE kernel module
54b389a4 95Summary(pl.UTF-8): Moduł jądra CIPE
9c26f061 96Release: %{_rel}@%{_kernel_ver_str}
859edd7f 97Group: Base/Kernel
87c73135 98%{?with_dist_kernel:%requires_releq_kernel_up}
b5dd35a8 99Requires(post,postun): /sbin/depmod
859edd7f 100
9c26f061 101%description -n kernel-cipe
859edd7f
SZ
102CIPE (the name is shortened from *Crypto IP Encapsulation*) is a
103package for an encrypting IP tunnel device. This can be used to build
104encrypting routers for VPN (Virtual Private Networks) and similar
105applications. This package contains a kernel module compiled for
87c73135 106%{_kernel_ver}.
859edd7f 107
cf02c4f2
JR
108%description -n kernel-cipe -l pl.UTF-8
109CIPE (nazwa to skrót od *Crypto IP Encapsulation*) to pakiet do
110tworzenia szyfrowanych tuneli IP. Można je wykorzystać do budowania
111routerów szyfrujących w VPNach (Prywatnych Sieciach Wirtualnych) i
112podobnych zastosowaniach. Ten pakiet zawiera moduł kernela
87c73135 113skompilowany dla %{_kernel_ver}.
9c26f061
SZ
114
115%package -n kernel-smp-cipe
116Summary: CIPE kernel module
54b389a4 117Summary(pl.UTF-8): Moduł jądra CIPE
9c26f061
SZ
118Release: %{_rel}@%{_kernel_ver_str}
119Group: Base/Kernel
87c73135 120%{?with_dist_kernel:%requires_releq_kernel_smp}
b5dd35a8 121Requires(post,postun): /sbin/depmod
9c26f061
SZ
122
123%description -n kernel-smp-cipe
124CIPE (the name is shortened from *Crypto IP Encapsulation*) is a
125package for an encrypting IP tunnel device. This can be used to build
126encrypting routers for VPN (Virtual Private Networks) and similar
127applications. This package contains a kernel module compiled for
87c73135 128%{_kernel_ver}smp.
9c26f061 129
cf02c4f2
JR
130%description -n kernel-smp-cipe -l pl.UTF-8
131CIPE (nazwa to skrót od *Crypto IP Encapsulation*) to pakiet do
132tworzenia szyfrowanych tuneli IP. Można je wykorzystać do budowania
133routerów szyfrujących w VPNach (Prywatnych Sieciach Wirtualnych) i
134podobnych zastosowaniach. Ten pakiet zawiera moduł kernela
87c73135 135skompilowany dla %{_kernel_ver}smp.
859edd7f
SZ
136
137%prep
138%setup -q
139%patch0 -p1
140%patch1 -p1
8a809272 141%patch2 -p1
4d82c0d9 142# %patch3 -p1
4a71d78c 143%patch4 -p1
859edd7f
SZ
144
145%build
146mv -f conf/aclocal.m4 conf/acinclude.m4
c36de5ab 147%{__aclocal} -I conf --output=conf/aclocal.m4
a3500c07 148%{__autoconf} --include conf/
9c26f061
SZ
149
150%configure \
151 --with-linux=%{_kernelsrcdir} \
152 --with-ciped=%{_sbindir}/ciped-cb
153
154%{__make} modules
155
1f56eaab
SZ
156%configure \
157 --with-linux=%{_kernelsrcdir} \
158 --with-ciped=%{_sbindir}/ciped-db \
159 --enable-protocol=4
160
161%{__make} modules
162
87c73135
JB
163mkdir modules
164mv -f */cip?b.o modules
9c26f061 165
4a71d78c 166%{__make} clean
9c26f061 167
8513a55d 168DEFS="-D__SMP__ -D__KERNEL_SMP=1" \
859edd7f
SZ
169%configure \
170 --with-linux=%{_kernelsrcdir} \
691cccf6 171 --with-ciped=%{_sbindir}/ciped-cb \
859edd7f 172 --enable-smp
859edd7f 173
8513a55d 174%{__make}
859edd7f 175
1f56eaab
SZ
176DEFS="-D__SMP__ -D__KERNEL_SMP=1" \
177%configure \
178 --with-linux=%{_kernelsrcdir} \
179 --with-ciped=%{_sbindir}/ciped-cb \
180 --enable-smp \
181 --enable-protocol=4
182
183%{__make}
184
859edd7f
SZ
185%install
186rm -rf $RPM_BUILD_ROOT
859edd7f
SZ
187install -d $RPM_BUILD_ROOT{%{_bindir},%{_sbindir},%{_infodir}} \
188 $RPM_BUILD_ROOT%{_sysconfdir}/cipe/pk \
691cccf6 189 $RPM_BUILD_ROOT/lib/modules/%{_kernel_ver}/misc \
9c26f061 190 $RPM_BUILD_ROOT/lib/modules/%{_kernel_ver}smp/misc \
6f30e163
SZ
191 $RPM_BUILD_ROOT%{_var}/run/cipe \
192 $RPM_BUILD_ROOT/etc/sysconfig/rc-inetd
859edd7f
SZ
193
194install pkcipe/pkcipe $RPM_BUILD_ROOT%{_sbindir}
195install pkcipe/rsa-keygen $RPM_BUILD_ROOT%{_bindir}
1f56eaab
SZ
196mv -f modules/cip?b.o $RPM_BUILD_ROOT/lib/modules/%{_kernel_ver}/misc
197install */cip?b.o $RPM_BUILD_ROOT/lib/modules/%{_kernel_ver}smp/misc
198install */ciped-?b $RPM_BUILD_ROOT%{_sbindir}
859edd7f 199install cipe.info $RPM_BUILD_ROOT%{_infodir}
6f30e163
SZ
200install %{SOURCE1} $RPM_BUILD_ROOT/etc/sysconfig/rc-inetd/pkcipe
201
4e2c5e16
JB
202%clean
203rm -rf $RPM_BUILD_ROOT
204
fc000f8b
ER
205%post -p /sbin/postshell
206-/usr/sbin/fix-info-dir -c %{_infodir}
859edd7f 207
fc000f8b
ER
208%postun -p /sbin/postshell
209-/usr/sbin/fix-info-dir -c %{_infodir}
859edd7f 210
8a809272 211%post pkcipe-client
6f30e163 212[ ! -f %{_sysconfdir}/cipe/identity.priv ] && %{_bindir}/rsa-keygen %{_sysconfdir}/cipe/identity
8a809272
SZ
213
214%post pkcipe-server
9d280a4b 215%service -q rc-inetd reload
6f30e163 216
8a809272 217%postun pkcipe-server
9d280a4b
ER
218if [ "$1" = "0" ]; then
219 %service -q rc-inetd reload
6f30e163
SZ
220fi
221
b5dd35a8 222%post -n kernel-cipe
513155e3 223%depmod %{_kernel_ver}
9c26f061
SZ
224
225%postun -n kernel-cipe
513155e3 226%depmod %{_kernel_ver}
859edd7f 227
b5dd35a8 228%post -n kernel-smp-cipe
513155e3 229%depmod %{_kernel_ver}smp
9c26f061
SZ
230
231%postun -n kernel-smp-cipe
513155e3 232%depmod %{_kernel_ver}smp
859edd7f
SZ
233
234%files
235%defattr(644,root,root,755)
4a71d78c 236%doc README* tcpdump.patch CHANGES samples
1f56eaab 237%attr(755,root,root) %{_sbindir}/ciped-*
859edd7f 238%dir %{_sysconfdir}/cipe
2a495601 239%attr(755,root,root) %dir %{_var}/run/cipe
87c73135 240%{_infodir}/*.info*
859edd7f 241
8a809272 242%files pkcipe-client
6f30e163
SZ
243%defattr(644,root,root,755)
244%attr(755,root,root) %{_bindir}/rsa-keygen
245%attr(755,root,root) %{_sbindir}/pkcipe
246%attr(700,root,root) %dir %{_sysconfdir}/cipe/pk
8a809272
SZ
247
248%files pkcipe-server
249%defattr(644,root,root,755)
da03665e 250%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/rc-inetd/pkcipe
6f30e163 251
9c26f061
SZ
252%files -n kernel-cipe
253%defattr(644,root,root,755)
2904c448 254/lib/modules/%{_kernel_ver}/misc/cip*.o*
9c26f061
SZ
255
256%files -n kernel-smp-cipe
859edd7f 257%defattr(644,root,root,755)
2904c448 258/lib/modules/%{_kernel_ver}smp/misc/cip*.o*
This page took 0.103994 seconds and 4 git commands to generate.