diff options
author | Mike Kazantsev (MK_FG) <mk.fraggod@gmail.com> | 2008-09-01 14:15:03 +0000 |
---|---|---|
committer | Mike Kazantsev (MK_FG) <mk.fraggod@gmail.com> | 2008-09-01 14:15:03 +0000 |
commit | 6a87453c790d5755e7c850c73dceb2306b9c064e (patch) | |
tree | 791cde061c0969bcb4ffc1c5f8077075cbdb71f6 /x11-misc | |
parent | app-i18n/ibus: Bump to snapshot 20080901 (diff) | |
download | sunrise-6a87453c790d5755e7c850c73dceb2306b9c064e.tar.gz sunrise-6a87453c790d5755e7c850c73dceb2306b9c064e.tar.bz2 sunrise-6a87453c790d5755e7c850c73dceb2306b9c064e.zip |
x11-misc/GeoXPlanet: New Ebuild for bug 236353 (GeoXPlanet)
svn path=/sunrise/; revision=6932
Diffstat (limited to 'x11-misc')
-rw-r--r-- | x11-misc/GeoXPlanet/ChangeLog | 9 | ||||
-rw-r--r-- | x11-misc/GeoXPlanet/GeoXPlanet-0.4.5-r2.ebuild | 56 | ||||
-rw-r--r-- | x11-misc/GeoXPlanet/Manifest | 7 | ||||
-rw-r--r-- | x11-misc/GeoXPlanet/files/GeoXPlanet-0.4.5-r2.patch | 114 | ||||
-rwxr-xr-x | x11-misc/GeoXPlanet/files/geoxplanet | 33 | ||||
-rw-r--r-- | x11-misc/GeoXPlanet/metadata.xml | 5 |
6 files changed, 224 insertions, 0 deletions
diff --git a/x11-misc/GeoXPlanet/ChangeLog b/x11-misc/GeoXPlanet/ChangeLog new file mode 100644 index 000000000..67ba25863 --- /dev/null +++ b/x11-misc/GeoXPlanet/ChangeLog @@ -0,0 +1,9 @@ +# ChangeLog for x11-misc/GeoXPlanet +# Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2 +# $Header: $ + + 01 Sep 2008; Mike Kazantsev (MK_FG) <mk.fraggod@gmail.com> + +GeoXPlanet-0.4.5-r2.ebuild, +files/GeoXPlanet-0.4.5-r2.patch, + +files/geoxplanet, +metadata.xml: + New Ebuild for bug 236353 (GeoXPlanet) + diff --git a/x11-misc/GeoXPlanet/GeoXPlanet-0.4.5-r2.ebuild b/x11-misc/GeoXPlanet/GeoXPlanet-0.4.5-r2.ebuild new file mode 100644 index 000000000..d670ac440 --- /dev/null +++ b/x11-misc/GeoXPlanet/GeoXPlanet-0.4.5-r2.ebuild @@ -0,0 +1,56 @@ +# Copyright 1999-2008 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +inherit eutils + +DESCRIPTION="Wrapper script to draw traceroutes of current network connections on xplanet images" +HOMEPAGE="http://geoxplanet.sourceforge.net" +SRC_URI="mirror://sourceforge/${PN}/${PF}.zip mirror://sourceforge/${PN}/geoip.db.zip" + +LICENSE="GPL-1 MAXMIND" +SLOT="0" +KEYWORDS="~x86" +IUSE="xinerama" + +RDEPEND="x11-misc/xplanet + dev-python/pygtk + xinerama? ( media-gfx/imagemagick ) + || ( + ( >=dev-python/pysqlite-2.0.3 <dev-lang/python-2.5 ) + >=dev-lang/python-2.5 + )" +DEPEND="${RDEPEND} app-arch/unzip" + +src_unpack() { + if has_version ">=dev-lang/python-2.5" && ! built_with_use dev-lang/python sqlite ; then + ewarn "Python 2.5 or higher (>=dev-lang/python-2.5) must be compiled with the sqlite support." + einfo "Please emerge python with sqlite USE flag and then emerge GeoXPlanet." + die "Python doesn't have sqlite support" + fi + + unpack ${A} + cd "${S}" + + # Originally GeoXPlanet moves temp files (images, config files, etc...) into user's home at first launch + # This patch changes move operation to copy + epatch "${FILESDIR}/${PF}.patch" +} + +src_install() { + dobin "${FILESDIR}/geoxplanet" + + cd "${WORKDIR}" + insinto /usr/share/geoxplanet/ + mv README README.geoip + dodoc README.geoip + doins geoip.db || die + cd "${S}" + doins -r arcFiles defaults src temp templates || die + insinto /usr/share/geoxplanet/src + insopts -m755 + doins src/GeoXPlanet.py src/configGUI.py || die + dodoc CHANGELOG CONFIG_OPTIONS README + + ewarn "GeoXPlanet will show configuration dialog only at first launch, but you can type 'geoxplanet -C' to use it later." +} diff --git a/x11-misc/GeoXPlanet/Manifest b/x11-misc/GeoXPlanet/Manifest new file mode 100644 index 000000000..63431dafa --- /dev/null +++ b/x11-misc/GeoXPlanet/Manifest @@ -0,0 +1,7 @@ +AUX GeoXPlanet-0.4.5-r2.patch 6789 RMD160 a46a899bc01c0470e20e9395bf40727f027bda23 SHA1 9ecdb675a82bfcedb17cb73d3ba52fd639948444 SHA256 2cce16706ecf02f7e1188e89468ef2aa3995bfed38bbc7b5f34a81817d804918 +AUX geoxplanet 701 RMD160 be270c12eae336102ad642e4c9fdbfbcf9cc21d0 SHA1 1d2d743d497c40e7845ca0774983fd40c839fc10 SHA256 243693bc2bd7ba1edf4b3728b9ad40dd53608637752e7b89c598dae79f0f650e +DIST GeoXPlanet-0.4.5-r2.zip 1346651 RMD160 59822c13f5f4a0f7e911c5afa0cb8217e8109354 SHA1 fe953f495407fd07d9a046ae6dc2e59abadd0628 SHA256 80696f38092b466a314d78a624e85adf15fcee1b41069ea7e773a9aeeefdcf7b +DIST geoip.db.zip 63522451 RMD160 38f865d5f25f5519bf3a66c01f8d7ab5f858f593 SHA1 c961fc6074842e399190ede3881d16097638e5ee SHA256 7bb358f8dd2a203fd779bebf517fb0aa63270594438d1b81fd9f001581c8566e +EBUILD GeoXPlanet-0.4.5-r2.ebuild 1680 RMD160 62ac6de5a8ce50d53246da2f86c7c3678c2fbf2d SHA1 20937b8849e81373acf62f89cf6cc86a146b96a8 SHA256 6f0ab77f750527e1499d41cb60afc6f5d18398dfbe7a8b2ebdc00c0af478625d +MISC ChangeLog 324 RMD160 05a9f43b3ec382b820377f8112201bcd33daaa5f SHA1 247f9f70445132230f5a82bacf0ee793cf0e8a5a SHA256 46633c7c36e162908a5d22325e2791dd38538634ba03a1fd238ba0a0115c1c39 +MISC metadata.xml 170 RMD160 645927a396fdc21cdeb089fe42c5397332420ea6 SHA1 ac7f48a14fec325926f9ce1be8fbf1f311b4f2e4 SHA256 d797a2ec6f9dc516c9f9c1a758ee87ad3e8c43101b5dc76c2f872d5bd4639b42 diff --git a/x11-misc/GeoXPlanet/files/GeoXPlanet-0.4.5-r2.patch b/x11-misc/GeoXPlanet/files/GeoXPlanet-0.4.5-r2.patch new file mode 100644 index 000000000..16ed61045 --- /dev/null +++ b/x11-misc/GeoXPlanet/files/GeoXPlanet-0.4.5-r2.patch @@ -0,0 +1,114 @@ +diff -uw src_bak/GeoXPlanet.py src/GeoXPlanet.py +--- src_bak/GeoXPlanet.py 2008-04-13 03:32:27.000000000 +0600 ++++ src/GeoXPlanet.py 2008-08-30 17:58:13.722833279 +0600 +@@ -91,9 +91,9 @@ + raise Exception # the current config file isn't compatible with this version of GeoXPlanet...let's kick off the configGUI + except Exception, inst: + if not os.path.exists(os.path.join(os.environ["HOME"], ".geoxplanet")) or not os.path.isdir(os.path.join(os.environ["HOME"], ".geoxplanet")): +- print "Moving temp files (images, config files, etc...) from " ++ print "Copying temp files (images, config files, etc...) from " + print "the GeoXPlanet directory to %s" % os.path.join(os.environ["HOME"],".geoxplanet") +- shutil.move(os.path.join(sys.path[0][:-4],"temp"), os.path.join(os.environ["HOME"],".geoxplanet")) ++ shutil.copytree(os.path.join(sys.path[0][:-4],"temp"), os.path.join(os.environ["HOME"],".geoxplanet")) + from configGUI import configGUI + config = configGUI() + config.show() +@@ -102,4 +102,3 @@ + if __name__ == '__main__': + program = GeoXPlanet(configFile) + program.run(GUI) +- +\ No newline at end of file +diff -uw src_bak/clouds.py src/clouds.py +--- src_bak/clouds.py 2008-04-13 06:21:54.000000000 +0600 ++++ src/clouds.py 2008-08-30 19:09:52.375831564 +0600 +@@ -32,18 +32,11 @@ + maxRetries = 3 + imageDir = "%s%s" % (os.path.join(os.environ["HOME"],".geoxplanet","images"), os.sep) + defaultOutputFile = "clouds_2048.jpg" +- mirrors = [ "http://www.ruwenzori.net/earth/clouds_2048.jpg", +- "http://xplanet.arculeo.com/clouds_2048.jpg", +- "http://xplanet.dyndns.org/clouds/clouds_2048.jpg", +- "http://userpage.fu-berlin.de/~jml/clouds_2048.jpg", +- "http://rcswww.urz.tu-dresden.de/~es179238/clouds_2048.jpg", ++ mirrors = [ "http://xplanet.dyndns.org/clouds/clouds_2048.jpg", + "http://home.megapass.co.kr/~ysy00/cloud_data/clouds_2048.jpg", + "http://home.megapass.co.kr/~holywatr/cloud_data/clouds_2048.jpg", +- "http://user.chol.com/~winxplanet/cloud_data/clouds_2048.jpg", + "http://home.megapass.co.kr/~gitto88/cloud_data/clouds_2048.jpg", +- "http://giga.colozone.nl/clouds_2048.jpg", + "http://www.wizabit.eclipse.co.uk/xplanet/files/mirror/clouds_2048.jpg", +- "http://www.wizabit.eclipse.co.uk/xplanet/files/local/clouds_2048.jpg", + "http://xplanet.explore-the-world.net/clouds_2048.jpg" ] + platform = sys.platform[:3] + +diff -uw src_bak/controller.py src/controller.py +--- src_bak/controller.py 2008-04-13 06:23:26.000000000 +0600 ++++ src/controller.py 2008-08-30 18:40:20.781831769 +0600 +@@ -184,6 +184,8 @@ + config.readfp(fname) + fname.close() + ++ self.tmpDir = os.path.join(os.environ["HOME"],".geoxplanet") ++ + self.xplanetExe = config.get("General", "xplanetExe") + print "Location of xplanet executable: %s" % self.xplanetExe + +@@ -313,7 +315,7 @@ + self.displayDict["Monitor_%i_stateColor" % index] = config.get("Display", "Monitor_%i_stateColor" % index) + self.displayDict["Monitor_%i_latitude" % index] = config.get("Display", "Monitor_%i_latitude" % index) + self.displayDict["Monitor_%i_longitude" % index] = config.get("Display", "Monitor_%i_longitude" % index) +- self.displayDict["Monitor_%i_xplanetConfig" % index] = "%s%sMonitor_%i_xplanet.conf" % (self.GeoXPlanetDir, os.sep, index) ++ self.displayDict["Monitor_%i_xplanetConfig" % index] = "%s%sMonitor_%i_xplanet.conf" % (self.tmpDir, os.sep, index) + conf = open(self.displayDict["Monitor_%i_xplanetConfig" % index], 'w') + self.displayDict["Monitor_%i_markerFile" % index] = "Monitor_%i_markerFile.txt" % index + self.displayDict["Monitor_%i_arcFile" % index] = "Monitor_%i_arcFile.txt" % index +@@ -685,7 +687,6 @@ + def runXPlanet(self): + # generate the image + self.suffix = (self.suffix + 1) % 2 +- tmpDir = os.path.join(os.environ["HOME"],".geoxplanet") + + if self.platform == 'win' or self.platform == 'Mic': + extension = 'bmp' +@@ -696,7 +697,7 @@ + imageFile = "%s%s.%s" % (os.path.join(os.environ["HOME"],".geoxplanet","images",("Monitor_%i_Output" % index)), self.suffix, extension) + print "Generating image file: %s" % imageFile + +- xplanetCommand = "%s -num_times 1 -searchdir %s -tmpdir %s -marker_file %s " % (self.xplanetExe, tmpDir, tmpDir, self.displayDict["Monitor_%i_markerFile" % index]) ++ xplanetCommand = "%s -num_times 1 -searchdir %s -tmpdir %s -marker_file %s " % (self.xplanetExe, self.tmpDir, self.tmpDir, self.displayDict["Monitor_%i_markerFile" % index]) + + if self.displayDict["Monitor_%i_projection" % index] != 'None': + xplanetCommand = xplanetCommand + "-projection %s " % self.displayDict["Monitor_%i_projection" % index] +@@ -722,13 +723,13 @@ + if self.platform != 'win' and self.platform != 'Mic': + if self.xinerama: + os.popen("convert %s%s.%s %s%s.%s +append %s%s.%s" % ( +- (os.path.join(tmpDir,"images","Monitor_0_Output")), self.suffix, extension, +- (os.path.join(tmpDir,"images","Monitor_1_Output")), self.suffix, extension, +- (os.path.join(tmpDir,"images","Output")), self.suffix, extension)) ++ (os.path.join(self.tmpDir,"images","Monitor_0_Output")), self.suffix, extension, ++ (os.path.join(self.tmpDir,"images","Monitor_1_Output")), self.suffix, extension, ++ (os.path.join(self.tmpDir,"images","Output")), self.suffix, extension)) + else: + os.popen("mv %s%s.%s %s%s.%s" % ( +- (os.path.join(tmpDir,"images","Monitor_0_Output")), self.suffix, extension, +- (os.path.join(tmpDir,"images","Output")), self.suffix, extension)) ++ (os.path.join(self.tmpDir,"images","Monitor_0_Output")), self.suffix, extension, ++ (os.path.join(self.tmpDir,"images","Output")), self.suffix, extension)) + command = "" + if self.displayDict["DESKTOP"] == 'gnome': + command = "gconftool-2 -t str -s /desktop/gnome/background/picture_filename" +@@ -742,10 +743,10 @@ + command = "echo -e \"# xfce backdrop list\n%s\">$HOME/.config/xfce4/desktop/backdrops.list && xfdesktop --reload" + + #print "%s %s%stemp%simages%s%s%s.png" % (command, self.GeoXPlanetDir, os.sep, os.sep,os.sep,("Monitor_%i_Output" % index), self.suffix) +- (stdin, stdout, stderr) = os.popen3("%s %s%s.%s" % (command, os.path.join(tmpDir,"images","Output"), self.suffix, extension)) ++ (stdin, stdout, stderr) = os.popen3("%s %s%s.%s" % (command, os.path.join(self.tmpDir,"images","Output"), self.suffix, extension)) + + else: # this is a windows system! +- bmp = ctypes.c_char_p( "%s%s.%s" % (os.path.join(tmpDir,"images","Monitor_0_Output"), self.suffix, extension)) ++ bmp = ctypes.c_char_p( "%s%s.%s" % (os.path.join(self.tmpDir,"images","Monitor_0_Output"), self.suffix, extension)) + ctypes.windll.user32.SystemParametersInfoA( 20, 0, bmp, 3 ) + + def run(self, GUI): diff --git a/x11-misc/GeoXPlanet/files/geoxplanet b/x11-misc/GeoXPlanet/files/geoxplanet new file mode 100755 index 000000000..1613b9c6e --- /dev/null +++ b/x11-misc/GeoXPlanet/files/geoxplanet @@ -0,0 +1,33 @@ +#!/bin/bash + +if [[ $@ =~ (-h)|(--help)|(\?) ]]; then + echo "Usage: ${0##*/} [-n] [-C]" + echo " or: ${0##*/} -k" + echo "Start/stop GeoXPlanet." + echo + echo " -n run in foreground (useful to see what's happening)" + echo " -k stop any running GeoXPlanet instances" + echo " -C launch configuration interface" + exit +fi + +if [[ $@ =~ -k ]]; then + if [[ `ps a | grep GeoXPlanet` ]]; then + kill `ps a | grep GeoXPlanet | sed 's|\([0-9]*\).*|\1|'` + exit + else + echo 'GeoXPlanet is not running' + exit + fi +fi + +if [[ $@ =~ -C ]] +then CMD="/usr/share/geoxplanet/src/configGUI.py" +else CMD="/usr/share/geoxplanet/src/GeoXPlanet.py" +fi + +if [[ ! $@ =~ -n ]] +then nohup $CMD > /dev/null 2>&1 & +else $CMD +fi + diff --git a/x11-misc/GeoXPlanet/metadata.xml b/x11-misc/GeoXPlanet/metadata.xml new file mode 100644 index 000000000..7e3286984 --- /dev/null +++ b/x11-misc/GeoXPlanet/metadata.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<herd>maintainer-wanted</herd> +</pkgmetadata> |