public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: app-admin/quickswitch/, app-admin/quickswitch/files/
@ 2017-12-29 17:02 David Seifert
  0 siblings, 0 replies; only message in thread
From: David Seifert @ 2017-12-29 17:02 UTC (permalink / raw
  To: gentoo-commits

commit:     15ad544f0f0f52c4f83074b6c1930f71c7aa0711
Author:     David Seifert <soap <AT> gentoo <DOT> org>
AuthorDate: Fri Dec 29 16:34:29 2017 +0000
Commit:     David Seifert <soap <AT> gentoo <DOT> org>
CommitDate: Fri Dec 29 17:02:13 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=15ad544f

app-admin/quickswitch: Port to EAPI 6

Package-Manager: Portage-2.3.19, Repoman-2.3.6

 .../files/quickswitch-1.05-fix-paths.patch         | 62 ++++++++++++++++++++++
 app-admin/quickswitch/quickswitch-1.05.ebuild      | 28 ++++------
 2 files changed, 71 insertions(+), 19 deletions(-)

diff --git a/app-admin/quickswitch/files/quickswitch-1.05-fix-paths.patch b/app-admin/quickswitch/files/quickswitch-1.05-fix-paths.patch
new file mode 100644
index 00000000000..707a355c09f
--- /dev/null
+++ b/app-admin/quickswitch/files/quickswitch-1.05-fix-paths.patch
@@ -0,0 +1,62 @@
+--- a/switcher
++++ b/switcher
+@@ -67,7 +67,7 @@
+ 
+ ### load quickswitch package
+ $_SWITCHTO = '/usr/bin/switchto'; # default location
+-$CONF_FILE = '/etc/switchto.conf';
++$CONF_FILE = '/etc/quickswitch/switchto.conf';
+ $SWITCHTO = find_switchto($CONF_FILE);
+ $ENV{RUNNING_FROM_SWITCHER} = 1;
+ require $SWITCHTO;
+--- a/switchto
++++ b/switchto
+@@ -26,7 +26,7 @@
+ #
+ # Send bug-reports, comments, women to bugs@muthanna.com
+ #
+-# Also see /etc/switchto.conf for further docs.
++# Also see /etc/quickswitch/switchto.conf for further docs.
+ #
+ # Release: 0.16
+ #
+@@ -143,8 +143,8 @@
+ $AUTHOR    = "Mohit Muthanna, Paul Seamons";
+ $DATE      = '2002';
+ 
+-### I would suggest renaming this /etc/switchto.conf
+-$CONF_FILE = "/etc/switchto.conf";
++### I would suggest renaming this /etc/quickswitch/switchto.conf
++$CONF_FILE = "/etc/quickswitch/switchto.conf";
+ %DEFAULTS  = (
+               autoconfig      => 0,
+               device          => "eth0",
+@@ -165,7 +165,7 @@
+               nfsexportall    => "/usr/sbin/exportfs -a",
+               nfsexportsfile  => "/etc/exports",
+               niscommand      => "/bin/nisdomainname",
+-              servicefilename => "/etc/switchto.last",
++              servicefilename => "/etc/quickswitch/switchto.last",
+               execpre         => undef,
+               execpost        => undef,
+ 
+--- a/switchto.conf
++++ b/switchto.conf
+@@ -43,7 +43,7 @@
+ device=eth0
+ 
+ # Path to save last good known configuration...
+-servicefilename=/etc/switchto.last
++servicefilename=/etc/quickswitch/switchto.last
+ 
+ # Path and arguments to switchto. This is for the switcher GUI
+ # switchtopath=/usr/bin/switchto -b
+@@ -52,7 +52,7 @@
+ # Uncomment theses and change them if needed.
+ # ------------------------------------------
+ # ifconfig=/sbin/ifconfig
+-# iwconfig=/usr/local/sbin/iwconfig
++# iwconfig=/sbin/iwconfig
+ # netstat=/bin/netstat
+ # route=/sbin/route
+ # hostnamecmd=/bin/hostname

diff --git a/app-admin/quickswitch/quickswitch-1.05.ebuild b/app-admin/quickswitch/quickswitch-1.05.ebuild
index ab9f3d539eb..24b21cea6b2 100644
--- a/app-admin/quickswitch/quickswitch-1.05.ebuild
+++ b/app-admin/quickswitch/quickswitch-1.05.ebuild
@@ -1,38 +1,28 @@
-# Copyright 1999-2010 Gentoo Foundation
+# Copyright 1999-2017 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
-IUSE="ncurses"
+EAPI=6
 
 DESCRIPTION="Utility to switch network profiles on the fly"
 SRC_URI="mirror://sourceforge/quickswitch/${P}.tar.gz"
 HOMEPAGE="http://quickswitch.sf.net"
 
-SLOT="0"
 LICENSE="GPL-2"
+SLOT="0"
 KEYWORDS="x86 ppc sparc s390 amd64"
+IUSE="ncurses"
 
 DEPEND=">=dev-lang/perl-5.6.0"
 RDEPEND="ncurses? ( dev-perl/CursesWidgets )"
 
+PATCHES=( "${FILESDIR}"/${PN}-1.05-fix-paths.patch )
+
 src_install() {
 	dobin switchto
-	dosed "s:/etc/switchto.conf:/etc/quickswitch/switchto.conf:" \
-		/usr/bin/switchto
-	dosed "s:/etc/switchto.last:/etc/quickswitch/switchto.last:" \
-		/usr/bin/switchto
-	if use ncurses; then
-		dobin switcher
-		dosed "s:/etc/switchto.conf:/etc/quickswitch/switchto.conf:" \
-			/usr/bin/switcher
-	fi
-
-	dodir /etc/quickswitch
+	use ncurses && dobin switcher
+
 	insinto /etc/quickswitch
 	newins switchto.conf switchto.conf.sample
 
-	dosed "s:/etc/switchto.last:/etc/quickswitch/switchto.last:" \
-		/etc/quickswitch/switchto.conf.sample
-	dosed "s:/usr/local/sbin/iwconfig:/sbin/iwconfig:" \
-		/etc/quickswitch/switchto.conf.sample
-	dodoc README
+	einstalldocs
 }


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2017-12-29 17:02 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-12-29 17:02 [gentoo-commits] repo/gentoo:master commit in: app-admin/quickswitch/, app-admin/quickswitch/files/ David Seifert

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox