net-misc/wicd: added v1.7.2.4-r3, Gentoo's ebuild plus minor changes

This commit is contained in:
Wuodan0 2013-04-04 07:41:00 +00:00
parent 53cb29028f
commit 0f303dd417
8 changed files with 330 additions and 0 deletions

View file

@ -1,8 +1,16 @@
AUX wicd-1.7.1-provide-net.patch 327 SHA256 9da2b1ccbc1c363466048bb1adf91612dd68b988bca96daad79ae1f81a89e09b SHA512 7f1d9d70513a367db7b296608d9864bfc105d44204e051c4c1456e5e7dc995b1c73399e8fd5fdd6499538568dcca2b1b6af928519461abd92734d1b16d3406e8 WHIRLPOOL 9314947dcf5fbf17164b5201c7cb8a78de86143c8c4f455b31dcf16141e6f401786dedce1ebdeabac202cba9e2ded8e33edb3ca32214be425f03fb2d60c27e72
AUX wicd-1.7.1_beta2-init.patch 409 SHA256 473146793cc9cf8b2b780c1ce13f27138662f9942b53e5a7e293634196fbebcf SHA512 1257e3d07b152b17394960d35fac196ed74e2314da8c7e25959f2a10498f4ba39673929963b75a7170ac7070f061501f3a404b07a891e6c108c5386a3711cedb WHIRLPOOL a075bbc33344a23ee088a5b7bdfc76d25f2335deac4d20d1df9a859728ea3fc60e25deb55d29e5084caeffa99f74f6ead79363dc96cfa45aaa29fe98f5386284
AUX wicd-1.7.1_pre20111210-wpa-psk-hex-template.patch 920 SHA256 b721a8b90c97330d12787608108dd8f1db99742c596a786d4fcfa1f3abb19be6 SHA512 35ca12131929bc16f43489a5db93461db40eb8756322349c399fe05c866195d4ee923f9b04bc060b3f1f24b7df962bafa45a4ea42414d7c6fa78b00f42eabe28 WHIRLPOOL a261fe450ed6b5a41e363c206388e429525afd586eaf39a60050a81ab6744eb8c0d194e929b18c27af0f112fe3ddd57131968f9fab6ea074bf7af86fbff97999
AUX wicd-1.7.2.4-fix-dbus-error.patch 582 SHA256 665c86a6412fd8178ef3ef1552180d4d6ec86f2c625cb6640816b5952e6b1192 SHA512 cacfd1a03cc862c030d21c2327b92750427fceb768923ef64845bf25cb43141b62139329d35f7cd2d2299d13afe8ae7d7e9a2596e516565529015adeca9a8c6d WHIRLPOOL 566ef450e2d110c322c1424d699063ed91b5ab9f8f6067a0a8f8fccde6702b8d319f05afe7d3d600310c9d81e2369102fe85179f34dbcc6ebad28bb9de11eb27
AUX wicd-1.7.2.4-second-urwid.patch 1378 SHA256 3eed2084f5631bdeb4a27ce1f729aa4be8cb12414af5364312b09005b75bc7b5 SHA512 8c9ddf06eeba28408f38ed9c1bfc2e9bcd8f8a9df86b3dd8675c82c673e38fd180dff113e7965cae5d4448f27ee5af4378daa34d147a15151811e854606a1d92 WHIRLPOOL 360151ca59baf2300309f851ac73faf3044d783c6901d2327f56bfc2ac7672f2d53ac7d7034ea072e314cf487499a5ef0e3c0255782c669d92ee0e7b42bf4ab5
AUX wicd-1.7.2.4-urwid.patch 2281 SHA256 6770f31f3a701fcdb019562ec63e53653463aca471d0d907227f6608d671cdf2 SHA512 0376d1f5fc3d9cd857fafa30024b6e754d202bbebc0c7fd498b77fd4c34d70cacd4c2b1cf6f5bd4be0ef6f6e2617feceab3e5b734e91ab2efe6c69f1a6a14508 WHIRLPOOL 1ebdf2f3c1362aa70fbed202c9d5afdc42ca12e1876c39184c2d52e681207a531b0bfd28c3131e3eaca158cc4277f61e7b2369a7414b1405189200b11d8d026a
AUX wicd-1.7.9999_p874-delay-daemon-connect.patch 470 SHA256 639895fd9b10536a82c26ed0862bea21267af6263b7af221c5d9b7adb41e6a1f SHA512 12a9aa64624d538d7a71b1a91e875d8761491bad9b81981071b44fc7e834e0aad3e07a5559d3b2515b798a333f57244ff520ef0b3debb0217269477ec70ee6ac WHIRLPOOL f05c0f8962360a99226559363b4eef7258691ba6aadf9d04df142b2fbbb25ce20debd96abaa4c743054f8e730e5d6b6b9ea0a576771c03945374cd0cce470b46
AUX wicd-1.7.9999_p874-undefined-LANG.patch 946 SHA256 747f5a0b87460148af67c37cb63c563dd0ec68b362a1853836515f4ccfed182e SHA512 c2d197d41a84975bb3caf44de9b05b741b6702c38079ecc917632f9eedcf2be71373416154013690620511f2e9e99fb0d88cee0b22292fe007795cde664e63e5 WHIRLPOOL 0b36b1d1cf4de2ec375f70e8bfbf7d453eb5104bd3aa1b0e4e2ade6b9e211f1d0759cdd7b78a356ce5ef2d8a4cf5017a2529e8f274b41408597d45315e171085
AUX wicd-disable-autostart.patch 165 SHA256 00fb46bb62289e8501bace58fe045f955d1957606931e8c0cb07e1fcb0ad83da SHA512 ee74dac0ff379dfa668eaf8d41c5bb39086f442d2705c88c2357e5f712dcba5de29a29a6002a3536f00925b8ab0ce1996a33847d74a94d38df121465c9ff7bee WHIRLPOOL caba44f3c538daedb65cb8f4c6a66f8120c2577c6a13288059f01457bf4ce5a4230927babc7192d71c9b71f436669257f0d9b39107a5a4730ff4f218bf50554a
AUX wicd-init-sve-start.patch 127 SHA256 53a987d6cee601668172c5866f794b0285b071ebd7baf9fa0c3a26243e538cd7 SHA512 9bb9186a915f82f891783f32f9891868bed9ad50dea1d69b8e1b5cc3feb993f86992dbd5c7d0ae63844a88e89905e0d8dc41bfcd44872982d87493ad23c296d0 WHIRLPOOL b565c93721e723411f511bab36235eac7d9013ab417dfb8ced53a727d8cffe314e226bf5a2d5bde93ec12dc3e54a59f8e2caa03abf42a7fa6857eb07adcb3171
DIST Icone-Wicd-Lucid.tar.gz 9015 SHA256 6e4e3483c6cff7398e6871dd3e4360e361e5c6e64007e8e1240fd1c259ac707e SHA512 0df0dbdf05b462264dca2dd9955454a82f688b0fbfa7c2ad70a424df57eb27b35561d37819fc88b5746cff8a54de5b7b43ec325d2f98a4a1a30e4d500e86d2f8 WHIRLPOOL 336f363092c9bac7523047b6052a856a699820147967820418c6ac1ca528c472d371c6c211c505c325b5eb001812042c01425b05e1dfdf2d4a528f96686c530a
DIST wicd-1.7.2.4.tar.gz 439297 SHA256 dcfdfb5dbbb49dbb9b205fddf064d6b1a4e88f66f1cf40d12fb7fe0e0c7cdc97 SHA512 6dd8d4726c5f9c943d90305b7ed70573b42b5dae00de443209d9f526778e91ac01aabffa14447c47374b4d9986133aacfcc970735d1b5befa232da44d3190d7c WHIRLPOOL 59885a22dbf350e73a55fdbf7ea1c9b93a339edae116beb1c22c271762d90488ecdeb7952a4efc8241d362b5bafcaccf88053c4d5c41468cba0cd524cf2a5756
DIST wicd-mac4lin-icons.tar.xz 53136 SHA256 4c48c769c71f962415e3bd3573557e9288351afb867347f9a6f652883ae31011 SHA512 98ed3f92ec361aa8651c64efdb5128b8f73068f1cf2423640dafc4b46889ae32c1d1f56f509ad609b2bf98f634f8ada4c501f2294e3a64affd1befd4400498a8 WHIRLPOOL 84c097432ebb6ca66c0fa48d4226c8da5f6342b6fdeeb9546c98952b8f6e52a1f87d0ba23c1b409f3008432e5c6346bf65949dad99070804b1dcc2c1055eb9ea
EBUILD wicd-1.7.2.4-r3.ebuild 4892 SHA256 1a910d092d03a28cd6cfaa72cf50621d02cbd9dc993d8c7769efabd33eee7481 SHA512 fdc0d2be86d88acc76adf662de07b00704d993047a1926fd51edee539397592fc2280726d20873cff452df2611fb186243334636b11b0f7400f4ef44d9d623f4 WHIRLPOOL f7b53de911fd2d6def933da194675fa043ad9594d37ba6def612a9001ef510a3d28d0612d0bd7d82d4eabc2b1d5bbded472ac41257c7d66609457569c001be7e
EBUILD wicd-1.7.9999_p874.ebuild 4736 SHA256 c84241f13c3ce8fb98448677cbf0ddce3de511106cadf3cc8769e86035fafd0b SHA512 88ba1c0b311052c6bfde881485cb9dd303fc6910a19f3eb8b66e3afea45f5a005bf6a237aed6326582c0ecea752fd3d72d4b875930e48cbc4aa3523dc30d6222 WHIRLPOOL c0e912e44923b0b3df4e6c5a8e1a74f79555dc4ba37e86a9f5cf879e0db064375e56c19230fcd53686d3c8482e454b44c3e1a48e6a9f29145f8f63d81cbbe842
MISC metadata.xml 1056 SHA256 b9546ab2e288f91607dd21595d9edd72c0f0d3c31675fb1e3957136493ade1be SHA512 abbe0fb3e339667a92a34251bbf63a8b4f0213cb99556bff91b3f7fa418fb9a2f49cbbe85d5dacd76effdd7655dc294b509c8fc0bbc6f53faf9d9797fd432472 WHIRLPOOL 1dcba5a56968e89fb302ea4d6f2298d3e1faf703a18bca347ed96d98c2bedef2b8116d30303d956f9d0a8c2c005687f02dad543f9bebca7cca1b19eac60dddcb

View file

@ -0,0 +1,11 @@
diff -U 3 -dHrN wicd-1.7.1.orig/in/init=gentoo=wicd.in wicd-1.7.1/in/init=gentoo=wicd.in
--- wicd-1.7.1.orig/in/init=gentoo=wicd.in 2012-02-27 21:49:36.422873826 +0100
+++ wicd-1.7.1/in/init=gentoo=wicd.in 2012-02-27 21:50:26.957127714 +0100
@@ -10,6 +10,7 @@
depend() {
need dbus
after hald
+ provide net
}
start() {

View file

@ -0,0 +1,11 @@
--- in/init=gentoo=wicd.in 2010-10-29 11:36:55.000000000 -0400
+++ in/init=gentoo=wicd.in.new 2011-03-28 09:40:27.245339002 -0400
@@ -15,7 +15,7 @@
start() {
ebegin "Starting wicd daemon"
# fix Gentoo bug 296197
- sed -i 's/^\[\]$//' /etc/wicd/wired-settings.conf
+ [ -f /etc/wicd/wired-settings.conf ] && sed -i 's/^\[\]$//' /etc/wicd/wired-settings.conf
"${WICD_DAEMON}" >/dev/null 2>&1
eend $?
}

View file

@ -0,0 +1,30 @@
diff -U 3 -dHrN wicd.org/encryption/templates/active wicd/encryption/templates/active
--- wicd.org/encryption/templates/active 2011-12-05 16:22:49.584224158 +0100
+++ wicd/encryption/templates/active 2011-12-05 16:16:10.736172566 +0100
@@ -1,6 +1,7 @@
wpa
wpa-peap
wpa-psk
+wpa-psk-hex
wpa2-leap
wpa2-peap
wep-hex
diff -U 3 -dHrN wicd.org/encryption/templates/wpa-psk-hex wicd/encryption/templates/wpa-psk-hex
--- wicd.org/encryption/templates/wpa-psk-hex 1970-01-01 01:00:00.000000000 +0100
+++ wicd/encryption/templates/wpa-psk-hex 2011-12-05 16:16:43.428012863 +0100
@@ -0,0 +1,15 @@
+name = WPA 1/2 (Preshared Hex Key)
+author = Thomas Kahle
+version = 1
+require apsk *Preshared_Key
+-----
+ctrl_interface=/var/run/wpa_supplicant
+network={
+ ssid="$_ESSID"
+ scan_ssid=$_SCAN
+ proto=WPA RSN
+ key_mgmt=WPA-PSK
+ pairwise=CCMP TKIP
+ group=CCMP TKIP
+ psk=$_APSK
+}

View file

@ -0,0 +1,16 @@
=== modified file 'wicd/misc.py'
--- wicd/misc.py 2012-04-30 19:20:47 +0000
+++ wicd/misc.py 2012-05-03 16:01:49 +0000
@@ -430,7 +430,10 @@
""" Sanitize property names to be used in config-files. """
allowed = string.ascii_letters + '_' + string.digits
table = string.maketrans(allowed, ' ' * len(allowed))
- return s.translate(None, table)
+
+ # s is a dbus.String -- since we don't allow unicode property keys,
+ # make it simple.
+ return str(s).translate(None, table)
def sanitize_escaped(s):
""" Sanitize double-escaped unicode strings. """

View file

@ -0,0 +1,43 @@
=== modified file 'curses/curses_misc.py'
--- curses/curses_misc.py 2012-11-15 09:26:21 +0000
+++ curses/curses_misc.py 2012-11-16 09:22:47 +0000
@@ -352,7 +352,7 @@
if urwid.VERSION < (1, 1, 0):
self.focus = focus
else:
- self.focus_position = focus
+ self._w.focus_position = focus
self.callback = callback
self.user_args = user_args
@@ -368,7 +368,10 @@
if urwid.VERSION < (1, 1, 0):
self.focus = index
else:
- self.focus_position = index
+ try:
+ self._w.focus_position = index
+ except IndexError:
+ pass
# API changed between urwid 0.9.8.4 and 0.9.9
try:
@@ -386,7 +389,7 @@
if urwid.VERSION < (1, 1, 0):
index = self.focus
else:
- index = self.focus_position
+ index = self._w.focus_position
self.cbox = DynWrap(SelText([self.list[index]+self.DOWN_ARROW]),
attrs=self.attrs,focus_attr=self.focus_attr)
@@ -434,7 +437,7 @@
if urwid.VERSION < (1, 1, 0):
return None, self.focus
else:
- return None, self.focus_position
+ return None, self._w.focus_position
def get_sensitive(self):
return self.cbox.get_sensitive()

View file

@ -0,0 +1,66 @@
=== modified file 'curses/curses_misc.py'
--- curses/curses_misc.py 2012-05-06 15:16:15 +0000
+++ curses/curses_misc.py 2012-11-15 09:26:21 +0000
@@ -349,7 +349,10 @@
# We need this to pick our keypresses
self.use_enter = use_enter
- self.focus = focus
+ if urwid.VERSION < (1, 1, 0):
+ self.focus = focus
+ else:
+ self.focus_position = focus
self.callback = callback
self.user_args = user_args
@@ -362,7 +365,11 @@
self.list = list
def set_focus(self,index):
- self.focus = index
+ if urwid.VERSION < (1, 1, 0):
+ self.focus = index
+ else:
+ self.focus_position = index
+
# API changed between urwid 0.9.8.4 and 0.9.9
try:
self.cbox.set_w(SelText(self.list[index]+self.DOWN_ARROW))
@@ -376,16 +383,21 @@
def build_combobox(self,parent,ui,row):
str,trash = self.label.get_text()
- self.cbox = DynWrap(SelText([self.list[self.focus]+self.DOWN_ARROW]),
+ if urwid.VERSION < (1, 1, 0):
+ index = self.focus
+ else:
+ index = self.focus_position
+
+ self.cbox = DynWrap(SelText([self.list[index]+self.DOWN_ARROW]),
attrs=self.attrs,focus_attr=self.focus_attr)
if str != '':
w = urwid.Columns([('fixed',len(str),self.label),self.cbox],
dividechars=1)
- self.overlay = self.ComboSpace(self.list,parent,ui,self.focus,
+ self.overlay = self.ComboSpace(self.list,parent,ui,index,
pos=(len(str)+1,row))
else:
w = urwid.Columns([self.cbox])
- self.overlay = self.ComboSpace(self.list,parent,ui,self.focus,
+ self.overlay = self.ComboSpace(self.list,parent,ui,index,
pos=(0,row))
self._w = w
@@ -419,7 +431,10 @@
if self.overlay:
return self.overlay._listbox.get_focus()
else:
- return None,self.focus
+ if urwid.VERSION < (1, 1, 0):
+ return None, self.focus
+ else:
+ return None, self.focus_position
def get_sensitive(self):
return self.cbox.get_sensitive()

View file

@ -0,0 +1,145 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
EAPI=5
PYTHON_DEPEND="2"
PYTHON_USE_WITH="ncurses? xml"
SUPPORT_PYTHON_ABIS="1"
RESTRICT_PYTHON_ABIS="3.* *-jython"
DISTUTILS_USE_SEPARATE_SOURCE_DIRECTORIES="1"
inherit eutils distutils systemd
DESCRIPTION="A lightweight wired and wireless network manager for Linux"
HOMEPAGE="https://launchpad.net/wicd"
SRC_URI="http://launchpad.net/wicd/1.7/${PV}/+download/${P}.tar.gz
mac4lin? ( http://dev.gentoo.org/~anarchy/dist/wicd-mac4lin-icons.tar.xz )
ambiance? ( http://freetimesblog.altervista.org/blog/wp-content/uploads/downloads/2010/05/Icone-Wicd-Lucid.tar.gz )"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="amd64 ~arm ~mips ppc ppc64 x86"
IUSE="X ambiance +gtk +gtk-autostart ioctl libnotify mac4lin ncurses nls +pm-utils"
DEPEND="nls? ( dev-python/Babel )"
# Maybe virtual/dhcp would work, but there are enough problems with
# net-misc/dhcp that I want net-misc/dhcpcd to be guarenteed to be considered
# first if none are installed.
RDEPEND="
dev-python/dbus-python
X? ( gtk? ( dev-python/pygtk
|| (
x11-misc/ktsuss
x11-libs/gksu
kde-base/kdesu
)
)
)
|| (
net-misc/dhcpcd
net-misc/dhcp
net-misc/pump
)
net-wireless/wireless-tools
net-wireless/wpa_supplicant
|| (
sys-apps/net-tools
sys-apps/ethtool
)
!gtk? ( dev-python/pygobject:2 )
ioctl? ( dev-python/python-iwscan dev-python/python-wpactrl )
libnotify? ( dev-python/notify-python )
ncurses? (
dev-python/urwid
dev-python/pygobject:2
)
pm-utils? ( >=sys-power/pm-utils-1.1.1 )
"
DOCS="CHANGES NEWS AUTHORS README"
src_prepare() {
# Fix bug 441966 (urwid-1.1.0 compatibility)
epatch "${FILESDIR}"/${P}-urwid.patch
epatch "${FILESDIR}"/${P}-second-urwid.patch
epatch "${FILESDIR}"/${PN}-1.7.1_beta2-init.patch
# pushed upstream as rev 876
epatch "${FILESDIR}"/${PN}-init-sve-start.patch
# Add a template for hex psk's and wpa (Bug 306423)
epatch "${FILESDIR}"/${PN}-1.7.1_pre20111210-wpa-psk-hex-template.patch
# Fix bug 416579 (should be included in next release)
epatch "${FILESDIR}"/${P}-fix-dbus-error.patch
# disable starting with startx
use gtk-autostart ||
epatch "${FILESDIR}/${PN}-disable-autostart.patch"
# get rid of opts variable to fix bug 381885 (rev 876)
sed -i "/opts/d" "in/init=gentoo=wicd.in" || die
# Make init script provide net per bug 405775
epatch "${FILESDIR}"/${PN}-1.7.1-provide-net.patch
# delay connect to daemon (rev 877 and 878)
epatch "${FILESDIR}/${PN}-1.7.9999_p874-delay-daemon-connect.patch"
# Need to ensure that generated scripts use Python 2 at run time.
sed -e "s:self.python = '/usr/bin/python':self.python = '/usr/bin/python2':" \
-i setup.py || die "sed failed"
if use nls; then
# Asturian is faulty with PyBabel
# (https://bugs.launchpad.net/wicd/+bug/928589)
rm po/ast.po
else
# nuke translations
rm po/*.po
fi
python_copy_sources
}
src_configure() {
local myconf
use gtk || myconf="${myconf} --no-install-gtk"
use libnotify || myconf="${myconf} --no-use-notifications"
use ncurses || myconf="${myconf} --no-install-ncurses"
use pm-utils || myconf="${myconf} --no-install-pmutils"
configuration() {
$(PYTHON) ./setup.py configure --no-install-docs --resume=/usr/share/wicd/scripts/ --suspend=/usr/share/wicd/scripts/ --verbose ${myconf}
}
python_execute_function -s configuration
}
src_install() {
distutils_src_install
keepdir /var/lib/wicd/configurations \
|| die "keepdir failed, critical for this app"
keepdir /etc/wicd/scripts/{postconnect,disconnect,preconnect} \
|| die "keepdir failed, critical for this app"
keepdir /var/log/wicd \
|| die "keepdir failed, critical for this app"
use nls || rm -rf "${D}"/usr/share/locale
systemd_dounit "${S}/other/wicd.service"
if use mac4lin; then
rm -rf "${D}"/usr/share/pixmaps/wicd || die "Failed to remove old icons"
mv "${WORKDIR}"/wicd "${D}"/usr/share/pixmaps/
fi
if use ambiance; then
# Overwrite tray icons with ambiance icon
rm "${WORKDIR}/Icone Wicd Lucid"/signal*
cp "${WORKDIR}/Icone Wicd Lucid"/*.png "${D}"/usr/share/pixmaps/wicd/
fi
}
pkg_postinst() {
distutils_pkg_postinst
elog "You may need to restart the dbus service after upgrading wicd."
echo
elog "To start wicd at boot, add /etc/init.d/wicd to a runlevel and:"
elog "- Remove all net.* initscripts (except for net.lo) from all runlevels"
elog "- Add these scripts to the RC_PLUG_SERVICES line in /etc/rc.conf"
elog "(For example, rc_hotplug=\"!net.eth* !net.wlan*\")"
# Maintainer's note: the consolekit use flag short circuits a dbus rule and
# allows the connection. Else, you need to be in the group.
if ! has_version sys-auth/consolekit; then
ewarn "Wicd-1.6 and newer requires your user to be in the 'users' group. If"
ewarn "you are not in that group, then modify /etc/dbus-1/system.d/wicd.conf"
fi
}