]> git.pld-linux.org Git - packages/vtun.git/blob - vtun.spec
ad0b7f04e0b5c4c164dc76936994b03637f826e5
[packages/vtun.git] / vtun.spec
1 # Conditional build:
2 # _without_ssl - build without encryption ability
3
4 Summary:        Virtual tunnel over TCP/IP networks
5 Summary(pl):    Wirtualne tunele poprzez sieci TCP/IP
6 Name:           vtun
7 Version:        2.5b1
8 Release:        6
9 Epoch:          1
10 License:        GPL
11 Group:          Networking/Daemons
12 Group(de):      Netzwerkwesen/Server
13 Group(pl):      Sieciowe/Serwery
14 Vendor:         Maxim Krasnyansky <max_mk@yahoo.com>
15 Source0:        http://vtun.sourceforge.net/%{name}-%{version}.tar.gz
16 Source1:        %{name}.init
17 Source2:        %{name}.sysconfig
18 Patch0:         %{name}-makefile.patch
19 Patch1:         %{name}-iproute.patch
20 Patch2:         %{name}-autoheader.patch
21 Patch3:         %{name}-getpt.patch
22 URL:            http://vtun.sourceforge.net/
23 BuildRequires:  autoconf
24 BuildRequires:  automake
25 BuildRequires:  lzo-devel
26 %{!?_without_ssl:BuildRequires: openssl-devel >= 0.9.6a}
27 BuildRequires:  zlib-devel
28 BuildRequires:  bison
29 BuildRequires:  flex
30 Prereq:         rc-scripts
31 Prereq:         /sbin/chkconfig
32 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
33 Obsoletes:      vppp
34
35 %define         _localstatedir  /var
36
37 %description
38 VTun provides the method for creating Virtual Tunnels over TCP/IP
39 networks and allows to shape, compress, encrypt traffic in that
40 tunnels. Supported type of tunnels are: PPP, IP, Ethernet and most of
41 other serial protocols and programs. VTun is easily and highly
42 configurable, it can be used for various network task like VPN, Mobil
43 IP, Shaped Internet access, IP address saving, etc. It is completely
44 user space implementation and does not require modification to any
45 kernel parts. You need SSLeay-devel and lzo-devel to build it.
46
47 %description -l pl
48 VTun umo¿liwia tworzenie Wirtualnych Tunelu poprzez sieci TCP/IP wraz
49 z przydzielaniem pasma, kompresj±, szyfrowaniem danych w tunelach.
50 Wspierane typy tuneli to: PPP, IP, Ethernet i wiêkszo¶æ pozosta³ych
51 protoko³ów szeregowych.
52
53 %prep
54 %setup -q
55 %patch0 -p1
56 %patch1 -p1
57 %patch2 -p1
58 %patch3 -p1
59
60 %build
61 aclocal
62 autoheader
63 autoconf
64 %configure \
65         %{!?_without_ssl:--with-crypto-headers=%{_includedir}/openssl} \
66         %{?_without_ssl:--disable-ssl} \
67         --enable-lzo
68 %{__make}
69
70 %install
71 rm -rf $RPM_BUILD_ROOT
72 install -d $RPM_BUILD_ROOT{%{_sbindir},%{_mandir}/man8} \
73         $RPM_BUILD_ROOT{/etc/{sysconfig,rc.d/init.d},%{_localstatedir}/log/vtun}
74
75 %{__make} install DESTDIR=$RPM_BUILD_ROOT
76
77 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/vtund
78 install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/vtun
79
80 gzip -9nf ChangeLog Credits README README.Setup README.Shaper FAQ TODO
81
82 %clean
83 rm -rf $RPM_BUILD_ROOT
84
85 %post
86 /sbin/chkconfig --add vtund
87 if [ -f /var/lock/subsys/vtund ]; then
88         /etc/rc.d/init.d/vtund restart >&2
89 else
90         echo "Run \"/etc/rc.d/init.d/vtund start\" to start vtun daemons."
91 fi
92
93 %preun
94 if [ "$1" = "0" ]; then
95         if [ -f /var/lock/subsys/vtund ]; then
96                 /etc/rc.d/init.d/vtund stop >&2
97         fi
98         /sbin/chkconfig --del vtund
99 fi
100
101 %files
102 %defattr(644,root,root,755)
103 %doc *.gz
104 %attr(754,root,root) /etc/rc.d/init.d/vtund
105 %attr(640,root,root) %config(noreplace) %verify(not size mtime md5) /etc/sysconfig/vtun
106 %attr(640,root,root) %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/vtund.conf
107 %attr(755,root,root) %{_sbindir}/vtund
108 %attr(755,root,root) %dir /var/log/vtund
109 %{_mandir}/man*/*
This page took 0.031515 seconds and 2 git commands to generate.