diff options
author | Michael Sterrett <mr_bones_@gentoo.org> | 2004-08-20 07:50:29 +0000 |
---|---|---|
committer | Michael Sterrett <mr_bones_@gentoo.org> | 2004-08-20 07:50:29 +0000 |
commit | 64e2108b45599aa89edbc338c2c18ae4c60d3efb (patch) | |
tree | dc806b9bc56434e59dd91c13140f32dff0dc435e /games-mud | |
parent | digest fix (diff) | |
download | gentoo-2-64e2108b45599aa89edbc338c2c18ae4c60d3efb.tar.gz gentoo-2-64e2108b45599aa89edbc338c2c18ae4c60d3efb.tar.bz2 gentoo-2-64e2108b45599aa89edbc338c2c18ae4c60d3efb.zip |
Add patch from Robert Gill via bug #58489 to enable mcl to be able to be used from the virtual console.
Diffstat (limited to 'games-mud')
-rw-r--r-- | games-mud/mcl/ChangeLog | 7 | ||||
-rw-r--r-- | games-mud/mcl/files/0.53.00-vc.patch | 39 | ||||
-rw-r--r-- | games-mud/mcl/mcl-0.53.00.ebuild | 28 |
3 files changed, 61 insertions, 13 deletions
diff --git a/games-mud/mcl/ChangeLog b/games-mud/mcl/ChangeLog index 7d354026d237..6645e3da16e6 100644 --- a/games-mud/mcl/ChangeLog +++ b/games-mud/mcl/ChangeLog @@ -1,6 +1,11 @@ # ChangeLog for games-mud/mcl # Copyright 2002-2004 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/games-mud/mcl/ChangeLog,v 1.7 2004/06/24 23:00:41 agriffis Exp $ +# $Header: /var/cvsroot/gentoo-x86/games-mud/mcl/ChangeLog,v 1.8 2004/08/20 07:50:29 mr_bones_ Exp $ + + 20 Aug 2004; Michael Sterrett <mr_bones_@gentoo.org> + +files/0.53.00-vc.patch, mcl-0.53.00.ebuild: + Add patch from Robert Gill via bug #58489 to enable mcl to be able to be + used from the virtual console. 19 Apr 2004; Chris Gianelloni <wolf31o2@gentoo.org> mcl-0.53.00.ebuild: Marking stable on amd64 (no bugs in 202 days). diff --git a/games-mud/mcl/files/0.53.00-vc.patch b/games-mud/mcl/files/0.53.00-vc.patch new file mode 100644 index 000000000000..fc77a4b9b348 --- /dev/null +++ b/games-mud/mcl/files/0.53.00-vc.patch @@ -0,0 +1,39 @@ +diff -u mcl-0.53.00/Screen.cc mcl-patched/Screen.cc +--- mcl-0.53.00/Screen.cc 2003-09-29 04:51:44.000000000 -0700 ++++ mcl-patched/Screen.cc 2004-07-26 19:22:11.620619536 -0700 +@@ -49,7 +49,8 @@ + // 2.4 with devs (noted by moon@deathmoon.com + else if (1 == (sscanf(tty, "/dev/vc/%d", &ttyno))) + sprintf (buf, "/dev/vcc/a%d", ttyno); +- else { ++ ++ if ((fd = open (buf, O_WRONLY)) < 0) { + usingVirtual = false; + scr_x = scr_y = scr_w = scr_h = 0; + last_screen = new attrib[width * height]; +@@ -58,13 +59,6 @@ + out = new Buffer(32000); + } + +- if (usingVirtual) { +- if ((fd = open (buf, O_WRONLY)) < 0) { +- fprintf (stderr, "\nFailed to open %s: %m. \nPerhaps your permissions are wrong?\n\n", buf); +- exit (EXIT_FAILURE); +- } +- } +- + init_curses(usingVirtual); + } + +diff -u mcl-0.53.00/main.cc mcl-patched/main.cc +--- mcl-0.53.00/main.cc 2003-09-29 03:39:14.000000000 -0700 ++++ mcl-patched/main.cc 2004-07-26 18:18:01.000000000 -0700 +@@ -50,7 +50,7 @@ + // Do this right at the start, so that a) perl can startup correctly, + // and b) to avoid any unforseen holes in eg. configfile loading -N + screen = new Screen(); +- setegid(getgid()); ++ seteuid(getuid()); + + time (¤t_time); + srand(current_time); diff --git a/games-mud/mcl/mcl-0.53.00.ebuild b/games-mud/mcl/mcl-0.53.00.ebuild index 305c8141d908..f4d2444c055b 100644 --- a/games-mud/mcl/mcl-0.53.00.ebuild +++ b/games-mud/mcl/mcl-0.53.00.ebuild @@ -1,16 +1,16 @@ # Copyright 1999-2004 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/games-mud/mcl/mcl-0.53.00.ebuild,v 1.7 2004/06/24 23:00:41 agriffis Exp $ +# $Header: /var/cvsroot/gentoo-x86/games-mud/mcl/mcl-0.53.00.ebuild,v 1.8 2004/08/20 07:50:29 mr_bones_ Exp $ inherit eutils gnuconfig games DESCRIPTION="A console MUD client scriptable in Perl and Python" -SRC_URI="http://www.andreasen.org/mcl/dist/${P}-src.tar.gz" HOMEPAGE="http://www.andreasen.org/mcl/" +SRC_URI="http://www.andreasen.org/mcl/dist/${P}-src.tar.gz" LICENSE="GPL-2" -KEYWORDS="x86 amd64" SLOT="0" +KEYWORDS="x86 amd64" IUSE="python perl" RDEPEND="perl? ( dev-lang/perl ) @@ -20,27 +20,31 @@ DEPEND="${RDEPEND} src_unpack() { unpack ${A} - cd ${S} + cd "${S}" - epatch ${FILESDIR}/${P}-fPIC.patch + epatch "${FILESDIR}/${P}-fPIC.patch" + epatch "${FILESDIR}/${PV}-vc.patch" sed -i \ -e "/MCL_LIBRARY_PATH/ s:/usr/lib/mcl:${GAMES_LIBDIR}/${PN}:" \ - h/mcl.h || die "sed h/mcl.h failed" + h/mcl.h \ + || die "sed h/mcl.h failed" + gnuconfig_update } src_compile() { - gnuconfig_update || die - - egamesconf `use_enable perl` `use_enable python` || die + egamesconf \ + $(use_enable perl) \ + $(use_enable python) \ + || die emake || die "emake failed" } src_install () { - make INSTALL_ROOT=${D} install || die "make install failed" + make INSTALL_ROOT="${D}" install || die "make install failed" dodoc \ - doc/{Changes,Chat,Embedded,Examples,Modules,Plugins,README,TODO} || \ - die "dodoc failed" + doc/{Changes,Chat,Embedded,Examples,Modules,Plugins,README,TODO} \ + || die "dodoc failed" dohtml doc/*html || die "dohtml failed" prepgamesdirs } |