Update copyrights.
[oweals/tinc.git] / redhat / tinc.spec
index beadcfe7422c502ab3bfc437eb718edbd2f077a0..b7357d93de9ec0e2c729a3f8d9c482fe6e671838 100644 (file)
@@ -1,12 +1,14 @@
 Summary: tinc Virtual Private Network daemon
 Name: tinc
 Summary: tinc Virtual Private Network daemon
 Name: tinc
-Version: 1.0pre1
-Release: 2
+Version: 1.0
+Release: cvs
 Copyright: GPL
 Group: System Environment/Daemons
 URL: http://tinc.nl.linux.org/
 Copyright: GPL
 Group: System Environment/Daemons
 URL: http://tinc.nl.linux.org/
-Source0: %{name}-%{version}.tar.gz
-Buildroot: /var/tmp/%{name}-%{version}-%{release}
+Source0: %{name}-%{version}-%{release}.tar.gz
+Buildroot: /var/tmp/%{name}
+#-%{version}-%{release}
+#Requires: iproute
 # for building the package the following is required:
 # /usr/bin/texi2html /usr/bin/patch
 
 # for building the package the following is required:
 # /usr/bin/texi2html /usr/bin/patch
 
@@ -26,10 +28,10 @@ See http://tinc.nl.linux.org/
 
 %prep
 
 
 %prep
 
-%setup -q -n %{name}-%{version}
+%setup -q -n %{name}-%{version}-%{release}
 
 %build
 
 %build
-./configure --prefix=/usr --sysconfdir=/etc
+./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var
 make
 /usr/bin/texi2html doc/tinc.texi
 
 make
 /usr/bin/texi2html doc/tinc.texi
 
@@ -41,29 +43,8 @@ gzip $RPM_BUILD_ROOT/usr/info/tinc.info
 mkdir -p $RPM_BUILD_ROOT/etc/rc.d/init.d/
 cp redhat/tinc $RPM_BUILD_ROOT/etc/rc.d/init.d/
 
 mkdir -p $RPM_BUILD_ROOT/etc/rc.d/init.d/
 cp redhat/tinc $RPM_BUILD_ROOT/etc/rc.d/init.d/
 
-ME=my.vpn.ip.number
-PEER=peer.vpn.ip.number
-PEEREAL=peer.real.ip.number
-
-umask 077
-mkdir -p $RPM_BUILD_ROOT/etc/tinc/$PEER/passphrases
-cat <<END >$RPM_BUILD_ROOT/etc/tinc/$PEER/tinc.conf
-# Sample tinc configuration. 
-# Insert your own ip numbers instead of the placeholders,
-# and be sure to use your own passphrases.
-# See man tinc.conf(5) tincd(8) genauth(8), info tinc and 
-# /usr/doc/%{name}-%{version}/tinc.conf.sample
-TapDevice = /dev/tap0
-ConnectTo = $PEEREAL
-MyVirtualIP = $ME/32
-AllowConnect = no
-END
-cat <<END >$RPM_BUILD_ROOT/etc/tinc/$PEER/passphrases/local
-128 0c647a1fd34da9d04c1d340ae9363f31
-END
-cat <<END >$RPM_BUILD_ROOT/etc/tinc/$PEER/passphrases/$PEER
-128 aea5a5d414fea63ee3829b592afc0fba
-END
+mkdir -p $RPM_BUILD_ROOT/etc/tinc/
+touch $RPM_BUILD_ROOT/etc/tinc/nets.boot
 
 %clean
 rm -rf $RPM_BUILD_ROOT
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -82,7 +63,7 @@ grep -q '^tinc[[:space:]]' /etc/services || patch -s /etc/services << END
   hmmp-ind     612/tcp         dqs313_intercell# HMMP Indication / DQS
   hmmp-ind     612/udp         dqs313_intercell# HMMP Indication / DQS
 + tinc         655/tcp         TINC            # tinc vpn
   hmmp-ind     612/tcp         dqs313_intercell# HMMP Indication / DQS
   hmmp-ind     612/udp         dqs313_intercell# HMMP Indication / DQS
 + tinc         655/tcp         TINC            # tinc vpn
-+ tinc         655/udp         TINC            # tinc.nl.linux.org
++ tinc         655/udp         TINC            # http://tinc.nl.linux.org/
   #
   # UNIX specific services
 END
   #
   # UNIX specific services
 END
@@ -91,21 +72,20 @@ grep -q '^alias tap0' /etc/conf.modules || cat >> /etc/conf.modules << END
 # tinc uses ethertap/netlink
 alias tap0 ethertap
 alias char-major-36 netlink_dev
 # tinc uses ethertap/netlink
 alias tap0 ethertap
 alias char-major-36 netlink_dev
+alias char-major-10-200 tun
 END
 END
-/sbin/install-info /usr/info/tinc.info.gz /usr/info/dir --entry= \
-       "* tinc: (tinc).                                The tinc Manual."
+/sbin/install-info /usr/info/tinc.info.gz /usr/info/dir 
 
 %preun
 
 %preun
+/sbin/install-info --delete /usr/info/tinc.info.gz /usr/info/dir
+
 %postun
 
 %files
 %postun
 
 %files
-%doc AUTHORS ChangeLog NEWS README THANKS *.html doc/tincd.conf.sample
+%doc AUTHORS ChangeLog NEWS README THANKS *.html
 %config /etc/tinc/
 %config /etc/tinc/
-/etc/rc.d/init.d/tinc
-/usr/sbin/genauth
+%attr(0755,root,root) /etc/rc.d/init.d/tinc
 /usr/sbin/tincd
 /usr/sbin/tincd
-/usr/lib/tinc/
-/usr/man/man5/tincd.conf.5
-/usr/man/man8/genauth.8
+/usr/man/man5/tinc.conf.5
 /usr/man/man8/tincd.8
 /usr/info/tinc.info.gz
 /usr/man/man8/tincd.8
 /usr/info/tinc.info.gz