This is an automated email from the git hooks/post-receive script. jcowgill-guest pushed a commit to annotated tag debian/3.3.0-7 in repository nethack.
commit 728c8911aa74730adcb41f203c32b33dedc4e387 Merge: 8b3d746 1429f6c Author: Ben Gertzfield <[email protected]> Date: Wed Jan 12 21:50:01 2000 -0800 Imported Debian patch 3.3.0-7 Files | 160 +- Makefile | 214 - Porting | 4 +- README | 130 +- dat/Arch.des | 18 +- dat/Barb.des | 12 +- dat/Caveman.des | 12 +- dat/Healer.des | 12 +- dat/Knight.des | 12 +- dat/Makefile | 87 - dat/Monk.des | 352 ++ dat/Priest.des | 12 +- dat/{Elf.des => Ranger.des} | 211 +- dat/Rogue.des | 12 +- dat/Samurai.des | 58 +- dat/Tourist.des | 12 +- dat/Valkyrie.des | 14 +- dat/Wizard.des | 12 +- dat/bigroom.des | 34 +- dat/castle.des | 2 +- dat/cmdhelp | 14 +- dat/data.base | 1195 ++++- dat/dungeon.def | 38 +- dat/endgame.des | 8 +- dat/gehennom.des | 2 +- dat/help | 35 +- dat/hh | 21 +- dat/history | 151 +- dat/knox.des | 2 +- dat/license | 13 +- dat/medusa.des | 2 +- dat/mines.des | 2 +- dat/opthelp | 30 +- dat/oracle.des | 2 +- dat/quest.txt | 1882 ++++--- dat/rumors.fal | 15 +- dat/rumors.tru | 9 + dat/sokoban.des | 611 +++ dat/tower.des | 2 +- dat/yendor.des | 2 +- debian/README.Debian | 12 +- debian/changelog | 85 +- debian/control | 8 +- debian/copyright | 26 +- debian/dirs | 5 +- debian/nethack.init | 33 +- debian/nethack.sh | 14 +- debian/nethackrc.x11 | 6 +- debian/postinst | 11 +- debian/postrm | 3 +- debian/preinst | 55 +- debian/rules | 49 +- debian/spoilers.tar.uu | 5692 --------------------- debian/xnethack.sh | 2 +- doc/Guidebook.mn | 857 +++- doc/Guidebook.tex | 976 +++- doc/Guidebook.txt | 1656 +++++-- doc/Makefile | 85 - doc/lev_comp.6 | 2 + doc/lev_comp.txt | 8 +- doc/lists | 130 + doc/nethack.6 | 61 +- doc/nethack.txt | 148 +- doc/recover.6 | 44 +- doc/window.doc | 6 +- include/align.h | 2 +- include/amiconf.h | 12 +- include/artifact.h | 10 +- include/artilist.h | 66 +- include/attrib.h | 14 +- include/beconf.h | 31 +- include/color.h | 4 +- include/config.h | 263 +- include/config1.h | 188 + include/coord.h | 2 +- include/decl.h | 81 +- include/def_os2.h | 2 +- include/dgn_file.h | 12 +- include/display.h | 221 +- include/dlb.h | 76 +- include/dungeon.h | 30 +- include/edog.h | 13 +- include/emin.h | 8 +- include/engrave.h | 4 +- include/epri.h | 6 +- include/eshk.h | 8 +- include/extern.h | 232 +- include/flag.h | 119 +- include/func_tab.h | 6 +- include/global.h | 88 +- include/hack.h | 130 +- include/lev.h | 2 +- include/macconf.h | 18 +- include/macpopup.h | 22 + include/mactty.h | 183 +- include/macwin.h | 198 +- include/mail.h | 2 +- include/mfndpos.h | 2 +- include/micro.h | 2 +- include/mkroom.h | 39 +- include/monattk.h | 129 +- include/mondata.h | 39 +- include/monflag.h | 65 +- include/monst.h | 29 +- include/monsym.h | 5 +- include/mttypriv.h | 62 +- include/nhlan.h | 48 + include/ntconf.h | 44 +- include/obj.h | 176 +- include/objclass.h | 63 +- include/os2conf.h | 11 +- include/patchlevel.h | 40 +- include/pcconf.h | 112 +- include/permonst.h | 16 +- include/prop.h | 191 +- include/qt_clust.h | 29 + include/qt_kde0.h | 10 + include/qt_win.h | 785 +++ include/qt_xpms.h | 1393 ++++++ include/qtext.h | 32 +- include/quest.h | 10 +- include/rect.h | 6 +- include/region.h | 46 + include/rm.h | 227 +- include/skills.h | 121 + include/sp_lev.h | 31 +- include/spell.h | 12 +- include/system.h | 70 +- include/{termcap.h => tcap.h} | 10 +- include/tile2x11.h | 2 +- include/timeout.h | 5 +- include/tradstdc.h | 14 +- include/trampoli.h | 38 +- include/trap.h | 20 +- include/unixconf.h | 106 +- include/vault.h | 6 +- include/vision.h | 16 +- include/vmsconf.h | 19 +- include/winX.h | 47 +- include/winami.h | 6 +- include/winprocs.h | 10 +- include/wintty.h | 10 +- include/wintype.h | 8 +- include/{Window.h => xwindow.h} | 14 +- include/{WindowP.h => xwindowp.h} | 12 +- include/you.h | 365 +- include/youprop.h | 387 +- makelog | 115 - src/Makefile | 727 --- src/allmain.c | 340 +- src/alloc.c | 2 +- src/apply.c | 854 +++- src/artifact.c | 322 +- src/attrib.c | 327 +- src/ball.c | 38 +- src/bones.c | 52 +- src/botl.c | 267 +- src/cmd.c | 501 +- src/dbridge.c | 77 +- src/decl.c | 14 +- src/detect.c | 125 +- src/dig.c | 176 +- src/display.c | 163 +- src/dlb.c | 296 +- src/do.c | 294 +- src/do_name.c | 297 +- src/do_wear.c | 667 ++- src/dog.c | 224 +- src/dogmove.c | 118 +- src/dokick.c | 284 +- src/dothrow.c | 528 +- src/drawing.c | 169 +- src/dungeon.c | 101 +- src/eat.c | 430 +- src/end.c | 294 +- src/engrave.c | 38 +- src/exper.c | 113 +- src/explode.c | 139 +- src/extralev.c | 22 +- src/files.c | 319 +- src/fountain.c | 40 +- src/hack.c | 317 +- src/hacklib.c | 41 +- src/interp.c | 309 -- src/invent.c | 523 +- src/light.c | 80 +- src/lock.c | 64 +- src/mail.c | 111 +- src/makemon.c | 204 +- src/mcastu.c | 49 +- src/mhitm.c | 162 +- src/mhitu.c | 450 +- src/minion.c | 16 +- src/mklev.c | 173 +- src/mkmap.c | 43 +- src/mkmaze.c | 78 +- src/mkobj.c | 108 +- src/mkroom.c | 101 +- src/mon.c | 849 +++- src/mondata.c | 93 +- src/monmove.c | 173 +- src/monst.c | 1190 +++-- src/mplayer.c | 159 +- src/mthrowu.c | 133 +- src/muse.c | 637 ++- src/music.c | 79 +- src/o_init.c | 73 +- src/objects.c | 506 +- src/objnam.c | 646 ++- src/options.c | 419 +- src/pager.c | 233 +- src/pickup.c | 189 +- src/pline.c | 42 +- src/polyself.c | 460 +- src/potion.c | 385 +- src/pray.c | 419 +- src/priest.c | 84 +- src/quest.c | 153 +- src/questpgr.c | 263 +- src/read.c | 528 +- src/rect.c | 2 +- src/region.c | 941 ++++ src/restore.c | 190 +- src/rip.c | 36 +- src/rnd.c | 2 +- src/role.c | 929 ++++ src/rumors.c | 60 +- src/save.c | 111 +- src/shk.c | 222 +- src/shknam.c | 23 +- src/sit.c | 43 +- src/sounds.c | 86 +- src/sp_lev.c | 245 +- src/spell.c | 792 ++- src/steal.c | 68 +- src/steed.c | 459 ++ src/teleport.c | 243 +- src/timeout.c | 202 +- src/topten.c | 205 +- src/track.c | 2 +- src/trap.c | 705 ++- src/u_init.c | 628 ++- src/uhitm.c | 939 ++-- src/vault.c | 26 +- src/version.c | 39 +- src/vision.c | 87 +- src/weapon.c | 576 ++- src/were.c | 19 +- src/wield.c | 530 +- src/windows.c | 15 +- src/wizard.c | 71 +- src/worm.c | 40 +- src/worn.c | 231 +- src/write.c | 15 +- src/zap.c | 1140 ++++- sys/amiga/Makefile.ami | 212 +- sys/amiga/NetHack.cnf | 7 +- sys/amiga/amibug | 225 + sys/amiga/amimenu.c | 18 +- sys/amiga/amitty.c | 2 +- sys/amiga/amiwbench.c | 27 +- sys/amiga/amiwind.c | 2 +- sys/amiga/winami.c | 12 +- sys/amiga/winfuncs.c | 11 + sys/amiga/winmenu.c | 2 +- sys/atari/Makefile.utl | 2 +- sys/atari/atari.cnf | 7 +- sys/atari/nethack.mnu | 7 +- sys/atari/tos.c | 2 +- sys/be/README | 52 +- sys/be/bemain.c | 88 +- sys/mac/Files.r | 122 + sys/mac/Install.mw | 58 +- sys/mac/MacHelp | 22 +- sys/mac/NHDeflts | 109 +- sys/mac/NHrsrc.hqx | 1524 ++++-- sys/mac/NHsound.hqx | 6822 ++++++++++++++++---------- sys/mac/News | 8 +- sys/mac/README | 8 + sys/mac/dprintf.c | 38 +- sys/mac/maccurs.c | 382 +- sys/mac/macerrs.c | 111 +- sys/mac/macfile.c | 179 +- sys/mac/machelp.hqx | 67 + sys/mac/macmain.c | 655 +-- sys/mac/macmenu.c | 1005 ++-- sys/mac/macsnd.c | 98 +- sys/mac/mactopl.c | 369 +- sys/mac/mactty.c | 1828 +++---- sys/mac/macwin.c | 3581 ++++++-------- sys/mac/mgetline.c | 327 +- sys/mac/mmodal.c | 586 ++- sys/mac/mrecover.c | 19 +- sys/mac/mrecover.hqx | 135 +- sys/mac/mttymain.c | 796 ++- sys/mac/old/macsegs | 333 ++ sys/msdos/Install.dos | 78 +- sys/msdos/Makefile.BC | 558 ++- sys/msdos/Makefile.GCC | 144 +- sys/msdos/Makefile.MSC | 2175 +++----- sys/msdos/Makefile.SC | 49 +- sys/{share/NetHack.cnf => msdos/NHAccess.nh} | 82 +- sys/msdos/msdos.c | 2 +- sys/msdos/msdoshlp.txt | 26 +- sys/msdos/nhico.uu | 0 sys/msdos/nhpif.uu | 0 sys/msdos/ovlinit.c | 2 +- sys/msdos/pckeys.c | 14 +- sys/msdos/pctiles.c | 2 +- sys/msdos/pctiles.h | 2 +- sys/msdos/pcvideo.h | 4 +- sys/msdos/portio.h | 2 +- sys/msdos/schema1.BC | 497 +- sys/msdos/schema1.MSC | 249 - sys/msdos/schema2.BC | 489 +- sys/msdos/schema2.MSC | 245 - sys/msdos/schema3.MSC | 506 +- sys/msdos/setup.bat | 23 +- sys/msdos/sound.c | 2 +- sys/msdos/tile2bin.c | 4 +- sys/msdos/video.c | 18 +- sys/msdos/vidtxt.c | 2 +- sys/msdos/vidvga.c | 12 +- sys/os2/Install.os2 | 56 +- sys/os2/Makefile.os2 | 167 +- sys/os2/os2.c | 21 +- sys/share/Makefile.lib | 2 +- sys/share/NetHack.cnf | 44 +- sys/share/dgn_lex.c | 2014 +++++--- sys/share/dgn_yacc.c | 13 +- sys/share/ioctl.c | 4 +- sys/share/lev_lex.c | 3395 ++++++------- sys/share/lev_yacc.c | 4 +- sys/share/nhlan.c | 191 + sys/share/pcmain.c | 175 +- sys/share/pcsys.c | 75 +- sys/share/pctty.c | 2 +- sys/share/pcunix.c | 140 +- sys/share/tclib.c | 2 +- sys/share/unixtty.c | 3 +- sys/unix/Files | 1 - sys/unix/Install | 37 - sys/unix/Install.unx | 67 +- sys/unix/Makefile | 22 - sys/unix/Makefile.dat | 13 +- sys/unix/Makefile.doc | 2 +- sys/unix/Makefile.src | 554 +-- sys/unix/Makefile.top | 53 +- sys/unix/Makefile.utl | 132 +- sys/unix/Master | 1 - sys/unix/Name | 1 - sys/unix/Node | 1 - sys/unix/READ.ME | 51 - sys/unix/Remove | 25 - sys/unix/Size | 2 - sys/unix/System | 1 - sys/unix/depend.awk | 141 + sys/unix/install.bsd | 59 - sys/unix/interp.c | 309 -- sys/unix/nethack.sh | 3 +- sys/unix/playtest | 25 - sys/unix/setup.sh | 0 sys/unix/spkr.7 | 117 - sys/unix/spkr.c | 305 -- sys/unix/spkr.h | 34 - sys/unix/unixmain.c | 64 +- sys/unix/unixunix.c | 31 +- sys/vms/Install.vms | 27 +- sys/vms/Makefile.dat | 9 +- sys/vms/Makefile.doc | 2 +- sys/vms/Makefile.src | 423 +- sys/vms/Makefile.top | 4 +- sys/vms/Makefile.utl | 16 +- sys/vms/install.com | 23 +- sys/vms/lev_lex.h | 17 +- sys/vms/oldcrtl.c | 4 +- sys/vms/vmsbuild.com | 9 +- sys/vms/vmsfiles.c | 6 +- sys/vms/vmsmail.c | 2 +- sys/vms/vmsmain.c | 41 +- sys/vms/vmsmisc.c | 2 +- sys/vms/vmstty.c | 4 +- sys/vms/vmsunix.c | 2 +- sys/winnt/Install.nt | 61 +- sys/winnt/Makefile.nt | 231 +- sys/winnt/mapimail.c | 479 ++ sys/winnt/nethack.def | 2 +- sys/winnt/nhico.uu | 0 sys/winnt/nhsetup.bat | 16 + sys/winnt/ntsound.c | 2 +- sys/winnt/nttty.c | 313 +- sys/winnt/win32api.h | 5 +- sys/winnt/winnt.c | 69 +- sys/winnt/winnt.cnf | 22 +- util/Makefile | 335 -- util/dgn_comp.l | 2 +- util/dgn_comp.y | 13 +- util/dgn_main.c | 2 +- util/dlb_main.c | 162 +- util/lev_comp.l | 7 +- util/lev_comp.y | 4 +- util/lev_main.c | 10 +- util/makedefs.c | 180 +- util/panic.c | 2 +- util/recover.c | 97 +- win/Qt/Install.Qt | 55 + win/Qt/knethack.lnk | 18 + win/Qt/knh-mini.xpm | 30 + win/Qt/knh.xpm | 67 + win/Qt/qt_clust.cpp | 168 + win/Qt/qt_win.cpp | 4208 ++++++++++++++++ win/Qt/tileedit.cpp | 408 ++ win/Qt/tileedit.h | 128 + win/X11/Install.X11 | 13 +- win/X11/NetHack.ad | 15 +- win/X11/Window.c | 4 +- win/X11/nethack.rc | 23 +- win/X11/nh32icon | 4 +- win/X11/nh56icon | 10 +- win/X11/nh72icon | 2 +- win/X11/rip.xpm | 580 +-- win/X11/winX.c | 22 +- win/X11/winmap.c | 22 +- win/X11/winmenu.c | 16 +- win/X11/winmesg.c | 4 +- win/X11/winmisc.c | 172 +- win/X11/winstat.c | 2 +- win/X11/wintext.c | 4 +- win/X11/winval.c | 2 +- win/share/monsters.txt | 1837 +++++-- win/share/objects.txt | 1570 ++++-- win/share/other.txt | 596 ++- win/share/thintile.c | 2 +- win/share/tilemap.c | 64 +- win/share/tiletext.c | 47 +- win/tty/getline.c | 25 +- win/tty/termcap.c | 55 +- win/tty/topl.c | 9 +- win/tty/wintty.c | 529 +- win/win32/nhprocs.c | 1147 ----- win/win32/nhwin32.h | 314 -- win/win32/nhwin32.rc | 140 - win/win32/tile2bmp.c | 120 +- win/win32/win32msg.c | 583 --- win/win32/winmain.c | 341 -- 445 files changed, 59379 insertions(+), 41306 deletions(-) diff --cc debian/README.Debian index 90c7ad9,0000000..24aa09e mode 100644,000000..100644 --- a/debian/README.Debian +++ b/debian/README.Debian @@@ -1,21 -1,0 +1,21 @@@ - README for Debian GNU/Linux Nethack 3.2.2: ++README for Debian GNU/Linux Nethack 3.3.0: + +Nethack is a wonderfully silly yet quite addicting Dungeons and +Dragons-style adventure game. You play the part of a fierce fighter, +wizard, or any of many other classes, fighting your way down to +retrieve the Amulet of Yendor (try saying THAT one backwards!) for +your god. On the way, you might encounter a quantum mechanic or two, +or perhaps a microscopic space fleet, or -- if you're REALLY lucky -- +the Ravenous Bugblatter Beast of Traal. + - The Debian package of Nethack includes spoiler files, to be read only - in sheer desperation, in /usr/doc/nethack/spoilers. ++There is a nethack-spoilers package available separately if you are ++really stuck, to be used only as a last resort. + +A few utilities -- recover, for retrieving your auto-save files in case +of a power failure, and dgn_comp and lev_comp, two utilities for making +your own Nethack levels and dungeons, have been included in +/usr/lib/games/nethack. + - The recover utility will be run upon bootup, by /etc/rc.boot/nethack. - Any auto-save files will be retrieved and converted into proper save - files. ++The recover utility will be run upon bootup by /etc/init.d/nethack. ++Any auto-save files still on the system from a possible crash will be ++retrieved and converted into proper save files. diff --cc debian/changelog index a93cc15,0000000..b2c4c50 mode 100644,000000..100644 --- a/debian/changelog +++ b/debian/changelog @@@ -1,198 -1,0 +1,257 @@@ - nethack (3.2.3-3) stable; urgency=low ++nethack (3.3.0-7) unstable; urgency=low + - * Make sure we chmod +x nethack.6 as we aren't using dh_installmanpages - (Closes: #53668) ++ * Patch to fix bones-file handling in /var/lib/games/nethack. ++ (The bones-file functions were changed from 3.2.2 and so ++ broke my older patch.) Closes: #54961 + - -- Ben Gertzfield <[email protected]> Tue, 28 Dec 1999 23:12:01 -0800 ++ -- Ben Gertzfield <[email protected]> Wed, 12 Jan 2000 21:50:01 -0800 + - nethack (3.2.3-2) stable; urgency=low ++nethack (3.3.0-6) unstable; urgency=low + - * Don't use dh_installmanpages/dh_installdocs because there's - no way to force them not to install into /usr/share/doc and - /usr/share/man for slink.. ++ * Change /usr/games/nethack script to remove stupid 'max number of ++ Nethack players at once' hack. ++ * Change /etc/init.d/nethack to work on *any* lock files in ++ /var/lib/games/nethack (use *.0 instead of *lock.0) ++ * Patch to fix nasty bugs introduced by separating lock/savefiles ++ into /var/lib/games/nethack. (Forgot some /s to a few sprintfs, ++ ouch!) ++ * Patch to fix recover to work with separate /var/lib/games/nethack ++ once again. Closes: #52995 ++ * Change default cat/dog/fruit names when using xnethack to be ++ more.. Debian-y. :) + - -- Ben Gertzfield <[email protected]> Mon, 20 Dec 1999 09:34:50 -0800 ++ -- Ben Gertzfield <[email protected]> Wed, 5 Jan 2000 16:32:53 -0800 + - nethack (3.2.3-1) stable; urgency=HIGH ++nethack (3.3.0-5) unstable; urgency=low + - * This may be more acceptable for a stable update. It includes - only Y2K and critical bug fixes. (Closes: #52730) ++ * Make root the user able to enter wizard (debug) mode with 'nethack -D' ++ instead of user 'wizard', the old default. Closes: #53901 ++ * Add link from /usr/lib/games/nethack/license -> ++ /usr/share/doc/nethack/copyright so ?i works in game. Closes: #53979 ++ * Make sure we pass arguments to nethack when run from xnethack ++ script. Fixes: #54104 + - -- Ben Gertzfield <[email protected]> Tue, 14 Dec 1999 15:56:44 -0800 ++ -- Ben Gertzfield <[email protected]> Wed, 5 Jan 2000 10:23:32 -0800 ++ ++nethack (3.3.0-4) unstable; urgency=low ++ ++ * Add color patch to fix swap of red and blue colors. ++ * Port Linux console IBMgraphics patch from 3.2.2. ++ * Remove all use of --suffix argument to tempfile, to make ++ building slink packages easier. Closes: #52968 ++ ++ -- Ben Gertzfield <[email protected]> Fri, 17 Dec 1999 15:26:05 -0800 ++ ++nethack (3.3.0-3) unstable; urgency=low ++ ++ * Fix missing 'esac' at end of /etc/init.d/nethack. Closes: #52738 ++ ++ -- Ben Gertzfield <[email protected]> Tue, 14 Dec 1999 15:35:32 -0800 ++ ++nethack (3.3.0-2) unstable; urgency=low ++ ++ * Note split of spoilers in README.Debian. Closes: #52628 ++ * Improve logic in preinst for various combinations of 'install' and ++ 'upgrade' arguments. ++ * Test for existence of /var/lib/games/nethack before trying to archive ++ it in preinst. Closes: #52666 ++ * (Yes, 3.3.0 fixes the Y2K bugs in Nethack! Sorry for not mentioning ++ this below.) ++ ++ -- Ben Gertzfield <[email protected]> Mon, 13 Dec 1999 22:15:10 -0800 ++ ++nethack (3.3.0-1) unstable; urgency=low ++ ++ * Finally! A new upstream version! Fixes: #52565 ++ * No more bashisms in postinst. Fixes: #36006 ++ * Use /etc/init.d/nethack and a link /etc/rcS.d/nethack instead ++ of /etc/rc.boot/nethack. Fixes: #32441 ++ * Spoilers split off into separate nethack-spoilers package. (Note: ++ spoilers may be out of date now for 3.3.0!) ++ * NOTE NOTE NOTE: Save files from 3.2.2 are *NOT COMPATIBLE* with ++ 3.3.0 so the preinst will prompt the user and archive the old ++ save directory, or abort. ++ * Now depends on debianutils (>= 1.13) because we use 'tempfile' ++ program in the preinst to get a safe filename for archiving ++ into for the above NOTE NOTE NOTE. This sucks, though, because ++ slink's debianutils is 1.10, but it doesn't support the ++ --suffix we need to make a tempfile with .tar.gz as the extension. ++ ++ -- Ben Gertzfield <[email protected]> Sun, 12 Dec 1999 14:22:23 -0800 + +nethack (3.2.2-16) unstable; urgency=low + + * Use Richard Braakman's wonderful patch to fix color support in + Nethack with ncurses 4.2. (Fixes: #27817) + * Use Hartmut Koptein's patch for glibc 2.1 prototypes checking. + (Fixes: #32012) + + -- Ben Gertzfield <[email protected]> Thu, 21 Jan 1999 07:00:41 -0800 + +nethack (3.2.2-15) frozen unstable; urgency=low + + * Recompile with ncurses 4.2. + + -- Ben Gertzfield <[email protected]> Fri, 30 Oct 1998 12:38:12 -0800 + +nethack (3.2.2-14) unstable; urgency=low + + * Add test in preinst to make sure we don't check $2 on anything + but an upgrade, as dpkg can call the preinst with no $2 if + we're doing a fresh install, and that'll make my test to see + what version we're upgrading from crash. (Fixes: #27101) + + -- Ben Gertzfield <[email protected]> Sat, 26 Sep 1998 10:57:36 -0700 + +nethack (3.2.2-13) unstable; urgency=low + + * Applied David Damerell's paranoid_quit and big top 10 patches. + (Fixes: #26609) + + -- Ben Gertzfield <[email protected]> Mon, 21 Sep 1998 19:30:22 -0700 + +nethack (3.2.2-12) unstable; urgency=low + + * Made postinst really anal on checks for upgrades from old versions, + to make all permissions correct. (Fixes: #25881, #19588) + * Converted debian/rules to debhelper. (Fixes: #14492) + * /var/lib/games/nethack/{record,logfile,perm} are no longer conffiles, + and the management of them has moved to the postinst/postrm scripts. + * Enabled tiles by default when running with X enhancements. + * Created xnethack script to run the X-based nethack. + * Disabled the mail daemon mail-check in X-based nethack, as it + could cause nethack to freeze if run from the menu entry (as + opposed to from within an xterm). + + -- Ben Gertzfield <[email protected]> Tue, 18 Aug 1998 17:10:16 -0700 + +nethack (3.2.2-11) unstable; urgency=low + + * Hamm release of 3.2.2-10. + + -- Ben Gertzfield <[email protected]> Tue, 28 Oct 1997 17:38:11 -0800 + +nethack (3.2.2-10) stable; urgency=low + + * Re-built with libc5 libraries, as 3.2.2-7 was broken. + * Fixed text menu entry pausing bug. + * Took out dpkg-shlibdeps call for the lib5 build. + * Changed chmod /var/lib/games/nethack 04775 in postinst to 02775. + + -- Ben Gertzfield <[email protected]> Tue, 28 Oct 1997 12:53:37 -0800 + +nethack (3.2.2-9) unstable; urgency=low + + * Re-added fix for permissions on /var/lib/games/nethack to postinst; + fixes bug #13596. + * Added X NetHack entry to menu file, fixes wishlist #13036. + * Menu entry for text NetHack now pauses after the game ends, fixes + bug #13035. + * Built with all-glibc libraries, fixes bug #12793. + * Copied 'license' text-file to /usr/lib/games/nethack, fixes bug #13033. + * Upgraded to Standards-Version 2.3.0.0. + + -- Ben Gertzfield <[email protected]> Fri, 10 Oct 1997 16:17:46 -0700 + +nethack (3.2.2-8) unstable; urgency=low + + * New maintainer. + * Compiled under libc6. + * Added patch for proper IBM graphics support. + * Added patch for sound (speaker) support at the console. + * No longer writes to /usr/lib/games/nethack; fixes bug #10454. + * No longer uses i386-specific commands in makefile; fixes bug #10795. + * Re-added dgn_comp and lev_comp to package; fixes bug #11013. + * Created /etc/rc.boot/nethack to recover save-files on boot; + fixes bug #11012. + * Changed rules file to no longer use debstd. + * Made the recover utility setgid and removed the -d option to + prevent cheating. + * Really fixed bug #10149 -- both logfile and record are now + conffiles. + * If upgrading from a version with incompatible logfile/record files, + warns before clearing out /var/lib/games/nethack. + + -- Ben Gertzfield <[email protected]> Wed, 23 Jul 1997 20:33:26 -0500 + +nethack (3.2.2-7) frozen unstable; urgency=low + + * changes to makefile to force compiling under libc5 + * fixed bug #10149: upgrading no longer kills the high score file + * fixed bug #9839: now provides nh10 font + + -- Paul Haggart <[email protected]> Mon, 26 May 1997 22:34:36 -0400 + +nethack (3.2.2-6) frozen unstable; urgency=low + + * routine cleanup of makefiles + * fixed debian/rules to actually clean up on 'debian/rules clean' + * fixed bug #9288: debian/rules doesn't delete manpages until after build + * fixed bug #9287: X11 support added + + -- Paul Haggart <[email protected]> Thu, 1 May 1997 19:32:57 -0400 + +nethack (3.2.2-5) frozen unstable; urgency=low + + * postinst tweak to allow saved games to actually save + + -- Paul Haggart <[email protected]> Wed, 23 Apr 1997 22:55:20 -0400 + +nethack (3.2.2-4) frozen unstable; urgency=low + + * added postinst to fix bad permissions/owners on upgrades + * fixed termcap/terminfo bug + + -- Paul Haggart <[email protected]> Tue, 8 Apr 1997 22:35:44 -0400 + +nethack (3.2.2-3) unstable; urgency=high + + * fixed -massive- error with lockfiles + * fixed gzip error with saved games + * now includes 'recovery' so you can try to restore a crashed game + + -- Paul Haggart <[email protected]> Sat, 15 Feb 1997 18:43:48 -0500 + +nethack (3.2.2-2) unstable; urgency=low + + * changed email address from 'debian.com' to 'debian.org' + + -- Paul Haggart <[email protected]> Wed, 12 Feb 1997 15:55:33 -0500 + +nethack (3.2.2-1) unstable; urgency=low + + * new upstream source (sorry this took so long to get done!) + * wizard patch removed .. it wouldn't patch into 3.2.2 + + -- Paul Haggart <[email protected]> Mon, 10 Feb 1997 22:08:09 -0500 + +nethack (3.2.1-4) unstable; urgency=low + + * removed qt interface because of policy complaints + + -- Paul Haggart <[email protected]> Mon, 2 Dec 1996 15:08:15 -0500 + +nethack (3.2.1-3) unstable; urgency=low + + * added wizard patch + + -- Paul Haggart <[email protected]> Mon, 18 Nov 1996 19:12:24 -0500 + +nethack (3.2.1-2) unstable; urgency=low + + * added qt interface + * added spoiler files + + -- Paul Haggart <[email protected]> Sat, 16 Nov 1996 02:22:05 -0500 + +nethack (3.2.1-1) unstable; urgency=low + + * New maintainer + * Initial release + + -- Paul Haggart <[email protected]> Sun, 27 Oct 1996 05:56:48 -0500 + +Local variables: +add-log-mailing-address: "[email protected]" +mode: debian-changelog +End: diff --cc debian/control index 6f4c8f4,0000000..24c3fbd mode 100644,000000..100644 --- a/debian/control +++ b/debian/control @@@ -1,27 -1,0 +1,27 @@@ +Source: nethack +Section: games +Priority: optional +Maintainer: Ben Gertzfield <[email protected]> - Standards-Version: 2.4.0.0 ++Standards-Version: 3.1.1.1 + +Package: nethack +Architecture: any - Depends: ${shlibs:Depends} ++Depends: ${shlibs:Depends}, debianutils (>= 1.10) +Description: Text-based/X11 overhead view D&D-style adventure game + Nethack is a wonderfully silly, yet quite addicting, Dungeons and + Dragons-style adventure game. You play the part of a fierce fighter, + wizard, or any of many other classes, fighting your way down to + retrieve the Amulet of Yendor (try saying THAT one backwards!) for + your god. On the way, you might encounter a quantum mechanic or two, + or perhaps a microscopic space fleet, or -- if you're REALLY lucky -- + the Ravenous Bugblatter Beast of Traal. + . - The Debian package of Nethack includes spoiler files, to be read only - in sheer desperation, in /usr/doc/nethack/spoilers. ++ There is a nethack-spoilers package available, if you're really ++ desparate. + . + A few utilities -- recover, for retrieving your auto-save files in case + of a power failure, and dgn_comp and lev_comp, two utilities for making + your own Nethack levels and dungeons, have been included in + /usr/lib/games/nethack. 'recover' will be run every time your system + boots, if there are any auto-save files available. + diff --cc debian/copyright index afd4b90,0000000..357ab28 mode 100644,000000..100644 --- a/debian/copyright +++ b/debian/copyright @@@ -1,103 -1,0 +1,107 @@@ - This package was debianized by Paul Haggart <[email protected]> on - Mon, 12 Feb 1997 15:52:37 -0500. ++This package was created by Ben Gertzfield <[email protected]> on ++Sun, 12 Dec 1999 14:23:01 -0800. It was originally Debianized by ++Paul Haggart <[email protected]>. + - It was downloaded from: - ftp://ftp.win.tue.nl/pub/games/nethack/ ++Nethack's home site is: http://www.nethack.org/ ++ ++This archive was downloaded from: ++ftp://ftp.nethack.org/pub/nethack/src/nethack-3.3.0.tar.gz + +Copyright: + + NETHACK GENERAL PUBLIC LICENSE + (Copyright 1989 M. Stephenson) + + (Based on the BISON general public license, + copyright 1988 Richard M. Stallman) + + Everyone is permitted to copy and distribute verbatim copies of this + license, but changing it is not allowed. You can also use this wording to + make the terms for other programs. + + The license agreements of most software companies keep you at the mercy of +those companies. By contrast, our general public license is intended to give +everyone the right to share NetHack. To make sure that you get the rights we +want you to have, we need to make restrictions that forbid anyone to deny you +these rights or to ask you to surrender the rights. Hence this license +agreement. + + Specifically, we want to make sure that you have the right to give away +copies of NetHack, that you receive source code or else can get it if you +want it, that you can change NetHack or use pieces of it in new free +programs, and that you know you can do these things. + + To make sure that everyone has such rights, we have to forbid you to +deprive anyone else of these rights. For example, if you distribute copies +of NetHack, you must give the recipients all the rights that you have. You +must make sure that they, too, receive or can get the source code. And you +must tell them their rights. + + Also, for our own protection, we must make certain that everyone finds out +that there is no warranty for NetHack. If NetHack is modified by someone +else and passed on, we want its recipients to know that what they have is +not what we distributed. + + Therefore we (Mike Stephenson and other holders of NetHack copyrights) make +the following terms which say what you must do to be allowed to distribute or +change NetHack. + + + COPYING POLICIES + + 1. You may copy and distribute verbatim copies of NetHack source code as +you receive it, in any medium, provided that you keep intact the notices on +all files that refer to copyrights, to this License Agreement, and to the +absence of any warranty; and give any other recipients of the NetHack +program a copy of this License Agreement along with the program. + + 2. You may modify your copy or copies of NetHack or any portion of it, and +copy and distribute such modifications under the terms of Paragraph 1 above +(including distributing this License Agreement), provided that you also do the +following: + + a) cause the modified files to carry prominent notices stating that you + changed the files and the date of any change; and + + b) cause the whole of any work that you distribute or publish, that in + whole or in part contains or is a derivative of NetHack or any part + thereof, to be licensed at no charge to all third parties on terms + identical to those contained in this License Agreement (except that you + may choose to grant more extensive warranty protection to some or all + third parties, at your option) + + c) You may charge a distribution fee for the physical act of + transferring a copy, and you may at your option offer warranty protection + in exchange for a fee. + + 3. You may copy and distribute NetHack (or a portion or derivative of it, +under Paragraph 2) in object code or executable form under the terms of +Paragraphs 1 and 2 above provided that you also do one of the following: + + a) accompany it with the complete machine-readable source code, which + must be distributed under the terms of Paragraphs 1 and 2 above; or, + + b) accompany it with full information as to how to obtain the complete + machine-readable source code from an appropriate archive site. (This + alternative is allowed only for noncommercial distribution.) + +For these purposes, complete source code means either the full source +distribution as originally released over Usenet or updated copies of the +files in this distribution used to create the object code or executable. + + 4. You may not copy, sublicense, distribute or transfer NetHack except as +expressly provided under this License Agreement. Any attempt otherwise to +copy, sublicense, distribute or transfer NetHack is void and your rights to +use the program under this License agreement shall be automatically +terminated. However, parties who have received computer software programs +from you with this License Agreement will not have their licenses terminated +so long as such parties remain in full compliance. + - Stated plainly: You are prohibited by the terms of this License Agreement - from using NetHack for gainful purposes. You are permitted to modify - NetHack, or otherwise use parts of NetHack, provided that you comply with - the conditions specified above; in particular, your modified NetHack or - program containing parts of NetHack must remain freely available as provided - in this License Agreement. In other words, go ahead and share NetHack, but - don't try to stop anyone else from sharing it farther. ++ ++Stated plainly: You are permitted to modify NetHack, or otherwise use parts ++of NetHack, provided that you comply with the conditions specified above; ++in particular, your modified NetHack or program containing parts of NetHack ++must remain freely available as provided in this License Agreement. In ++other words, go ahead and share NetHack, but don't try to stop anyone else ++from sharing it farther. ++ diff --cc debian/dirs index 0d8abc7,0000000..1bfce0b mode 100644,000000..100644 --- a/debian/dirs +++ b/debian/dirs @@@ -1,8 -1,0 +1,7 @@@ +usr/games +usr/X11R6/lib/X11/app-defaults +usr/X11R6/lib/X11/fonts/misc +usr/lib/games/nethack +var/lib/games/nethack/save - etc/rc.boot - usr/man/man6 - usr/doc/nethack ++etc/init.d ++usr/share/doc/nethack diff --cc debian/nethack.init index b64b9a2,0000000..103eddd mode 100644,000000..100644 --- a/debian/nethack.init +++ b/debian/nethack.init @@@ -1,29 -1,0 +1,32 @@@ +#!/bin/sh + +# Nethack save-file recovery script for Debian +# +# Ben Gertzfield ([email protected]) 29 July 1997 +# Copyright 1997 Ben Gertzfield. This script is released under the +# GNU General Public License, version 2 or later. + +PATH=/bin:/usr/bin:/sbin:/usr/sbin + +set -e + - # Has the nethack package been removed? - test -f /usr/lib/games/nethack/recover || exit 0 ++case "$1" in ++ start) ++ # Has the nethack package been removed? ++ test -x /usr/lib/games/nethack/recover || exit 0 + - # Are there any lock-files to recover? - ls /var/lib/games/nethack/*lock.0 >/dev/null 2>&1 || exit 0 ++ # Are there any lock-files to recover? ++ ls /var/lib/games/nethack/*.0 >/dev/null 2>&1 || exit 0 + - # Yes; recover them. - for file in /var/lib/games/nethack/*lock.0; do - owner=$(ls -l $file | awk '{print $3}') - echo -n "Recovering Nethack save file owned by $owner: " - su $owner -c "/usr/lib/games/nethack/recover $file" >/dev/null 2>&1 - if (($?)); then - echo error $?\! - else - echo "recovered." - fi - done ++ # Yes; recover them. ++ for file in /var/lib/games/nethack/*.0; do ++ owner=$(ls -l $file | awk '{print $3}') ++ echo "Recovering Nethack save file owned by $owner..." ++ su --shell=/bin/sh --command="/usr/lib/games/nethack/recover $file" $owner ++ if (($?)); then ++ echo "error $?\!" ++ else ++ echo "recovered." ++ fi ++ done ++esac diff --cc debian/nethack.sh index 6ee8b4e,0000000..f683822 mode 100644,000000..100644 --- a/debian/nethack.sh +++ b/debian/nethack.sh @@@ -1,58 -1,0 +1,52 @@@ +#!/bin/sh - # SCCS Id: @(#)nethack.sh 3.2 90/02/26 ++# SCCS Id: @(#)nethack.sh 3.3 90/02/26 + +HACKDIR=/usr/lib/games/nethack ++export HACKDIR +HACK=$HACKDIR/nethack - MAXNROFPLAYERS=42 + +# see if we can find the full path name of PAGER, so help files work properly +# assume that if someone sets up a special variable (HACKPAGER) for NetHack, +# it will already be in a form acceptable to NetHack +# ideas from [email protected] +if test \( "xxx$PAGER" != xxx \) -a \( "xxx$HACKPAGER" = xxx \) +then + + HACKPAGER=$PAGER + +# use only the first word of the pager variable +# this prevents problems when looking for file names with trailing +# options, but also makes the options unavailable for later use from +# NetHack + for i in $HACKPAGER + do + HACKPAGER=$i + break + done + + if test ! -f $HACKPAGER + then + IFS=: + for i in $PATH + do + if test -f $i/$HACKPAGER + then + HACKPAGER=$i/$HACKPAGER + export HACKPAGER + break + fi + done + IFS=' ' + fi + if test ! -f $HACKPAGER + then + echo Cannot find $PAGER -- unsetting PAGER. + unset HACKPAGER + unset PAGER + fi +fi + + +cd $HACKDIR - case $1 in - -s*) - exec $HACK -d $HACKDIR "$@" - ;; - *) - exec $HACK -d $HACKDIR "$@" $MAXNROFPLAYERS - ;; - esac ++exec $HACK "$@" ++ diff --cc debian/nethackrc.x11 index 41231a9,0000000..cc53c4c mode 100644,000000..100644 --- a/debian/nethackrc.x11 +++ b/debian/nethackrc.x11 @@@ -1,72 -1,0 +1,72 @@@ +# +# System-wide NetHack configuration file for X-based NetHack. +# + +OPTIONS=windowtype:x11,toptenwin,hilite_pet +OPTIONS=fixinv,safe_pet,sortpack,tombstone,color - OPTIONS=verbose,news,fruit:yiffmelon - OPTIONS=dogname:Kitsune - OPTIONS=catname:Neko-chan ++OPTIONS=verbose,news,fruit:potato ++OPTIONS=dogname:Slinky ++OPTIONS=catname:Rex +OPTIONS=pickup_types:$ +OPTIONS=nomail + +# +# There are 17 object symbols and various graphics symbols. +# The descriptions of these symbols can be found in dat/opthelp. +# +# +# Font: nh10 (10x20) +# +OBJECTS= 180 183 188 192 181 184 182 189 190 196 \ + 191 194 193 187 185 186 195 +# +DUNGEON= 032 025 018 013 012 014 011 015 023 024 \ + 022 021 128 129 130 131 132 133 134 135 \ + 136 137 145 146 144 143 142 141 140 149 \ + 150 031 031 147 148 031 161 140 +# +TRAPS= 138 138 138 138 138 138 138 138 138 138 \ + 138 138 138 138 138 139 138 138 138 138 \ + 138 138 +# +EFFECTS= 151 152 153 154 155 156 157 158 \ + 159 160 161 162 \ + 163 164 165 166 167 168 169 170 \ + 171 172 173 174 175 176 177 178 179 +# +# +# Font: ibm (8x14) +# +#OBJECTS= 207 210 215 219 208 211 209 216 217 223 \ +# 218 221 220 214 212 213 222 +# +#DUNGEON= 032 128 129 130 131 132 133 134 135 136 \ +# 137 138 139 045 124 142 143 144 145 146 \ +# 147 148 155 156 227 154 153 152 151 159 \ +# 160 200 200 157 158 250 170 151 +# +#TRAPS= 149 149 149 149 149 149 149 149 149 149 \ +# 149 149 149 149 149 150 149 149 149 149 \ +# 149 149 +# +#EFFECTS= 161 162 163 164 165 166 167 168 \ +# 169 170 171 172 \ +# 173 174 175 176 177 178 179 180 \ +# 181 182 183 184 185 186 187 188 189 +# +# +# Font: a "standard" font like 6x13 +# +#DUNGEON = 032 025 018 013 012 014 011 015 023 024 \ +# 022 021 031 045 124 043 043 031 035 001 \ +# 060 062 060 062 019 092 035 123 125 031 \ +# 125 046 046 035 035 046 127 125 +# +#TRAPS= 094 094 094 094 094 094 094 094 094 094 \ +# 094 094 094 094 094 002 094 094 094 094 \ +# 094 094 +# +#EFFECTS= 124 045 092 047 042 033 041 040 \ +# 048 035 064 042 \ +# 047 045 092 124 124 092 045 047 \ +# 047 064 092 064 064 064 092 064 047 diff --cc debian/postinst index a5c3c87,0000000..6e88483 mode 100644,000000..100644 --- a/debian/postinst +++ b/debian/postinst @@@ -1,38 -1,0 +1,43 @@@ +#!/bin/sh + +# Nethack post-installation script for Debian +# +# Ben Gertzfield ([email protected]) 29 July 1997 +# Copyright 1997 Ben Gertzfield. This script is released under the +# GNU General Public License, version 2 or later. + +# Modified 10 October 1997 to fix permissions on /var/lib/games/nethack. +# Modified 18 August 1998 to fix more upgrade problems from ancient +# nethacks + +set -e + +# This is super anal. It should work for all cases, for all upgrades. + +find /var/lib/games/nethack -print0 | xargs -r -0 chgrp games + +chmod 02775 /var/lib/games/nethack/ + +find /var/lib/games/nethack -type f -print0 | xargs -r -0 chmod 664 +find /var/lib/games/nethack -type f -name '*lock*' -print0 | xargs -r -0 chmod 660 + +chmod 02775 /var/lib/games/nethack/save/ + +find /var/lib/games/nethack/save -type f -print0 | xargs -r -0 chmod 660 + +# These have been moved to the postinst per policy; they should not be +# conffiles. They are removed on purge in the postrm. + - touch /var/lib/games/nethack/{perm,record,logfile} - chown root.games /var/lib/games/nethack/{perm,record,logfile} - chmod 0664 /var/lib/games/nethack/{perm,record,logfile} ++for file in perm record logfile; do ++ touch /var/lib/games/nethack/$file ++ chown root.games /var/lib/games/nethack/$file ++ chmod 0664 /var/lib/games/nethack/$file ++done + +if [ -x /usr/X11R6/bin/mkfontdir ] ; then /usr/X11R6/bin/mkfontdir \ + /usr/X11R6/lib/X11/fonts/misc ; fi + ++# Set up link /etc/rcS.d/S85nethack -> /etc/init.d/nethack ++update-rc.d nethack start 85 S . >/dev/null ++ +#DEBHELPER# diff --cc debian/postrm index e830260,0000000..e8654d0 mode 100644,000000..100644 --- a/debian/postrm +++ b/debian/postrm @@@ -1,23 -1,0 +1,24 @@@ +#!/bin/sh + +# Nethack post-remove script for Debian +# +# Ben Gertzfield ([email protected]) 29 July 1997 +# Copyright 1997 Ben Gertzfield. This script is released under the +# GNU General Public License, version 2 or later. + +# Updated 18 August 1998 to rm -rf the score/save directory on a purge, +# added debhelper comments + +set -e + +if [ -x /usr/X11R6/bin/mkfontdir ] ; then /usr/X11R6/bin/mkfontdir \ + /usr/X11R6/lib/X11/fonts/misc ; fi + +if [ "$1" = "purge" ]; then ++ update-rc.d nethack remove >/dev/null + echo -n "Purging high-scores and save-files for Nethack... " + rm -rf /var/lib/games/nethack/ + echo "done." +fi + - #DEBHELPER# ++#DEBHELPER# diff --cc debian/preinst index 7daf5d3,0000000..0eecb0c mode 100644,000000..100644 --- a/debian/preinst +++ b/debian/preinst @@@ -1,38 -1,0 +1,69 @@@ +#!/bin/sh + +# Nethack pre-installation script for Debian +# +# Ben Gertzfield ([email protected]) 29 July 1997 +# Copyright 1997 Ben Gertzfield. This script is released under the +# GNU General Public License, version 2 or later. + +set -e + - if [ $1 != "configure" ] ; then - exit 0 ++# We only want to take action if we are called as: ++# nethack.preinst upgrade old-version ++# or ++# nethack.preinst install old-version ++ ++if [ "$1" != "upgrade" ] && [ "$1" != "install" ] || [ ! "$2" ]; then ++ exit 0 +fi + - dpkg --compare-versions $2 lt-nl 3.2.2 || exit 0 ++SAFEVER=3.3.0 ++LOGDIR=/var/lib/games/nethack ++ ++dpkg --compare-versions $2 lt-nl $SAFEVER || exit 0 ++ ++# Make sure $LOGDIR exists before we try to archive it ++ ++if [ ! -d $LOGDIR ]; then ++cat <<EOF ++Your previous version of Nethack, $2, had save-game files incompatible ++with the current version. ++ ++Normally, your $LOGDIR would be backed up into a ++.tar.gz file in /tmp, but for some reason that directory does not ++exist on your system, so we will just continue with the installation ++and pretend nothing went wrong. Did you perhaps remove ++$LOGDIR by hand? ++ ++EOF ++ exit 0 ++fi + +cat <<EOF - You seem to have a version of Nethack prior to this package's version, - which is 3.2.2. Unfortunately, the save files and high scores that - older versions used are incompatible with this version, and will be - cleared if you continue installing this package. ++Your previous version of Nethack, $2, has save-game files incompatible ++with the current version. To fix this, your $LOGDIR ++will be backed up into a .tar.gz file in /tmp and then wiped clean. + - If you want to save these, back up /var/lib/games/nethack now! ++If you do not say "n" here and abort, look in /tmp for your old ++save-game files and high-score files. + +EOF + - echo -n "Do you want to continue? (Y/n) " ++printf "Do you want to continue? (Y/n) " +read answer + +if [ "$answer" = "n" -o "$answer" = "N" ] ; then - echo "Aborting installation of Nethack." ++ printf "Aborting installation of Nethack.\n" + exit 1 +else - echo "Removing old save files and high scores.." - rm -rf /var/lib/games/nethack ++ BACKUP=`tempfile --directory=/tmp --prefix=nethk` ++ printf "Backing up $LOGDIR to $BACKUP... " ++ printf "(NOTE: $BACKUP *is* a .tar.gz archive, it just is missing" ++ printf " its suffix. You can unpack it with tar zxvf as normal.)" ++ tar zcf $BACKUP $LOGDIR >/dev/null 2>&1 ++ printf "done.\nRemoving old save files and high scores... " ++ rm -rf $LOGDIR ++ printf "done.\nYou can find your old save games and score files in $BACKUP.\n" +fi + + diff --cc debian/rules index 7e17b09,0000000..3b5fd77 mode 100755,000000..100755 --- a/debian/rules +++ b/debian/rules @@@ -1,110 -1,0 +1,113 @@@ +#!/usr/bin/make -f + +# Nethack build script for Debian +# +# Ben Gertzfield ([email protected]) 29 July 1997 +# Copyright 1997 Ben Gertzfield. This script is released under the +# GNU General Public License, version 2 or later. + +build: build-stamp +build-stamp: + dh_testdir + - make all CFLAGS='-DDEBIAN -O2 -I../include \ - -I/usr/X11R6/include -fomit-frame-pointer' ++ # setup.sh makes the symlinks for the Makefiles. Giving it any ++ # argument (in this case, 1) tells it to make symlinks. ++ sh sys/unix/setup.sh 1 + - cd util && make recover CFLAGS='-DDEBIAN -O2 -I../include \ - -I/usr/X11R6/include -fomit-frame-pointer' ++ make all CFLAGS='-O2 -I../include \ ++ -I/usr/X11R6/include -fomit-frame-pointer' LFLAGS='-L/usr/X11R6/lib' ++ ++ cd util && make recover CFLAGS='-O2 -I../include \ ++ -I/usr/X11R6/include -fomit-frame-pointer' LFLAGS='-L/usr/X11R6/lib' + + touch build-stamp + +clean: + dh_testdir + dh_testroot + -rm -f build-stamp nh10.pcf + -rm -f `find . -name "*.orig"` + -rm -f `find . -name "*~"` + -rm -rf debian/tmp debian/files* core debian/substvars + -make spotless ++ find . -name Makefile -print0 | xargs -r -0 rm + dh_clean - ++ +binary-indep: build +# Nothing to do by default + +binary-arch: build + dh_testdir + dh_testroot + dh_clean -k + dh_installdirs + chgrp games debian/tmp/usr/lib/games/nethack + chgrp -R games debian/tmp/var/lib/games/nethack + chmod -R 02775 debian/tmp/var/lib/games/nethack + - install -m 0644 -o root -g root \ - dat/{nhdat,x11tiles,pet_mark.xbm,rip.xpm,license} \ - debian/tmp/usr/lib/games/nethack ++ for file in nhdat x11tiles pet_mark.xbm rip.xpm; \ ++ do \ ++ install -m 0644 -o root -g root dat/$$file \ ++ debian/tmp/usr/lib/games/nethack; \ ++ done + + install -m 0755 -o root -g games \ + debian/nethack.sh debian/tmp/usr/games/nethack + + install -m 0755 -o root -g games \ + debian/xnethack.sh debian/tmp/usr/games/xnethack + + install -m 2755 -o root -g games src/nethack \ + debian/tmp/usr/lib/games/nethack/ + + # build the recover prog, and move it where it's supposed to be + install -o root -g games -m 2755 util/recover \ + debian/tmp/usr/lib/games/nethack/recover + + # install the dgn_comp and lev_comp programs + install -o root -g games -m 755 util/dgn_comp \ + debian/tmp/usr/lib/games/nethack/dgn_comp + + install -o root -g games -m 755 util/lev_comp \ + debian/tmp/usr/lib/games/nethack/lev_comp + + # install X11 stuff + install -m 644 debian/NetHack.ad debian/tmp/usr/X11R6/lib/X11/app-defaults/NetHack + /usr/X11R6/bin/bdftopcf -o nh10.pcf win/X11/nh10.bdf + install -m 644 nh10.pcf debian/tmp/usr/X11R6/lib/X11/fonts/misc/ + gzip debian/tmp/usr/X11R6/lib/X11/fonts/misc/nh10.pcf + - # extract spoilers - uudecode -o /dev/stdout debian/spoilers.tar.uu | tar xf - -C debian/tmp/usr/doc/nethack ++ # spoilers have been split out into nethack-spoilers + + # init.d script + install -m 755 -o root -g root debian/nethack.init \ - debian/tmp/etc/rc.boot/nethack ++ debian/tmp/etc/init.d/nethack + + # system-wide X nethack.rc file, thanks again joey :) + install -m 644 -o root -g root debian/nethackrc.x11 \ + debian/tmp/etc/nethackrc.x11 - - #dh_installdocs doc/Guidebook - cp debian/README.Debian debian/tmp/usr/doc/nethack - cp debian/copyright debian/tmp/usr/doc/nethack - cp doc/Guidebook debian/tmp/usr/doc/nethack - cp debian/changelog debian/tmp/usr/doc/nethack ++ ++ # link for /usr/lib/games/nethack/license -> /usr/share/doc/nethack/copyright ++ ln -s /usr/share/doc/nethack/copyright \ ++ debian/tmp/usr/lib/games/nethack/license ++ ++ dh_installdocs doc/Guidebook + dh_installmenu - # no can do; broken for slink - # dh_installmanpages sys/unix/spkr.7 - cp doc/*.6 debian/tmp/usr/man/man6 - cp debian/*.6 debian/tmp/usr/man/man6 - # dh_installchangelogs ++ dh_installmanpages ++ dh_installchangelogs + dh_strip + dh_compress + dh_fixperms -Xnethack - chmod 644 debian/tmp/usr/man/man6/nethack.6.gz ++ dh_suidregister + dh_installdeb + dh_shlibdeps + dh_gencontrol + dh_md5sums + dh_builddeb + +source diff: + @echo >&2 'source and diff are obsolete - use dpkg-source -b'; false + +binary: binary-indep binary-arch +.PHONY: build clean binary-indep binary-arch binary + diff --cc debian/xnethack.sh index 2d4b1fb,0000000..d1267e8 mode 100644,000000..100644 --- a/debian/xnethack.sh +++ b/debian/xnethack.sh @@@ -1,5 -1,0 +1,5 @@@ +#!/bin/sh + +set -e + - NETHACKOPTIONS=/etc/nethackrc.x11 /usr/games/nethack ++NETHACKOPTIONS=/etc/nethackrc.x11 /usr/games/nethack $* diff --cc include/config.h index fd86320,52e4314..5075e27 --- a/include/config.h +++ b/include/config.h @@@ -211,7 -43,8 +43,8 @@@ * Some combinations make no sense. See the installation document. */ #define TTY_GRAPHICS /* good old tty based graphics */ - #define X11_GRAPHICS /* X11 interface */ -/* #define X11_GRAPHICS */ /* X11 interface */ ++#define X11_GRAPHICS /* X11 interface */ + /* #define QT_GRAPHICS */ /* Qt interface */ /* * Define the default window system. This should be one that is compiled @@@ -256,7 -92,7 +92,7 @@@ * would allow: * xpmtoppm <x11tiles.xpm | pnmscale 1.25 | ppmquant 90 >x11tiles_big.xpm */ - # define USE_XPM /* Disable if you do not have the XPM library */ -/* # define USE_XPM */ /* Disable if you do not have the XPM library */ ++# define USE_XPM /* Disable if you do not have the XPM library */ # ifdef USE_XPM # define GRAPHIC_TOMBSTONE /* Use graphical tombstone (rip.xpm) */ # endif @@@ -271,21 -108,16 +108,27 @@@ #ifndef WIZARD /* allow for compile-time or Makefile changes */ # ifndef KR1ED -# define WIZARD "wizard" /* the person allowed to use the -D option */ +# define WIZARD "root" /* the person allowed to use the -D option */ # else # define WIZARD --# define WIZARD_NAME "wizard" ++# define WIZARD_NAME "root" # endif #endif - #ifdef DEBIAN - # define LOGFILE "/var/lib/games/nethack/logfile" - # define NEWS "/var/lib/games/nethack/news" -#define LOGFILE "logfile" /* larger file for debugging purposes */ -#define NEWS "news" /* the file containing the latest hack news */ ++/* ++ * Define LOGDIR here if you want your save games and log files to be ++ * stored somewhere besides where the other game files are stored. ++ */ ++#define LOGDIR "/var/lib/games/nethack" ++ ++#ifdef LOGDIR ++# define LOGFILE LOGDIR "/logfile" /* larger file for debugging purposes */ +#else - # define LOGFILE "logfile" /* larger file for debugging purposes */ - # define NEWS "news" /* the file containing the latest hack news */ ++# define LOGFILE "/logfile" +#endif + ++#define NEWS "/news" /* the file containing the latest hack news */ + /* * If COMPRESS is defined, it should contain the full path name of your * 'compress' program. Defining INTERNAL_COMP causes NetHack to do @@@ -301,13 -133,13 +144,13 @@@ #ifdef UNIX /* path and file name extension for compression program */ - /* # define COMPRESS "/usr/ucb/compress" /* Lempel-Ziv compression */ - /* # define COMPRESS_EXTENSION ".Z" /* compress's extension */ - -#define COMPRESS "/usr/bin/compress" /* Lempel-Ziv compression */ -#define COMPRESS_EXTENSION ".Z" /* compress's extension */ ++/* #define COMPRESS "/usr/bin/compress" */ /* Lempel-Ziv compression */ ++/* #define COMPRESS_EXTENSION ".Z" */ /* compress's extension */ /* An example of one alternative you might want to use: */ - # define COMPRESS "/bin/gzip" /* FSF gzip compression */ - # define COMPRESS_EXTENSION ".gz" /* normal gzip extension */ -/* #define COMPRESS "/usr/local/bin/gzip" */ /* FSF gzip compression */ -/* #define COMPRESS_EXTENSION ".gz" */ /* normal gzip extension */ ++#define COMPRESS "/bin/gzip" /* FSF gzip compression */ ++#define COMPRESS_EXTENSION ".gz" /* normal gzip extension */ #endif + #ifndef COMPRESS # define INTERNAL_COMP /* control use of NetHack's compression routines */ #endif @@@ -317,7 -149,7 +160,7 @@@ * a tar-like file, thus making a neater installation. See *conf.h * for detailed configuration. */ - #define DLB /* not supported on all platforms */ -/* #define DLB */ /* not supported on all platforms */ ++#define DLB /* not supported on all platforms */ /* * Defining INSURANCE slows down level changes, but allows games that diff --cc include/global.h index f2d30bd,b04e075..73e171e --- a/include/global.h +++ b/include/global.h @@@ -6,7 -6,7 +6,7 @@@ #define GLOBAL_H #include <stdio.h> -- ++#include "config.h" /* #define BETA /* if a beta-test copy [MRS] */ @@@ -14,25 -14,20 +14,25 @@@ * Files expected to exist in the playground directory. */ - #ifdef DEBIAN - # define RECORD "/var/lib/games/nethack/record" -#define RECORD "record" /* file containing list of topscorers */ ++#ifdef LOGDIR ++# define RECORD LOGDIR "/record" /* file containing list of topscorers */ +#else - # define RECORD "record" /* a file containing list of topscorers */ ++# define RECORD "record" /* file containing list of topscorers */ +#endif + - #define HELP "help" /* a file containing command descriptions */ - #define SHELP "hh" /* abbreviated form of the same */ - #define DEBUGHELP "wizhelp" /* a file containing debug mode cmds */ - #define RUMORFILE "rumors" /* a file with fortune cookies */ - #define ORACLEFILE "oracles" /* a file with oracular information */ - #define DATAFILE "data" /* a file giving the meaning of symbols used */ - #define CMDHELPFILE "cmdhelp" /* file telling what commands do */ - #define HISTORY "history" /* a file giving nethack's history */ - #define LICENSE "license" /* file with license information */ - #define OPTIONFILE "opthelp" /* a file explaining runtime options */ - #define OPTIONS_USED "options" /* compile-time options, for #version */ + #define HELP "help" /* file containing command descriptions */ + #define SHELP "hh" /* abbreviated form of the same */ + #define DEBUGHELP "wizhelp" /* file containing debug mode cmds */ + #define RUMORFILE "rumors" /* file with fortune cookies */ + #define ORACLEFILE "oracles" /* file with oracular information */ + #define DATAFILE "data" /* file giving the meaning of symbols used */ + #define CMDHELPFILE "cmdhelp" /* file telling what commands do */ + #define HISTORY "history" /* file giving nethack's history */ + #define LICENSE "license" /* file with license information */ + #define OPTIONFILE "opthelp" /* file explaining runtime options */ + #define OPTIONS_USED "options" /* compile-time options, for #version */ - #define LEV_EXT ".lev" /* extension for special level files */ + #define LEV_EXT ".lev" /* extension for special level files */ /* Assorted definitions that may depend on selections in config.h. */ diff --cc include/unixconf.h index 06cca75,a259faf..f0b33cf --- a/include/unixconf.h +++ b/include/unixconf.h @@@ -6,6 -6,6 +6,8 @@@ #ifndef UNIXCONF_H #define UNIXCONF_H ++#include "config.h" ++ /* * Some include files are in a different place under SYSV * BSD SYSV @@@ -30,18 -32,25 +34,25 @@@ /* define any of the following that are appropriate */ --#define SVR4 /* use in addition to SYSV for System V Release 4 */ ++/* #define SVR4 */ /* use in addition to SYSV for System V Release 4 */ + /* including Solaris 2+ */ #define NETWORK /* if running on a networked system */ /* e.g. Suns sharing a playground through NFS */ - /* #define SUNOS4 /* SunOS 4.x */ - #define LINUX /* Another Unix clone */ - /* #define GENIX /* Yet Another Unix Clone */ - /* #define HISX /* Bull Unix for XPS Machines */ - /* #define BOS /* Bull Open Software - Unix for DPX/2 Machines */ - /* #define UNIXPC /* use in addition to SYSV for AT&T 7300/3B1 */ - /* #define AIX_31 /* In AIX 3.1 (IBM RS/6000) use BSD ioctl's to gain + /* #define SUNOS4 */ /* SunOS 4.x */ -/* #define LINUX */ /* Another Unix clone */ ++#define LINUX /* Another Unix clone */ + /* #define GENIX */ /* Yet Another Unix Clone */ + /* #define HISX */ /* Bull Unix for XPS Machines */ + /* #define BOS */ /* Bull Open Software - Unix for DPX/2 Machines */ + /* #define UNIXPC */ /* use in addition to SYSV for AT&T 7300/3B1 */ + /* #define AIX_31 */ /* In AIX 3.1 (IBM RS/6000) use BSD ioctl's to gain * job control (note that AIX is SYSV otherwise) * Also define this for AIX 3.2 */ + #define TERMINFO /* uses terminfo rather than termcap */ + /* Should be defined for most SYSV, SVR4 (including + * Solaris 2+), HPUX, and Linux systems. In + * particular, it should NOT be defined for the UNIXPC + * unless you remove the use of the shared library in + * the Makefile */ #define TEXTCOLOR /* Use System V r3.2 terminfo color support */ /* and/or ANSI color support on termcap systems */ /* and/or X11 color */ @@@ -83,9 -93,9 +95,13 @@@ * Ralf Brown, 7/26/89 (from v2.3 hack of 10/10/88) */ - /* #define NO_FILE_LINKS /* if no hard links */ - #define LOCKDIR "/var/lib/games/nethack" /* where to put locks */ - + /* #define NO_FILE_LINKS */ /* if no hard links */ + /* #define LOCKDIR "/usr/games/lib/nethackdir" */ /* where to put locks */ - ++#ifdef LOGDIR ++# define LOCKDIR LOGDIR ++#else ++/* # define LOCKDIR "/usr/games/lib/nethackdir" */ ++#endif /* * Define DEF_PAGER as your default pager, e.g. "/bin/cat" or "/usr/ucb/more" @@@ -241,11 -251,7 +257,11 @@@ #include <time.h> #endif - #ifdef DEBIAN - # define HLOCK "/var/lib/games/nethack/perm" -#define HLOCK "perm" /* an empty file used for locking purposes */ ++#ifdef LOGDIR ++# define HLOCK LOGDIR "/perm" /* an empty file used for locking purposes */ +#else - # define HLOCK "perm" /* an empty file used for locking purposes */ ++# define HLOCK "perm" /* an empty file used for locking purposes */ +#endif #ifndef REDO #define Getchar nhgetch diff --cc src/drawing.c index 2c25298,df7eded..768f2fd --- a/src/drawing.c +++ b/src/drawing.c @@@ -820,10 -843,10 +843,10 @@@ boolean is_rlevel ) oc_syms[i] = IBM_r_oc_syms[i]; else -#endif /* ASCIIGRAPH */ +#endif /* ASCIIGRAPH && !LINUX */ oc_syms[i] = r_oc_syms[i]; } - #if defined(MSDOS) + #if defined(MSDOS) && defined(USE_TILES) if (iflags.grmode) tileview(FALSE); #endif } else { diff --cc src/files.c index 4e12cbe,4eda31f..5e9840c --- a/src/files.c +++ b/src/files.c @@@ -29,26 -29,26 +29,35 @@@ extern int errno # define O_BINARY 0 #endif - #ifdef MFLOPPY -#if !defined(MFLOPPY) && !defined(VMS) && !defined(WIN32) ++#if !defined(MFLOPPY) && !defined(VMS) && !defined(WIN32) && !defined(LOGDIR) + char bones[] = "bonesnn.xxx"; + char lock[PL_NSIZ+14] = "1lock"; /* long enough for uid+name+.99 */ + #else + # if defined(MFLOPPY) char bones[FILENAME]; /* pathname of bones files */ char lock[FILENAME]; /* pathname of level files */ - #else - # ifdef VMS + # endif + # if defined(VMS) char bones[] = "bonesnn.xxx;1"; char lock[PL_NSIZ+17] = "1lock"; /* long enough for _uid+name+.99;1 */ - # else - # ifdef DEBIAN - char bones[] = "/var/lib/games/nethack/bonesnn.xxx"; - char lock[255] = "/var/lib/games/nethack/1lock"; - # else + # endif + # if defined(WIN32) char bones[] = "bonesnn.xxx"; - char lock[PL_NSIZ+14] = "1lock"; /* long enough for uid+name+.99 */ - # endif - # endif /* VMS */ - #endif /* MFLOPPY */ + char lock[PL_NSIZ+25]; /* long enough for username+.+name+.99 */ + # endif ++# if defined(LOGDIR) ++char bones[] = LOGDIR "/bonesnn.xxx"; ++char lock[sizeof(LOGDIR)+PL_NSIZ+15] = LOGDIR "/1lock"; ++ /* long enough for /+uid+name+.99 */ ++# endif + #endif #if defined(UNIX) || defined(__BEOS__) ++# if defined(LOGDIR) /* /save/99999player.e */ ++#define SAVESIZE (PL_NSIZ + 14 + sizeof(LOGDIR)) ++# else #define SAVESIZE (PL_NSIZ + 13) /* save/99999player.e */ ++# endif /* LOGDIR */ #else # ifdef VMS #define SAVESIZE (PL_NSIZ + 22) /* [.save]<uid>player.e;1 */ @@@ -250,12 -278,12 +287,18 @@@ set_bonesfile_name(file, lev char *file; d_level *lev; { - char *dptr = rindex(file, '.'); s_level *sptr; + char *dptr; + - Sprintf(file, "bon%c%s", dungeons[lev->dnum].boneid, - In_quest(lev) ? urole.filecode : "0"); ++#ifdef LOGDIR ++ Sprintf(file, "%s/bon%c%s", LOGDIR, dungeons[lev->dnum].boneid, ++ In_quest(lev) ? urole.filecode : "0"); ++#else ++ Sprintf(file, "bon%c%s", dungeons[lev->dnum].boneid, ++ In_quest(lev) ? urole.filecode : "0"); ++#endif /* LOGDIR */ + - if (!dptr) dptr = eos(file); - *(dptr-2) = dungeons[lev->dnum].boneid; - *(dptr-1) = In_quest(lev) ? pl_character[0] : '0'; + dptr = eos(file); if ((sptr = Is_special(lev)) != 0) Sprintf(dptr, ".%c", sptr->boneid); else @@@ -430,16 -467,15 +482,20 @@@ set_savefile_name( regularize(SAVEF+i); } Strcat(SAVEF, ".sav"); - # else - # ifdef DEBIAN - Sprintf(SAVEF, "/var/lib/games/nethack/save/%d%s", (int)getuid(), plname); - regularize(SAVEF+28); /* avoid . or / in name */ + # else -# if defined(WIN32) - Sprintf(SAVEF,"%s-%s.NetHack-saved-game",get_username(0), plname); ++# if defined(LOGDIR) ++ Sprintf(SAVEF, "%s/save/%d%s", LOGDIR, (int)getuid(), plname); ++ regularize(SAVEF + sizeof(LOGDIR) + 5); # else - Sprintf(SAVEF, "save/%d%s", (int)getuid(), plname); - regularize(SAVEF+5); /* avoid . or / in name */ - # endif /* DEBIAN */ ++# if defined(WIN32) ++ Sprintf(SAVEF,"%s-%s.NetHack-saved-game",get_username(0), plname); ++# else + Sprintf(SAVEF, "save/%d%s", (int)getuid(), plname); + regularize(SAVEF+5); /* avoid . or / in name */ -# endif /* WIN32 */ ++# endif /* WIN32 */ ++# endif /* LOGDIR */ # endif /* MICRO */ - #endif /* VMS */ + #endif /* VMS */ } #ifdef INSURANCE diff --cc src/mail.c index cb9e72a,f8982bf..e16db7b --- a/src/mail.c +++ b/src/mail.c @@@ -65,14 -66,18 +66,18 @@@ static char *mailbox = (char *)0 static long laststattime; # ifdef AMS /* Just a placeholder for AMS */ - # define MAILPATH "/dev/null" + # define MAILPATH "/dev/null" # else - # if defined(BSD) || defined(ULTRIX) - # define MAILPATH "/usr/spool/mail/" - # endif - # if defined(SYSV) || defined(HPUX) - # define MAILPATH "/usr/mail/" - # endif + # ifdef LINUX -# define MAILPATH "/var/spool/mail" ++# define MAILPATH "/var/spool/mail/" + # else + # if defined(BSD) || defined(ULTRIX) + # define MAILPATH "/usr/spool/mail/" + # endif + # if defined(SYSV) || defined(HPUX) + # define MAILPATH "/usr/mail/" + # endif + # endif /* LINUX */ # endif /* AMS */ void diff --cc sys/share/unixtty.c index 7129683,deeaab1..c364056 --- a/sys/share/unixtty.c +++ b/sys/share/unixtty.c @@@ -355,7 -355,7 +355,6 @@@ init_sco_cons( if (!strcmp(windowprocs.name, "tty") && sco_flag_console) { atexit(sco_mapon); sco_mapoff(); -- switch_graphics(IBM_GRAPHICS); # ifdef TEXTCOLOR if (has_colors()) iflags.use_color = TRUE; diff --cc sys/unix/Makefile.src index da48b14,45048e6..1909d23 --- a/sys/unix/Makefile.src +++ b/sys/unix/Makefile.src @@@ -109,8 -112,8 +112,8 @@@ SYSOBJ = ioctl.o unixmain.o unixtty.o u # flags for Linux # compile normally --# CFLAGS = -O2 -fomit-frame-pointer -I../include -I/usr/X11/include --# LFLAGS = -L/usr/X11/lib ++CFLAGS = -O2 -fomit-frame-pointer -I../include -I/usr/X11R6/include ++LFLAGS = -L/usr/X11R6/lib # OR compile backwards compatible a.out format # CFLAGS = -O2 -b i486-linuxaout -fomit-frame-pointer -I../include -I/usr/X11/include # LFLAGS = -b i486-linuxaout -L/usr/X11/lib @@@ -124,9 -132,14 +132,14 @@@ # flags for debugging: # CFLAGS = -g -I../include - CFLAGS = -O2 -I../include -I/usr/X11R6/include - LFLAGS = -s -L/usr/X11R6/lib -CFLAGS = -O -I../include -LFLAGS = ++#CFLAGS = -O -I../include ++#LFLAGS = + # Only used for Qt interface (other interfaces are standard C) + CXXFLAGS = -g $(CFLAGS) -I. -I$(QTDIR)/include + # Qt is C++, so define the compiler and linker thus required: + #CXX=g++ + #LD=g++ # Set the WINSRC, WINOBJ, and WINLIB lines to correspond to your desired # combination of windowing systems. Also set windowing systems in config.h. @@@ -145,9 -158,15 +158,15 @@@ WINX11SRC = ../win/X11/Window.c ../win/ WINX11OBJ = Window.o dialogs.o winX.o winmap.o winmenu.o winmesg.o \ winmisc.o winstat.o wintext.o winval.o tile.o # + # Files for a Qt port + # + WINQTSRC = ../win/Qt/qt_win.cpp ../win/Qt/qt_clust.cpp + WINQTOBJ = qt_win.o qt_clust.o tile.o + + # # -WINSRC = $(WINTTYSRC) -WINOBJ = $(WINTTYOBJ) +WINSRC = $(WINTTYSRC) $(WINX11SRC) +WINOBJ = $(WINTTYOBJ) $(WINX11OBJ) # on some systems the termcap library is in -ltermcap or -lcurses # on 386 Xenix, the -ltermlib tputs() seems not to work; use -lcurses instead @@@ -160,20 -179,27 +179,27 @@@ # # libraries for tty ports # WINTTYLIB = -ltermcap - WINTTYLIB = -lcurses + # WINTTYLIB = -lcurses # WINTTYLIB = -lcurses16 --# WINTTYLIB = -lncurses -WINTTYLIB = -ltermlib ++WINTTYLIB = -lncurses +# WINTTYLIB = -ltermlib # # libraries for X11 # If USE_XPM is defined in config.h, you will also need -lXpm here. -WINX11LIB = -lXaw -lXmu -lXext -lXt -lX11 +# WINX11LIB = -lXaw -lXmu -lXext -lXt -lX11 # WINX11LIB = -lXaw -lXmu -lXt -lX11 --# WINX11LIB = -lXaw -lXmu -lXext -lXt -lXpm -lX11 -lm - WINX11LIB = -lXaw -lXmu -lXpm -lXext -lXt -lX11 -lSM -lICE # Linux 2.0 ++WINX11LIB = -lXaw -lXmu -lXext -lXt -lXpm -lX11 -lm + # WINX11LIB = -lXaw -lXmu -lXpm -lXext -lXt -lX11 -lSM -lICE -lm # BSD/OS 2.0 + # + # libraries for Qt + WINQTLIB = -L$(QTDIR)/lib -lqt + # + # libraries for KDE (with Qt) + WINKDELIB = -lkdecore -lkdeui -lXext # # + -WINLIB = $(WINTTYLIB) +WINLIB = $(WINTTYLIB) $(WINX11LIB) # any other strange libraries your system needs (for Sysunix only -- the more # specialized targets should already be right) diff --cc sys/unix/Makefile.top index 3fbd419,20fb022..93e036c --- a/sys/unix/Makefile.top +++ b/sys/unix/Makefile.top @@@ -32,13 -33,13 +33,13 @@@ DIRPERM = 075 # therefore there should not be anything in GAMEDIR that you want to keep # (if there is, you'll have to do the installation by hand or modify the # instructions) - GAMEDIR = /usr/games/lib/$(GAME)dir - SHELLDIR = /usr/games + GAMEDIR = $(PREFIX)/games/lib/$(GAME)dir + SHELLDIR = $(PREFIX)/games - # per discussion in Install.X11 + # per discussion in Install.X11 and Install.Qt -VARDATND = +# VARDATND = # VARDATND = x11tiles pet_mark.xbm -# VARDATND = x11tiles pet_mark.xbm rip.xpm +VARDATND = x11tiles pet_mark.xbm rip.xpm VARDATD = data oracles options quest.dat rumors VARDAT = $(VARDATD) $(VARDATND) @@@ -55,6 -56,6 +56,11 @@@ CHOWN = chown CHGRP = chgrp ++# If LOGDIR is defined, we use that, not GAMEDIR, to store files. ++# This is useful for systems that shouldn't be writing into /usr. ++# Note that you need to define this in config.h as well! ++# LOGDIR = /var/lib/games/$(GAME) ++ # # end of configuration # @@@ -165,8 -167,8 +172,13 @@@ dofiles-nodlb chmod $(FILEPERM) $(DAT) ) update: $(GAME) $(VARDAT) dungeon spec_levs ++ if [ "$(LOGDIR)" ]; then; \ ++ DATADIR=$(LOGDIR); \ ++ else; \ ++ DATADIR=$(GAMEDIR); \ ++ fi # (don't yank the old version out from under people who're playing it) -- -mv $(GAMEDIR)/$(GAME) $(GAMEDIR)/$(GAME).old ++ -mv $(DATADIR)/$(GAME) $(DATADIR)/$(GAME).old # quest.dat is also kept open and has the same problems over NFS # (quest.dat may be inside nhdat if dlb is in use) -mv $(GAMEDIR)/quest.dat $(GAMEDIR)/quest.dat.old @@@ -174,25 -176,25 +186,30 @@@ # set up new versions of the game files ( $(MAKE) dofiles ) # touch time-sensitive files -- -touch -c $(GAMEDIR)/bones* $(GAMEDIR)/?lock* $(GAMEDIR)/wizard* -- -touch -c $(GAMEDIR)/save/* -- touch $(GAMEDIR)/perm $(GAMEDIR)/record ++ -touch -c $(DATADIR)/bones* $(DATADIR)/?lock* $(DATADIR)/wizard* ++ -touch -c $(DATADIR)/save/* ++ touch $(DATADIR)/perm $(DATADIR)/record # and a reminder @echo You may also want to install the man pages via the doc Makefile. install: $(GAME) $(VARDAT) dungeon spec_levs # set up the directories -mkdir $(SHELLDIR) -- -rm -rf $(GAMEDIR) -- -mkdir $(GAMEDIR) $(GAMEDIR)/save -- -$(CHOWN) $(GAMEUID) $(GAMEDIR) $(GAMEDIR)/save -- $(CHGRP) $(GAMEGRP) $(GAMEDIR) $(GAMEDIR)/save -- chmod $(DIRPERM) $(GAMEDIR) $(GAMEDIR)/save ++ if [ "$(LOGDIR)" ]; then; \ ++ DATADIR=$(LOGDIR); \ ++ else; \ ++ DATADIR=$(GAMEDIR); \ ++ fi ++ -rm -rf $(DATADIR) ++ -mkdir $(DATADIR) $(DATADIR)/save ++ -$(CHOWN) $(GAMEUID) $(DATADIR) $(DATADIR)/save ++ $(CHGRP) $(GAMEGRP) $(DATADIR) $(DATADIR)/save ++ chmod $(DIRPERM) $(DATADIR) $(DATADIR)/save # set up the game files ( $(MAKE) dofiles ) # set up some additional files -- touch $(GAMEDIR)/perm $(GAMEDIR)/record $(GAMEDIR)/logfile -- -( cd $(GAMEDIR) ; $(CHOWN) $(GAMEUID) perm record logfile ; \ ++ touch $(DATADIR)/perm $(DATADIR)/record $(DATADIR)/logfile ++ -( cd $(DATADIR) ; $(CHOWN) $(GAMEUID) perm record logfile ; \ $(CHGRP) $(GAMEGRP) perm record logfile ; \ chmod $(FILEPERM) perm record logfile ) # and a reminder diff --cc sys/unix/Makefile.utl index ce2144c,84eda9b..fe79f5e --- a/sys/unix/Makefile.utl +++ b/sys/unix/Makefile.utl @@@ -64,8 -67,8 +67,8 @@@ # flags for Linux # compile normally --# CFLAGS = -O2 -fomit-frame-pointer -I../include -I/usr/X11/include --# LFLAGS = -L/usr/X11/lib ++CFLAGS = -O2 -fomit-frame-pointer -I../include -I/usr/X11R6/include ++LFLAGS = -L/usr/X11R6/lib # OR compile backwards compatible a.out format # CFLAGS = -O2 -b i486-linuxaout -fomit-frame-pointer -I../include -I/usr/X11/include # LFLAGS = -b i486-linuxaout -L/usr/X11/lib @@@ -78,17 -84,17 +84,17 @@@ # flags for debugging: # CFLAGS = -g -I../include - CFLAGS = -O2 -I../include - LFLAGS = -s -CFLAGS = -O -I../include -LFLAGS = ++#CFLAGS = -O -I../include ++#LFLAGS = # yacc/lex programs to use to generate *_comp.h, *_lex.c, and *_yacc.c. # if, instead of yacc/lex you have bison/flex, comment/uncomment the following. - # YACC = yacc - # LEX = lex -YACC = yacc -LEX = lex -# YACC = bison -y ++#YACC = yacc ++#LEX = lex +YACC = bison -y # YACC = byacc -# LEX = flex +LEX = flex # these are the names of the output files from YACC/LEX. Under MS-DOS # and similar systems, they may differ diff --cc sys/unix/unixmain.c index f10f6b8,f5b0aa5..a668952 --- a/sys/unix/unixmain.c +++ b/sys/unix/unixmain.c @@@ -185,22 -174,14 +184,23 @@@ char *argv[] (void) signal(SIGQUIT,SIG_IGN); (void) signal(SIGINT,SIG_IGN); if(!locknum) - #ifdef DEBIAN - Sprintf(lock, "/var/lib/games/nethack/%d%s", (int)getuid(), plname); ++#ifdef LOGDIR ++ Sprintf(lock, "%s/%d%s", LOGDIR, (int)getuid(), plname); +#else - Sprintf(lock, "%d%s", (int)getuid(), plname); - #endif + Sprintf(lock, "%d%s", (int)getuid(), plname); ++#endif /* LOGDIR */ ++ getlock(); #ifdef WIZARD } else { - #ifdef DEBIAN - Sprintf(lock, "/var/lib/games/nethack/%d%s", (int)getuid(), plname); ++#ifdef LOGDIR ++ Sprintf(lock, "%s%/d%s", LOGDIR, (int)getuid(), plname); +#else Sprintf(lock, "%d%s", (int)getuid(), plname); - #endif ++#endif /* LOGDIR */ getlock(); } - #endif /* WIZARD /**/ + #endif /* WIZARD */ dlb_init(); /* must be before newgame() */ diff --cc sys/unix/unixunix.c index 6a9b7f2,43d2c04..d3a5a21 --- a/sys/unix/unixunix.c +++ b/sys/unix/unixunix.c @@@ -184,22 -180,15 +184,23 @@@ getlock( wait_synch(); error("%s", ""); } - #ifdef DEBIAN - regularize(lock+23); + ++#ifdef LOGDIR ++ regularize(lock + sizeof(LOGDIR)); /* sorry about this hack */ +#else regularize(lock); +#endif set_levelfile_name(lock, 0); if(locknum) { if(locknum > 25) locknum = 25; do { - #ifdef DEBIAN - lock[23] = 'a' + i++; ++#ifdef LOGDIR ++ lock[sizeof(LOGDIR)] = 'a' + i++; +#else lock[0] = 'a' + i++; +#endif if((fd = open(lock, 0)) == -1) { if(errno == ENOENT) goto gotlock; /* no such file */ diff --cc util/recover.c index 0fe85f5,63a9fda..dbb1995 --- a/util/recover.c +++ b/util/recover.c @@@ -27,7 -30,7 +30,11 @@@ void FDECL(copy_bytes, (int,int)) #define Close (void)close #ifdef UNIX ++# ifdef LOGDIR /* LOGDIR/save/99999player.e */ ++#define SAVESIZE (PL_NSIZ + 14 + sizeof(LOGDIR)) ++# else #define SAVESIZE (PL_NSIZ + 13) /* save/99999player.e */ ++# endif /* LOGDIR */ #else # ifdef VMS #define SAVESIZE (PL_NSIZ + 22) /* [.save]<uid>player.e;1 */ @@@ -85,21 -98,17 +102,25 @@@ char *argv[] } argno++; } - - if (!dir) dir = getenv("NETHACKDIR"); - if (!dir) dir = getenv("HACKDIR"); - # if defined(SECURE) && !defined(VMS) + #if defined(SECURE) && !defined(VMS) if (dir -# ifdef HACKDIR ++# ifdef LOGDIR ++ && strcmp(dir, LOGDIR) ++# else +# ifdef HACKDIR && strcmp(dir, HACKDIR) - # endif -# endif ++# endif /* HACKDIR */ ++# endif /* LOGDIR */ ) { (void) setgid(getgid()); (void) setuid(getuid()); } - # endif /* SECURE && !VMS */ - #endif /* DEBIAN */ + #endif /* SECURE && !VMS */ + ++#ifdef LOGDIR ++ if (!dir) dir = LOGDIR; ++#endif + #ifdef HACKDIR if (!dir) dir = HACKDIR; #endif diff --cc win/tty/termcap.c index 10b85b0,cb253ab..db269ab --- a/win/tty/termcap.c +++ b/win/tty/termcap.c @@@ -828,10 -828,9 +828,9 @@@ init_hilite( hilites[c] = HI; hilites[CLR_GRAY] = hilites[NO_COLOR] = (char *)0; - if (tgetnum("Co") < 8) - return; - if ((setf = tgetstr("Sf", (char **)0)) == (char *)0 - && (setf = tgetstr("AF", (char **)0)) == (char *)0) + if (tgetnum("Co") < 8 - || ((setf = tgetstr("Sf", (char **)0)) == (char *)0 - && (setf = tgetstr("AF", (char **)0)) == (char *)0)) ++ || ((setf = tgetstr("AF", (char **)0)) == (char *)0 ++ && (setf = tgetstr("Sf", (char **)0)) == (char *)0)) return; for (c = 0; c < CLR_MAX / 2; c++) { -- Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/nethack.git _______________________________________________ Pkg-games-commits mailing list [email protected] http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-games-commits

