From 6ac681b5fa6d775fee8c57196eaaa56e4caa7ac7 Mon Sep 17 00:00:00 2001 From: Pasi Kallinen Date: Sat, 29 Dec 2018 07:19:18 +0200 Subject: [PATCH] X11: default to XPM-format tile file and rip screen People have been wondering how to change the tiles on the X11 version, and the old default of NetHack-specific binary tile data isn't directly editable with image editing tools. Also show in the #version info if xpm and graphic rip are enabled. --- doc/fixes36.2 | 1 + sys/unix/Makefile.src | 2 +- sys/unix/hints/linux-x11 | 7 ++++++- util/makedefs.c | 6 ++++++ 4 files changed, 14 insertions(+), 2 deletions(-) diff --git a/doc/fixes36.2 b/doc/fixes36.2 index 1a64ce23e..7e1b29810 100644 --- a/doc/fixes36.2 +++ b/doc/fixes36.2 @@ -443,6 +443,7 @@ X11: enable menu [cancel] button for PICK_NONE menus X11: text popups on OSX wouldn't accept keyboard input unless the 'autofocus' resource was enabled; most noticeable when trying to dismiss 'things that are here' while walking over object piles +X11: default to using XPM format tile file and rip screen General New Features diff --git a/sys/unix/Makefile.src b/sys/unix/Makefile.src index 3150bbdd4..40892e1ed 100644 --- a/sys/unix/Makefile.src +++ b/sys/unix/Makefile.src @@ -287,7 +287,7 @@ WINBEOBJ = # # 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 -lm # BSD/OS 2.0 diff --git a/sys/unix/hints/linux-x11 b/sys/unix/hints/linux-x11 index 05d7e7304..d8e29aa85 100644 --- a/sys/unix/hints/linux-x11 +++ b/sys/unix/hints/linux-x11 @@ -35,7 +35,7 @@ WINLIB = $(WINX11LIB) VARDATND = x11tiles NetHack.ad pet_mark.xbm pilemark.xbm -#WINTTYLIB=-lcurses +WINX11LIB = -lXaw -lXmu -lXext -lXt -lX11 CHOWN=true CHGRP=true @@ -43,4 +43,9 @@ VARDIRPERM = 0755 VARFILEPERM = 0600 GAMEPERM = 0755 +# Use XPM format tile file +CFLAGS+=-DUSE_XPM +WINX11LIB+=-lXpm +VARDATND+=rip.xpm + # note: needs libxt-dev libxaw7-dev libx11-dev bdftopcf diff --git a/util/makedefs.c b/util/makedefs.c index 29a528f01..44a04a4ff 100644 --- a/util/makedefs.c +++ b/util/makedefs.c @@ -1674,6 +1674,12 @@ static const char *build_opts[] = { "terminal capability library", #endif #endif +#ifdef USE_XPM + "tile_file in XPM format", +#endif +#ifdef GRAPHIC_TOMBSTONE + "graphical RIP screen", +#endif #ifdef TIMED_DELAY "timed wait for display effects", #endif