debian/0000755000000000000000000000000012154212624007165 5ustar debian/source/0000755000000000000000000000000012154212624010465 5ustar debian/source/format0000644000000000000000000000001412154212624011673 0ustar 3.0 (quilt) debian/README.Debian0000644000000000000000000000047712154212624011236 0ustar write-highscores ---------------- Normally, pathological comes with a small score writer program, that is installed setgid. Since there is some debate at this time (Aug 01 2003) on debian-devel as to how to properly handle packages like this, Pathological in Debian currently only writes scores to your home directory. debian/copyright0000644000000000000000000000267412154212624011131 0ustar Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: Pathological Source: http://pathological.sourceforge.net/ Files: * Copyright: 2003, John-Paul Gignac License: GPL-2+ Files: debian/* Copyright: 2003-2005, Joe Wreschnig 2007,2009 Alexander Schmehl 2009, Barry deFreese 2009, Cyril Brulebois, Eddy Petrișor, Gonéri Le Bouder Ansgar Burchardt 2012, Evgeniy Dolgikh 2013, Markus Koschany License: GPL-2+ License: GPL-2+ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. . This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. . You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. . On Debian GNU/Linux systems, the complete text of the GNU General Public License can be found in `/usr/share/common-licenses/GPL-2'. debian/pathological.menu0000644000000000000000000000036412154212624012524 0ustar ?package(pathological):needs="X11" \ section="Games/Puzzles" \ title="Pathological" \ longtitle="Pathological - puzzle game involving paths and marbles" \ command="/usr/games/pathological" \ icon="/usr/share/pixmaps/pathological.xpm" debian/changelog0000644000000000000000000001262712154212624011047 0ustar pathological (1.1.3-12) unstable; urgency=low * Convert .xm files to .ogg at build time. (Closes: #705415). + Add xmp and vorbis-tools build-deps. + Add patch to load .ogg files instead of .xm. -- Barry deFreese Wed, 05 Jun 2013 18:19:07 -0400 pathological (1.1.3-11) unstable; urgency=low * Team upload. [ Evgeniy Dolgikh ] * Remove GenericName field from desktop file. (Closes: #641824) * Switch to 3.0 (quilt) source format and drop quilt dependency. * Bump debhelper compat level to 9, require debhelper >= 9. * Add depends on ${misc:Depends}. * Switch to dh rules.tiny. * Add doc-base registration for html docs. [ Markus Koschany ] * Improve watch file and make the extension regex more flexible. * Bump standards version to 3.9.4, no changes needed. * debian/control: - Use canonical Vcs-URI. - Revert the decision to split the music files in a separate source package. Do not depend on pathological-music anymore and install the music from the pathological package again. Use Provides, Conflicts and Replaces relationship to ensure a smooth upgrade. - Drop Conflicts on pathological-scores. - Add python and python-pygame to Build-Depends-Indep. - Replace python with ${phython:Depends}. * pathological.desktop: Add Keywords and a comment in German. * pathological.menu: Add longtitle. * debian/patches: - Update 10_makefile.patch and install the music files again. - Add define-music_pending_song.patch which fixes an exception that was caused by an uninitialized game variable. (Closes: #705417) * Add DEP-3 headers to all patches. * Update debian/copyright to copyright format 1.0. * debian/rules: Use xz compression and build --with python2. -- Markus Koschany Thu, 02 May 2013 20:21:59 +0200 pathological (1.1.3-10) unstable; urgency=low [ Barry deFreese ] * 40_pygame_181.patch - Fix to run with pygame 1.8.1. (Closes: #523874). + Thanks to Andrea Mennucc for the fix. -- Barry deFreese Wed, 15 Apr 2009 10:51:13 -0400 pathological (1.1.3-9) unstable; urgency=low [ Gonéri Le Bouder ] * call dh_desktop to run update-desktop-database [ Eddy Petrișor ] * desktop file changes - removed invalid category "Application" - added missing semicolon at the end of the Categories field [ Cyril Brulebois ] * Added XS-Vcs-Svn and XS-Vcs-Browser fields in the control file. [ Barry deFreese ] * Add Homepage field * Bump debhelper build-dep to match compat * Remove deprecated Encoding from desktop file and make more HIG compliant * Add watch file * Make distclean not ignore errors * Make debhelper b-d, not b-d-i. (Used in clean target). * Add myself to uploaders. * Add quilt patching system. * Move old inline changes to quilt patches. + 10_makefile.patch. + 20_highscores.patch. * 30_no_soundcard.patch. Start with no soundcard. (Closes: #461330). + Thanks to Emanuele Rocca for the patch! * Bump Standards Version to 3.8.1. (No changes needed). [ Ansgar Burchardt ] * debian/control: Change XS-Vcs-* to Vcs-* * Remove Homepage semi-field from description [ Alexander Reichle-Schmehl ] * Adopt debian/control to my new name -- Barry deFreese Tue, 17 Mar 2009 11:18:43 -0400 pathological (1.1.3-8) unstable; urgency=low * placing new adress of FSF in debian/copyright -- Alexander Schmehl Fri, 12 Jan 2007 18:24:50 +0100 pathological (1.1.3-7) unstable; urgency=low * New Maintainer: Debian Games Team (Closes: #388358) * Adding Homepage header to package description -- Alexander Schmehl Fri, 12 Jan 2007 18:01:07 +0100 pathological (1.1.3-6) unstable; urgency=low * Fix mouse handling in menus. Sorry I took so long to do this. (Closes: #311432) -- Joe Wreschnig Tue, 21 Jun 2005 10:45:11 -0500 pathological (1.1.3-5) unstable; urgency=low * Patch main menu to allow initial level selection, up to the highest level you have beaten. (Closes: #257876) * Initialize display, mixer, font individually. (Closes: #269684) -- Joe Wreschnig Thu, 23 Sep 2004 21:39:12 -0500 pathological (1.1.3-4) unstable; urgency=low * Remove pathological-score-related cruft in debian/. * Add an fd.o .desktop entry. (Closes: #235860) * Add an encoding string to pathological.py. (Closes: #217116) * Quote the section and environment in the menu file. -- Joe Wreschnig Fri, 01 Aug 2003 14:46:15 -0500 pathological (1.1.3-3) unstable; urgency=low * On second thought, remove the setgid program altogether, and only write to the users' high score file, based on discussions about things I'm probably doing wrong on d-devel. -- Joe Wreschnig Fri, 01 Aug 2003 14:46:15 -0500 pathological (1.1.3-2) unstable; urgency=low * Fix the short description. (Closes: #203480) * Split off the music from the main package. (Closes: #203479) * Add correct Build-Depends-Indep. * Remove dh_python call (we don't use any of the compiled stuff.) -- Joe Wreschnig Wed, 30 Jul 2003 14:37:39 -0500 pathological (1.1.3-1) unstable; urgency=low * Initial Release. (Closes: #200178) * Patch the upstream Makefile to separate the build rules, and use install(1) instead of cp(1). -- Joe Wreschnig Sat, 19 Jul 2003 13:40:00 -0500 debian/pathological.docs0000644000000000000000000000001412154212624012500 0ustar README TODO debian/compat0000644000000000000000000000000212154212624010363 0ustar 9 debian/watch0000644000000000000000000000014612154212624010217 0ustar version=3 http://sf.net/pathological/pathological-(\d+.+)\.(?:zip|tgz|tbz|txz|(?:tar\.(?:gz|bz2|xz))) debian/pathological.install0000644000000000000000000000006312154212624013222 0ustar debian/pathological.desktop usr/share/applications debian/rules0000755000000000000000000000131612154212624010246 0ustar #!/usr/bin/make -f #export DH_VERBOSE=1 %: dh $@ --with python2 override_dh_auto_install: $(MAKE) install-indep DESTDIR=$(CURDIR)/debian/pathological override_dh_install: xmp music/intro.xm -o debian/pathological/usr/share/games/pathological/music/intro.wav xmp music/background.xm -o debian/pathological/usr/share/games/pathological/music/background.wav oggenc -b 256 debian/pathological/usr/share/games/pathological/music/intro.wav oggenc -b 160 debian/pathological/usr/share/games/pathological/music/background.wav rm -f debian/pathological/usr/share/games/pathological/music/*.xm rm -f debian/pathological/usr/share/games/pathological/music/*.wav dh_install override_dh_builddeb: dh_builddeb -- -Zxz debian/control0000644000000000000000000000215212154212624010570 0ustar Source: pathological Section: games Priority: optional Maintainer: Debian Games Team Uploaders: Alexander Reichle-Schmehl , Barry deFreese Build-Depends: debhelper (>= 9), xmp, vorbis-tools Build-Depends-Indep: netpbm, python, python-pygame Standards-Version: 3.9.4 Homepage: http://pathological.sourceforge.net/ Vcs-Svn: svn://anonscm.debian.org/pkg-games/packages/trunk/pathological/ Vcs-Browser: http://anonscm.debian.org/viewvc/pkg-games/packages/trunk/pathological/ Package: pathological Architecture: all Depends: python-pygame, ${misc:Depends}, ${python:Depends} Provides: pathological-music Conflicts: pathological-music Replaces: pathological-music Description: puzzle game involving paths and marbles Pathological is an enriched clone of the game "Logical" by Rainbow Arts. To solve a level, fill each wheel with four marbles of matching color. Various board elements such as teleporters, switches, filters, etc., make the game interesting and challenging. New levels can be created using your favorite text editor. debian/pathological.doc-base0000644000000000000000000000041512154212624013232 0ustar Document: pathological Title: How to Play Pathological Abstract: This document explains how to play the puzzle game Pathological. Section: Games/Puzzles Format: HTML Index: /usr/share/doc/pathological/html/index.html Files: /usr/share/doc/pathological/html/index.html debian/patches/0000755000000000000000000000000012154212624010614 5ustar debian/patches/series0000644000000000000000000000020712154212624012030 0ustar 10_makefile.patch 20_highscores.patch 30_no_soundcard.patch 40_pygame_181.patch define-music_pending_song.patch 60_use_ogg_music.patch debian/patches/define-music_pending_song.patch0000644000000000000000000000157412154212624016746 0ustar From: Markus Koschany Date: Mon, 15 Apr 2013 00:27:06 +0200 Subject: define music_pending_song Bug: http://bugs.debian.org/705417 Taken from the Gentoo distribution, pathological-1.1.3-music-py.patch. The original patch was presumably created by "vapier". See also http://bugs.gentoo.org/109272 --- pathological.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pathological.py b/pathological.py index e8b1f84..8ccadc6 100755 --- a/pathological.py +++ b/pathological.py @@ -30,6 +30,7 @@ fullscreen = 0 colorblind = 0 sound_on = 1 music_on = 1 +music_pending_song = 0 for arg in sys.argv[1:]: if arg == '-s': screenshot = 1 @@ -196,7 +197,7 @@ def toggle_sound(): sound_on = sound_on ^ 1 def toggle_music(): - global music_on + global music_pending_song, music_on music_on = music_on ^ 1 if music_on: if music_pending_song: debian/patches/60_use_ogg_music.patch0000644000000000000000000000220112154212624014765 0ustar Description: Newer versions of pygame.mixer having issues with .xm files. The .xm files included seem to have varying sample rates so we convert them to .ogg files at build time and patched the source to load them instead of the .xm files. The .xm files have been removed from the binary packages in favor of the .ogg files. Origin: vendor, http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=705415 Bug-Debian: http://bugs.debian.org/705415 Author: Barry deFreese Index: pathological-1.1.3/pathological.py =================================================================== --- pathological-1.1.3.orig/pathological.py 2013-06-04 11:27:18.000000000 -0400 +++ pathological-1.1.3/pathological.py 2013-06-05 18:38:13.000000000 -0400 @@ -1614,7 +1614,7 @@ popup("Please wait...\n", (150, 50)) - start_music("background.xm", ingame_music_volume) + start_music("background.ogg", ingame_music_volume) self.highscores.current_score = -1 @@ -1998,7 +1998,7 @@ self.draw() - start_music("intro.xm", intro_music_volume) + start_music("intro.ogg", intro_music_volume) while 1: # Wait for the next frame debian/patches/20_highscores.patch0000644000000000000000000001211612154212624014275 0ustar From: Debian Games Team Date: Thu, 11 Apr 2013 01:16:52 +0200 Subject: 20_highscores --- pathological | 6 +----- pathological.py | 53 ++++++++++++++++++++++++++++++++++++++++++----------- 2 files changed, 43 insertions(+), 16 deletions(-) diff --git a/pathological b/pathological index ca356b3..8a77cb7 100755 --- a/pathological +++ b/pathological @@ -32,8 +32,4 @@ done cd /usr/share/games/pathological -if [ -z "$scoresfile" ]; then - scoresfile=/var/games/pathological_scores -fi - -exec ./pathological.py $options $scoresfile +exec ./pathological.py $options diff --git a/pathological.py b/pathological.py index 5c15009..d86c6ca 100755 --- a/pathological.py +++ b/pathological.py @@ -1,6 +1,8 @@ #!/usr/bin/python +# -*- coding: iso-8859-1 -*- """ Copyright (C) 2003 John-Paul Gignac + (C) 2004 Joe Wreschnig This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -22,7 +24,7 @@ import os, pygame, random, time, math, re, sys, md5 from pygame.locals import * # Parse the command line -highscores_file = "pathological_scores" +highscores_file = os.path.join(os.environ["HOME"], ".pathological_scores") screenshot = 0 fullscreen = 0 colorblind = 0 @@ -51,7 +53,7 @@ else: # The location of the setgid script for writing highscores # This script is only used if the highscores file is not writable directly -write_highscores = "/usr/lib/pathological/bin/write-highscores" +write_highscores = "/usr/lib/games/pathological/bin/write-highscores" # Game constants wheel_steps = 9 @@ -1562,7 +1564,7 @@ def popdown( popup_rc): pygame.display.update( popup_rc[1]) class Game: - def __init__(self, screen, circuit, highscores): + def __init__(self, screen, circuit, highscores, level = 0): self.screen = screen self.circuit = circuit self.highscores = highscores @@ -1578,7 +1580,7 @@ class Game: f.close() self.numlevels = j / vert_tiles - self.level = 0 + self.level = level self.score = 0 self.lives = initial_lives @@ -1829,6 +1831,7 @@ def get_name( screen, font, cursor_box, backcol, forecol): class IntroScreen: menu = ("Start Game", "High Scores", "Fullscreen:", "Music:", "Sound Effects:", "Quit Game") + start_level = 1 menu_width = 240 menu_pos = ((800 - menu_width)/2, 145) menu_font_height = 32 @@ -1914,6 +1917,14 @@ class IntroScreen: self.screen.blit( menu_option, (self.menu_pos[0], y)) y += self.menu_font_height + levelt = self.menu_font.render("(Lvl. %d)" % + IntroScreen.start_level, + 1, self.menu_color) + lt_r = levelt.get_rect() + lt_r.right = self.menu_pos[0] + self.menu_option_left + 40 + lt_r.top = self.menu_pos[1] + self.screen.blit(levelt, lt_r) + if fullscreen: offon = 'On' else: offon = 'Off' offon = self.menu_font.render( offon, 1, self.menu_color) @@ -1966,6 +1977,15 @@ class IntroScreen: self.curpage = 1 self.draw_menu() + def inc_level(self): + if (IntroScreen.start_level < + max([s[2] for s in self.highscores.scores])): + IntroScreen.start_level += 1 + + def dec_level(self): + if IntroScreen.start_level > 1: + IntroScreen.start_level -= 1 + def do(self, show_highscores=0): self.scroller_pos = -self.scroller_rect[2] @@ -2028,7 +2048,15 @@ class IntroScreen: self.draw_menu() elif event.key == K_SPACE or event.key == K_RETURN: rc = self.menu_select( self.menu_cursor) - if rc < 1: return rc + if rc: return rc + elif event.key == K_LEFT: + if self.menu_cursor == 0: + self.dec_level() + self.draw_menu() + elif event.key == K_RIGHT: + if self.menu_cursor == 0: + self.inc_level() + self.draw_menu() continue elif event.type is MOUSEBUTTONDOWN: if self.curpage == 1: @@ -2044,9 +2072,8 @@ class IntroScreen: if pos[1] < self.menu_pos[1]: continue i = (pos[1] - self.menu_pos[1]) / self.menu_font_height if i >= len(self.menu): continue - rc = self.menu_select( i) - if rc < 1: return rc + if rc: return rc pygame.display.update( self.dirty_rects) @@ -2057,7 +2084,7 @@ class IntroScreen: # 1 - Unknown option def menu_select( self, i): if i == 0: - return 0 + return IntroScreen.start_level elif i == 1: play_sound( menu_select) self.go_to_highscores() @@ -2075,7 +2102,7 @@ class IntroScreen: self.draw_menu() elif i == 5: return -1 - return 1 + return 0 hs_font_height = 24 hs_width = 320 @@ -2157,7 +2184,10 @@ def setup_everything(): pygame.mixer.pre_init(44100,-16,1,4096) # Initialize the game module - pygame.init() + pygame.display.init() + pygame.mixer.init() + pygame.font.init() + pygame.key.set_repeat(500, 30) if not pygame.font: print 'Warning, fonts disabled' if not pygame.mixer: print 'Warning, sound disabled' @@ -2189,7 +2219,8 @@ while 1: if rc < 0: break # Handle the QUIT message - game = Game(screen, 'all-boards', highscores) + # If rc is positive, it's a level. + game = Game(screen, 'all-boards', highscores, rc - 1) show_highscores = 1 debian/patches/10_makefile.patch0000644000000000000000000000642612154212624013722 0ustar From: Debian Games Team Date: Thu, 11 Apr 2013 01:16:52 +0200 Subject: 10_makefile --- Makefile | 55 ++++++++++++++++++++++++++++--------------------------- 1 file changed, 28 insertions(+), 27 deletions(-) diff --git a/Makefile b/Makefile index dc42b93..432353b 100644 --- a/Makefile +++ b/Makefile @@ -2,59 +2,60 @@ DESTDIR = DATADIR = $(DESTDIR)/usr/share/games/pathological -all: write-highscores html/wheel.png +all: write-highscores docs write-highscores: write-highscores.c gcc -s -o write-highscores write-highscores.c +docs: html/wheel.png html/wheel.png: ./makehtml -install: all - mkdir -p $(DATADIR) - cp pathological.py $(DATADIR)/ +install: install-dep install-indep install-scores + +# Install architecture-independent data +install-indep: + install -d $(DATADIR) + install -D -m 755 pathological.py $(DATADIR)/pathological.py cp -r circuits graphics music sounds $(DATADIR)/ rm -f $(DATADIR)/graphics/*.xcf rm -f $(DATADIR)/sounds/*.orig - mkdir -p $(DESTDIR)/usr/games - cp pathological $(DESTDIR)/usr/games/ - - mkdir -p $(DESTDIR)/usr/lib/pathological/bin - cp write-highscores $(DESTDIR)/usr/lib/pathological/bin - - # The following changes should also be performed in a post-install script - -chgrp games $(DESTDIR)/usr/lib/pathological/bin/write-highscores - -chmod 2755 $(DESTDIR)/usr/lib/pathological/bin/write-highscores + install -D -m 755 pathological $(DESTDIR)/usr/games/pathological - mkdir -p $(DESTDIR)/usr/X11R6/include/X11/pixmaps - cp pathological.xpm $(DESTDIR)/usr/X11R6/include/X11/pixmaps + zcat pathological.6.gz > pathological.6 + install -D -m 644 pathological.6 $(DESTDIR)/usr/share/man/man6/pathological.6 - mkdir -p $(DESTDIR)/var/games - cp pathological_scores $(DESTDIR)/var/games + install -d $(DESTDIR)/usr/share/doc/pathological + cp -r html $(DESTDIR)/usr/share/doc/pathological - # The following changes should also be performed in a post-install script - -chgrp games $(DESTDIR)/var/games/pathological_scores - -chmod 664 $(DESTDIR)/var/games/pathological_scores + install -D -m 644 pathological.xpm $(DESTDIR)/usr/share/pixmaps/pathological.xpm - mkdir -p $(DESTDIR)/usr/share/man/man6 - cp pathological.6.gz $(DESTDIR)/usr/share/man/man6 +# Install architecture-dependent data +install-dep: + install -d $(DESTDIR)/var/games + install -D -m 2755 --owner=root --group=games write-highscores $(DESTDIR)/usr/lib/games/pathological/bin/write-highscores - mkdir -p $(DESTDIR)/usr/share/doc/pathological - cp -r html $(DESTDIR)/usr/share/doc/pathological +# Install the scores file, if it doesn't already exist. +install-scores: + if [ ! -e $(DESTDIR)/var/games/pathological_scores ]; then \ + install -D -m 644 pathological_scores $(DESTDIR)/var/games/pathological_scores; \ + fi uninstall: rm -rf $(DATADIR) - rm -rf $(DESTDIR)/usr/lib/pathological + rm -rf $(DESTDIR)/usr/lib/games/pathological rm -f $(DESTDIR)/usr/games/pathological - rm -f $(DESTDIR)/usr/X11R6/include/X11/pixmaps/pathological.xpm + rm -f $(DESTDIR)/usr/share/pixmaps/pathological.xpm rm -f $(DESTDIR)/usr/share/man/man6/pathological.6.gz purge: uninstall rm -f $(DESTDIR)/var/games/pathological_scores empty: distclean +distclean: clean -distclean: +clean: rm -f write-highscores rm -f html/*.png + rm -f pathological.6 debian/patches/40_pygame_181.patch0000644000000000000000000000121112154212624014006 0ustar From: Debian Games Team Date: Thu, 11 Apr 2013 01:16:52 +0200 Subject: 40_pygame_181 =================================================================== --- pathological.py | 1 + 1 file changed, 1 insertion(+) diff --git a/pathological.py b/pathological.py index e8b1f84..1bf5b3d 100755 --- a/pathological.py +++ b/pathological.py @@ -169,6 +169,7 @@ def start_music(name, volume=-1): if not pygame.mixer or not pygame.mixer.music: print "Background music not available." return + pygame.mixer.music.stop() fullname = os.path.join('music', name) try: pygame.mixer.music.load(fullname) debian/patches/30_no_soundcard.patch0000644000000000000000000000127412154212624014621 0ustar From: Debian Games Team Date: Thu, 11 Apr 2013 01:16:52 +0200 Subject: 30_no_soundcard --- pathological.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/pathological.py b/pathological.py index d86c6ca..e8b1f84 100755 --- a/pathological.py +++ b/pathological.py @@ -2185,7 +2185,12 @@ def setup_everything(): # Initialize the game module pygame.display.init() - pygame.mixer.init() + try: + pygame.mixer.init() + except: + print "error on pygame.mixer.init() inside setup_everything():" + print sys.exc_info()[0],":",sys.exc_info()[1] + print "...ignoring it" pygame.font.init() pygame.key.set_repeat(500, 30) debian/pathological.desktop0000644000000000000000000000036712154212624013234 0ustar [Desktop Entry] Type=Application Name=Pathological Icon=pathological Comment=Solve puzzles involving paths and marbles Comment[de]=Rätselspiel mit Wegen und Murmeln Exec=pathological Categories=Game;LogicGame; Keywords=game;logic;marbles;puzzle;