bird.spec 1.33 KB
Newer Older
Ondřej Filip's avatar
Ondřej Filip committed
1 2
Summary: BIRD Internet Routing Daemon
Name: bird
Ondřej Zajíček's avatar
Ondřej Zajíček committed
3
Version: 1.2.1
Ondřej Filip's avatar
Ondřej Filip committed
4
Release: 1
Ondřej Filip's avatar
Ondřej Filip committed
5 6 7 8
Copyright: GPL
Group: Networking/Daemons
Source: ftp://bird.network.cz/pub/bird/bird-%{version}.tar.gz
Source1: bird.init
9
Source2: birdc6
Ondřej Filip's avatar
Ondřej Filip committed
10 11 12 13 14 15 16 17 18 19 20 21
Buildroot: /var/tmp/bird-root
Url: http://bird.network.cz
Prereq: /sbin/chkconfig

%description
BIRD is dynamic routing daemon supporting IPv4 and IPv6 versions of routing
protocols BGP, RIP and OSPF.

%prep
%setup -n bird-%{version}

%build
22
./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var --enable-ipv6
23 24
make
mv bird bird6
25 26
make clean
./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var
Ondřej Filip's avatar
Ondřej Filip committed
27 28
make

29

Ondřej Filip's avatar
Ondřej Filip committed
30 31
%install
rm -rf $RPM_BUILD_ROOT/*
32
make install prefix=$RPM_BUILD_ROOT/usr sysconfdir=$RPM_BUILD_ROOT/etc localstatedir=$RPM_BUILD_ROOT/var
33
install bird6 $RPM_BUILD_ROOT/usr/sbin
Ondřej Filip's avatar
Ondřej Filip committed
34 35

cd $RPM_BUILD_ROOT
36 37
install -d etc/rc.d/init.d
install $RPM_SOURCE_DIR/bird.init etc/rc.d/init.d/bird
38
install $RPM_SOURCE_DIR/birdc6 usr/sbin/birdc6
Ondřej Filip's avatar
Ondřej Filip committed
39 40 41

%post
/sbin/ldconfig
42
/sbin/chkconfig --add bird
Ondřej Filip's avatar
Ondřej Filip committed
43 44 45
 
%preun
if [ $1 = 0 ] ; then
46
        /sbin/chkconfig --del bird
Ondřej Filip's avatar
Ondřej Filip committed
47 48 49 50
fi                                                                              

%files
%attr(755,root,root) /usr/sbin/bird
51
%attr(755,root,root) /usr/sbin/bird6
Ondřej Filip's avatar
Ondřej Filip committed
52
%attr(755,root,root) /usr/sbin/birdc
53
%attr(755,root,root) /usr/sbin/birdc6
54
%attr(755,root,root) /etc/rc.d/init.d/bird