--- /dev/null
+diff -ruN nethack-3.4.0.orig/include/config.h 2/include/config.h
+--- nethack-3.4.0.orig/include/config.h Mon Mar 25 23:47:30 2002
++++ 2/include/config.h Tue Mar 26 20:35:52 2002
+@@ -44,7 +44,7 @@
+ */
+ #define TTY_GRAPHICS /* good old tty based graphics */
+ /* #define X11_GRAPHICS */ /* X11 interface */
+-/* #define QT_GRAPHICS */ /* Qt interface */
++#define QT_GRAPHICS /* Qt interface */
+ /* #define GNOME_GRAPHICS */ /* Gnome interface */
+ /* #define MSWIN_GRAPHICS */ /* Windows NT, CE, Graphics */
+
+@@ -136,6 +136,7 @@
+ * LOGFILE and NEWS refer to files in the playground.
+ */
+
++#if 0
+ #ifndef WIZARD /* allow for compile-time or Makefile changes */
+ # ifndef KR1ED
+ # define WIZARD "wizard" /* the person allowed to use the -D option */
+@@ -144,6 +145,7 @@
+ # define WIZARD_NAME "wizard"
+ # endif
+ #endif
++#endif
+
+ #define LOGFILE "logfile" /* larger file for debugging purposes */
+ #define NEWS "news" /* the file containing the latest hack news */
+@@ -163,8 +165,8 @@
+
+ #ifdef UNIX
+ /* path and file name extension for compression program */
+-#define COMPRESS "/usr/bin/compress" /* Lempel-Ziv compression */
+-#define COMPRESS_EXTENSION ".Z" /* compress's extension */
++#define COMPRESS "/bin/gzip" /* Lempel-Ziv compression */
++#define COMPRESS_EXTENSION ".gz" /* compress's extension */
+ /* An example of one alternative you might want to use: */
+ /* #define COMPRESS "/usr/local/bin/gzip" */ /* FSF gzip compression */
+ /* #define COMPRESS_EXTENSION ".gz" */ /* normal gzip extension */
+@@ -179,7 +181,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 */
+
+ /*
+ * Defining INSURANCE slows down level changes, but allows games that
+@@ -201,7 +203,7 @@
+ # ifdef __APPLE__
+ # define HACKDIR "nethackdir" /* nethack directory */
+ # else
+-# define HACKDIR "/usr/games/lib/nethackdir"
++# define HACKDIR "/usr/share/nethack"
+ # endif
+ # endif
+
+@@ -298,7 +300,7 @@
+ * functions that have been macroized.
+ */
+
+-/* #define VISION_TABLES */ /* use vision tables generated at compile time */
++#define VISION_TABLES /* use vision tables generated at compile time */
+ #ifndef VISION_TABLES
+ # ifndef NO_MACRO_CPATH
+ # define MACRO_CPATH /* use clear_path macros instead of functions */
+diff -ruN nethack-3.4.0.orig/include/unixconf.h 2/include/unixconf.h
+--- nethack-3.4.0.orig/include/unixconf.h Mon Mar 25 23:47:30 2002
++++ 2/include/unixconf.h Tue Mar 26 20:44:41 2002
+@@ -32,12 +32,12 @@
+
+
+ /* 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 LINUX /* Another Unix clone */
+ /* #define CYGWIN32 */ /* Unix on Win32 -- use with case sensitive defines */
+ /* #define GENIX */ /* Yet Another Unix Clone */
+ /* #define HISX */ /* Bull Unix for XPS Machines */
+@@ -102,7 +102,7 @@
+ * If you want the static parts of your playground on a read-only file
+ * system, define VAR_PLAYGROUND to be where the variable parts are kept.
+ */
+-/* #define VAR_PLAYGROUND "/var/lib/games/nethack" */
++#define VAR_PLAYGROUND "/var/games/nethack"
+
+
+ /*
+@@ -132,7 +132,7 @@
+ * "extra output" method is used, but not all systems provide access to
+ * a fine-grained timer.
+ */
+-/* #define TIMED_DELAY */ /* usleep() */
++#define TIMED_DELAY /* usleep() */
+ #endif
+
+ /*
--- /dev/null
+diff -ruN nethack-3.4.0.orig/sys/unix/Makefile.src 2/sys/unix/Makefile.src
+--- nethack-3.4.0.orig/sys/unix/Makefile.src Mon Mar 25 23:47:32 2002
++++ 2/sys/unix/Makefile.src Tue Mar 26 21:29:11 2002
+@@ -150,7 +150,7 @@
+ # The Qt and Be window systems are written in C++, while the rest of
+ # NetHack is standard C. If using Qt, uncomment the LD line here to get
+ # the C++ libraries linked in.
+-CXXFLAGS = $(CFLAGS) -I. -I$(QTDIR)/include
++CXXFLAGS = $(CFLAGS) -I. -I/usr/X11R6/include/qt
+ CXX=g++
+ #LD=g++
+
+@@ -203,8 +203,8 @@
+
+ #
+ #
+-WINSRC = $(WINTTYSRC)
+-WINOBJ = $(WINTTYOBJ)
++WINSRC = $(WINTTYSRC) $(WINQTSRC)
++WINOBJ = $(WINTTYOBJ) $(WINQTOBJ)
+
+ # on some systems the termcap library is in -ltermcap or -lcurses
+ # on 386 Xenix, the -ltermlib tputs() seems not to work; use -lcurses instead
+@@ -219,8 +219,8 @@
+ # WINTTYLIB = -ltermcap
+ # 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.
+@@ -230,7 +230,7 @@
+ # WINX11LIB = -lXaw -lXmu -lXpm -lXext -lXt -lX11 -lSM -lICE -lm # BSD/OS 2.0
+ #
+ # libraries for Qt
+-WINQTLIB = -L$(QTDIR)/lib -lqt
++WINQTLIB = -L/usr/X11R6/lib -lqt
+ #
+ # libraries for KDE (with Qt)
+ WINKDELIB = -lkdecore -lkdeui -lXext
+@@ -244,7 +244,7 @@
+ # libraries for BeOS
+ WINBELIB = -lbe
+
+-WINLIB = $(WINTTYLIB)
++WINLIB = $(WINTTYLIB) $(WINQTLIB)
+
+ # any other strange libraries your system needs (for Sysunix only -- the more
+ # specialized targets should already be right)
+@@ -450,13 +450,13 @@
+
+ # Qt windowport meta-object-compiler output
+ qt_kde0.moc: ../include/qt_kde0.h
+- $(QTDIR)/bin/moc ../include/qt_kde0.h > qt_kde0.moc
++ /usr/X11R6/bin/moc ../include/qt_kde0.h > qt_kde0.moc
+
+ qt_win.moc: ../include/qt_win.h
+- $(QTDIR)/bin/moc ../include/qt_win.h > qt_win.moc
++ /usr/X11R6/bin/moc ../include/qt_win.h > qt_win.moc
+
+ qttableview.moc: ../include/qttableview.h
+- $(QTDIR)/bin/moc ../include/qttableview.h > qttableview.moc
++ /usr/X11R6/bin/moc ../include/qttableview.h > qttableview.moc
+
+ $(MAKEDEFS): ../util/makedefs.c $(CONFIG_H) ../include/permonst.h \
+ ../include/objclass.h ../include/monsym.h \
+diff -ruN nethack-3.4.0.orig/sys/unix/Makefile.top 2/sys/unix/Makefile.top
+--- nethack-3.4.0.orig/sys/unix/Makefile.top Mon Mar 25 23:47:32 2002
++++ 2/sys/unix/Makefile.top Tue Mar 26 21:28:10 2002
+@@ -14,7 +14,7 @@
+ # MAKE = make
+
+ # make NetHack
+-PREFIX = /usr
++PREFIX = $(DESTDIR)/usr
+ GAME = nethack
+ # GAME = nethack.prg
+ GAMEUID = games
+@@ -35,14 +35,14 @@
+ # 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 = $(PREFIX)/games/lib/$(GAME)dir
+-VARDIR = $(GAMEDIR)
++GAMEDIR = $(PREFIX)/share/nethack
++VARDIR = $(DESTDIR)/var/games/nethack
+ SHELLDIR = $(PREFIX)/games
+
+ # 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
+ # for Atari/Gem
+ # VARDATND = nh16.img title.img GEM_RSC.RSC rip.img
+ # for BeOS
+@@ -64,8 +64,8 @@
+ # other permission-related reasons. If that happens, you may want to set the
+ # command to "true", which is a no-op. Note that disabling chown or chgrp
+ # will only work if setuid (or setgid) behavior is not desired or required.
+-CHOWN = chown
+-CHGRP = chgrp
++CHOWN = true
++CHGRP = true
+
+ #
+ # end of configuration
+@@ -177,6 +177,7 @@
+ -rm -f $(SHELLDIR)/$(GAME)
+ sed -e 's;/usr/games/lib/nethackdir;$(GAMEDIR);' \
+ -e 's;HACKDIR/nethack;HACKDIR/$(GAME);' \
++ -e 's;$(DESTDIR);;' \
+ < sys/unix/nethack.sh \
+ > $(SHELLDIR)/$(GAME)
+ # set up their permissions
+diff -ruN nethack-3.4.0.orig/sys/unix/Makefile.utl 2/sys/unix/Makefile.utl
+--- nethack-3.4.0.orig/sys/unix/Makefile.utl Mon Mar 25 23:47:32 2002
++++ 2/sys/unix/Makefile.utl Tue Mar 26 21:28:10 2002
+@@ -97,11 +97,11 @@
+
+ # 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 = 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