/[gentoo-x86]/net-misc/wicd/wicd-1.7.1_beta2-r5.ebuild
Gentoo

Contents of /net-misc/wicd/wicd-1.7.1_beta2-r5.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (show annotations) (download)
Tue Sep 13 19:25:14 2011 UTC (8 years, 3 months ago) by tomka
Branch: MAIN
CVS Tags: HEAD
Changes since 1.1: +1 -1 lines
FILE REMOVED
Fix bugs 351337 (ad-hoc-net), 306423 (wpa-hex-template)

(Portage version: 2.1.10.15/cvs/Linux i686)

1 # Copyright 1999-2011 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/net-misc/wicd/wicd-1.7.1_beta2-r5.ebuild,v 1.1 2011/09/09 11:18:41 tomka Exp $
4
5 EAPI=3
6
7 PYTHON_DEPEND="2"
8 PYTHON_USE_WITH="ncurses? xml"
9 SUPPORT_PYTHON_ABIS="1"
10 RESTRICT_PYTHON_ABIS="3.* *-jython"
11 DISTUTILS_USE_SEPARATE_SOURCE_DIRECTORIES="1"
12
13 inherit eutils distutils
14
15 MY_P=${P/_beta/b}
16 S="${WORKDIR}/${MY_P}"
17
18 DESCRIPTION="A lightweight wired and wireless network manager for Linux"
19 HOMEPAGE="http://wicd.sourceforge.net/"
20 SRC_URI="http://downloads.wicd.net/src/testing/1.7.x/${MY_P}.tar.bz2"
21
22 LICENSE="GPL-2"
23 SLOT="0"
24 KEYWORDS="~amd64 ~ppc ~ppc64 ~x86"
25 IUSE="X +gtk ioctl libnotify ncurses nls +pm-utils"
26
27 DEPEND=""
28 # Maybe virtual/dhcp would work, but there are enough problems with
29 # net-misc/dhcp that I want net-misc/dhcpcd to be guarenteed to be considered
30 # first if none are installed.
31 RDEPEND="
32 dev-python/dbus-python
33 X? ( gtk? ( dev-python/pygtk
34 || (
35 x11-misc/ktsuss
36 x11-libs/gksu
37 kde-base/kdesu
38 )
39 )
40 )
41 || (
42 net-misc/dhcpcd
43 net-misc/dhcp
44 net-misc/pump
45 )
46 net-wireless/wireless-tools
47 net-wireless/wpa_supplicant
48 || (
49 sys-apps/net-tools
50 sys-apps/ethtool
51 )
52 !gtk? ( dev-python/pygobject )
53 ioctl? ( dev-python/python-iwscan dev-python/python-wpactrl )
54 libnotify? ( dev-python/notify-python )
55 ncurses? (
56 >=dev-python/urwid-0.9.9.1
57 dev-python/pygobject
58 )
59 pm-utils? ( >=sys-power/pm-utils-1.1.1 )
60 "
61 DOCS="CHANGES NEWS AUTHORS README"
62
63 src_prepare() {
64 epatch "${FILESDIR}"/${P}-init.patch
65 epatch "${FILESDIR}"/${PN}-init-sve-start.patch
66 # get rid of opts variable to fix bug 381885
67 sed -i "/opts/d" "in/init=gentoo=wicd.in"
68 # Need to ensure that generated scripts use Python 2 at run time.
69 sed -e "s:self.python = '/usr/bin/python':self.python = '/usr/bin/python2':" \
70 -i setup.py || die "sed failed"
71 python_copy_sources
72 }
73
74 src_configure() {
75 local myconf
76 use gtk || myconf="${myconf} --no-install-gtk"
77 use libnotify || myconf="${myconf} --no-use-notifications"
78 use ncurses || myconf="${myconf} --no-install-ncurses"
79 use pm-utils || myconf="${myconf} --no-install-pmutils"
80 configuration() {
81 $(PYTHON) ./setup.py configure --no-install-docs --resume=/usr/share/wicd/scripts/ --suspend=/usr/share/wicd/scripts/ --verbose ${myconf}
82 }
83 python_execute_function -s configuration
84 }
85
86 src_install() {
87 distutils_src_install
88 keepdir /var/lib/wicd/configurations \
89 || die "keepdir failed, critical for this app"
90 keepdir /etc/wicd/scripts/{postconnect,disconnect,preconnect} \
91 || die "keepdir failed, critical for this app"
92 keepdir /var/log/wicd \
93 || die "keepdir failed, critical for this app"
94 use nls || rm -rf "${D}"/usr/share/locale
95 }
96
97 pkg_postinst() {
98 distutils_pkg_postinst
99
100 elog "You may need to restart the dbus service after upgrading wicd."
101 echo
102 elog "To start wicd at boot, add /etc/init.d/wicd to a runlevel and:"
103 elog "- Remove all net.* initscripts (except for net.lo) from all runlevels"
104 elog "- Add these scripts to the RC_PLUG_SERVICES line in /etc/rc.conf"
105 elog "(For example, rc_hotplug=\"!net.eth* !net.wlan*\")"
106 # Maintainer's note: the consolekit use flag short circuits a dbus rule and
107 # allows the connection. Else, you need to be in the group.
108 if ! has_version sys-auth/pambase[consolekit]; then
109 ewarn "Wicd-1.6 and newer requires your user to be in the 'users' group. If"
110 ewarn "you are not in that group, then modify /etc/dbus-1/system.d/wicd.conf"
111 fi
112 }

  ViewVC Help
Powered by ViewVC 1.1.20