3 %bcond_without ssl # build without encryption ability
5 Summary: Virtual tunnel over TCP/IP networks
6 Summary(pl.UTF-8): Wirtualne tunele poprzez sieci TCP/IP
12 Group: Networking/Daemons
13 Source0: http://dl.sourceforge.net/vtun/%{name}-%{version}.tar.gz
14 # Source0-md5: c342ffe77055d4248a38f0b380f28c1b
16 Source2: %{name}.sysconfig
17 Patch0: %{name}-makefile.patch
18 Patch1: %{name}-expect.patch
19 Patch2: %{name}-autoheader.patch
20 Patch3: %{name}-getpt.patch
21 Patch4: %{name}-sslauth.patch
22 Patch5: %{name}-ac.patch
23 Patch6: %{name}-lzo2.patch
24 Patch7: %{name}-linking.patch
25 URL: http://vtun.sourceforge.net/
26 BuildRequires: autoconf
27 BuildRequires: automake
30 BuildRequires: lzo-devel >= 2.0.1
31 %{?with_ssl:BuildRequires: openssl-devel >= 0.9.7d}
32 BuildRequires: rpmbuild(macros) >= 1.268
33 BuildRequires: zlib-devel
34 Requires(post,preun): /sbin/chkconfig
37 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
39 %define _localstatedir /var
42 VTun provides the method for creating Virtual Tunnels over TCP/IP
43 networks and allows to shape, compress, encrypt traffic in that
44 tunnels. Supported type of tunnels are: PPP, IP, Ethernet and most of
45 other serial protocols and programs. VTun is easily and highly
46 configurable, it can be used for various network task like VPN, Mobil
47 IP, Shaped Internet access, IP address saving, etc. It is completely
48 user space implementation and does not require modification to any
49 kernel parts. You need SSLeay-devel and lzo-devel to build it.
51 %description -l pl.UTF-8
52 VTun umożliwia tworzenie tuneli poprzez sieci TCP/IP wraz z
53 przydzielaniem pasma, kompresją, szyfrowaniem danych w tunelach.
54 Wspierane typy tuneli to: PPP, IP, Ethernet i większość pozostałych
55 protokołów szeregowych. VTun jest łatwy i elastyczny w konfiguracji.
56 Może zostać wykorzystany do takich sieciowych zastosowań jak VPN,
57 Mobil IP, łącza o określonym paśmie oraz innych. Działa w warstwie
58 user space, więc nie wymaga dodatkowego wsparcia w jądrze.
70 cp -f /usr/share/automake/config.* .
71 # aclocal.m4 is only local, don't try to rebuild
75 %{?with_ssl:--with-crypto-headers=%{_includedir}/openssl} \
76 %{!?with_ssl:--disable-ssl} \
81 rm -rf $RPM_BUILD_ROOT
82 install -d $RPM_BUILD_ROOT{%{_sbindir},%{_mandir}/man8} \
83 $RPM_BUILD_ROOT{/etc/{sysconfig,rc.d/init.d},%{_localstatedir}/log/vtun}
86 DESTDIR=$RPM_BUILD_ROOT \
89 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/vtund
90 install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/vtun
91 touch $RPM_BUILD_ROOT%{_sysconfdir}/vtund.conf
92 rm -f $RPM_BUILD_ROOT%{_mandir}/man8/vtun.8
93 echo ".so vtund.8" > $RPM_BUILD_ROOT%{_mandir}/man8/vtun.8
96 rm -rf $RPM_BUILD_ROOT
99 /sbin/chkconfig --add vtund
100 %service vtund restart "vtun daemons"
103 if [ "$1" = "0" ]; then
105 /sbin/chkconfig --del vtund
109 %defattr(644,root,root,755)
110 %doc ChangeLog Credits README README.Setup README.Shaper FAQ TODO vtund.conf
111 %attr(754,root,root) /etc/rc.d/init.d/vtund
112 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/vtun
113 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/vtund.conf
114 %attr(755,root,root) %{_sbindir}/vtund
115 %attr(755,root,root) %dir /var/log/vtund