/[gentoo-x86]/net-misc/quagga/quagga-0.99.22.4.ebuild
Gentoo

Contents of /net-misc/quagga/quagga-0.99.22.4.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.8 - (show annotations) (download)
Wed Oct 9 17:10:41 2013 UTC (6 years ago) by ago
Branch: MAIN
Changes since 1.7: +2 -2 lines
Stable for sparc, wrt bug #475706

(Portage version: 2.1.12.2/cvs/Linux ppc64, RepoMan options: --include-arches="sparc", signed Manifest commit with key 7194459F)

1 # Copyright 1999-2013 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/net-misc/quagga/quagga-0.99.22.4.ebuild,v 1.7 2013/10/07 19:30:59 ago Exp $
4
5 EAPI="5"
6
7 CLASSLESS_BGP_PATCH=ht-20040304-classless-bgp.patch
8
9 AUTOTOOLS_AUTORECONF=1
10 inherit autotools-utils eutils flag-o-matic multilib pam readme.gentoo user
11
12 DESCRIPTION="A free routing daemon replacing Zebra supporting RIP, OSPF and BGP"
13 HOMEPAGE="http://quagga.net/"
14 SRC_URI="mirror://nongnu/${PN}/${P}.tar.xz
15 bgpclassless? ( http://hasso.linux.ee/stuff/patches/quagga/${CLASSLESS_BGP_PATCH} )"
16
17 LICENSE="GPL-2"
18 SLOT="0"
19 KEYWORDS="alpha amd64 arm hppa ppc ~s390 sparc x86"
20 IUSE="bgpclassless caps doc elibc_glibc ipv6 multipath ospfapi pam +readline snmp tcp-zebra"
21
22 COMMON_DEPEND="
23 caps? ( sys-libs/libcap )
24 snmp? ( net-analyzer/net-snmp )
25 readline? (
26 sys-libs/readline
27 pam? ( sys-libs/pam )
28 )
29 !elibc_glibc? ( dev-libs/libpcre )"
30 DEPEND="${COMMON_DEPEND}
31 app-arch/xz-utils
32 >=sys-devel/libtool-2.2.4"
33 RDEPEND="${COMMON_DEPEND}
34 sys-apps/openrc
35 sys-apps/iproute2"
36
37 DISABLE_AUTOFORMATTING=1
38 DOC_CONTENTS="Sample configuration files can be found in /usr/share/doc/${PF}/samples
39 You have to create config files in /etc/quagga before
40 starting one of the daemons.
41
42 You can pass additional options to the daemon by setting the EXTRA_OPTS
43 variable in their respective file in /etc/conf.d
44
45 Starting from version 0.99.18, quagga no longer supports the realms patch.
46 The patch was abandoned upstream and once again didn't apply; it needs a
47 dedicated maintainer, if it is still necessary."
48
49 pkg_setup() {
50 enewgroup quagga
51 enewuser quagga -1 -1 /var/empty quagga
52 }
53
54 src_prepare() {
55 # Classless prefixes for BGP
56 # http://hasso.linux.ee/doku.php/english:network:quagga
57 use bgpclassless && epatch "${DISTDIR}/${CLASSLESS_BGP_PATCH}"
58
59 autotools-utils_src_prepare
60 }
61
62 src_configure() {
63 append-flags -fno-strict-aliasing
64
65 # do not build PDF docs
66 export ac_cv_prog_PDFLATEX=no
67 export ac_cv_prog_LATEXMK=no
68
69 local myeconfargs=(
70 --enable-user=quagga
71 --enable-group=quagga
72 --enable-vty-group=quagga
73 --with-cflags="${CFLAGS}"
74 --sysconfdir=/etc/quagga
75 --enable-exampledir=/usr/share/doc/${PF}/samples
76 --localstatedir=/run/quagga
77 --disable-static
78 --disable-pie
79 $(use_enable caps capabilities)
80 $(usex snmp '--enable-snmp' '' '' '')
81 $(use_enable !elibc_glibc pcreposix)
82 $(use_enable tcp-zebra)
83 $(use_enable doc)
84 $(usex multipath $(use_enable multipath) '' '=0' '')
85 $(usex ospfapi '--enable-opaque-lsa --enable-ospf-te --enable-ospfclient' '' '' '')
86 $(use_enable readline vtysh)
87 $(use_with pam libpam)
88 $(use_enable ipv6)
89 $(use_enable ipv6 babeld) # babeld does not build properly with USE="-ipv6", bug #446289
90 $(use_enable ipv6 ripngd)
91 $(use_enable ipv6 ospf6d)
92 $(use_enable ipv6 rtadv)
93 )
94 autotools-utils_src_configure
95 }
96
97 src_install() {
98 autotools-utils_src_install
99 readme.gentoo_create_doc
100
101 keepdir /etc/quagga
102 fowners root:quagga /etc/quagga
103 fperms 0770 /etc/quagga
104
105 # install zebra as a file, symlink the rest
106 newinitd "${FILESDIR}"/quagga-services.init.3 zebra
107
108 for service in ripd ospfd bgpd $(use ipv6 && echo babeld ripngd ospf6d); do
109 dosym zebra /etc/init.d/${service}
110 done
111
112 use readline && newpamd "${FILESDIR}/quagga.pam" quagga
113
114 insinto /etc/logrotate.d
115 newins redhat/quagga.logrotate quagga
116 }

  ViewVC Help
Powered by ViewVC 1.1.20