Merge branch 'master' into win32-x64-working
Conflicts: src/display.c
This commit is contained in:
3
Files
3
Files
@@ -177,7 +177,8 @@ snd86unx.shr
|
||||
|
||||
sys/unix/hints:
|
||||
(files for configuring UNIX NetHack versions)
|
||||
linux linux-x11 macosx macos-x11 unix
|
||||
linux linux-x11 macosx macosx10.5 macosx10.7
|
||||
macosx10.10 unix
|
||||
|
||||
sys/vms:
|
||||
(files for VMS version - untested for 3.6.0)
|
||||
|
||||
156
dat/tribute
156
dat/tribute
@@ -476,13 +476,129 @@ There's a fifth element, and generally it's called Surprise.
|
||||
%e title
|
||||
#
|
||||
#
|
||||
# The Last Hero has never been released in the U.S. (or anywhere?) as a
|
||||
# conventional mass market paperback. The large (roughly 10" by 12")
|
||||
# trade paperback contains many full page color illustrations and most
|
||||
# text pages include decorations of varying degress of elaborateness.
|
||||
# The actual text is probably only novella length.
|
||||
#
|
||||
%title The Last Hero (1)
|
||||
%title The Last Hero (7)
|
||||
# pg. 41 (end of 1st paragraph)
|
||||
%passage 1
|
||||
Too many people, when listing all the perils to be found in the search for lost treasure or ancient wisdom,
|
||||
had forgotten to put at the top of the list 'the man who arrived just before you'.
|
||||
Too many people, when listing all the perils to be found in the search
|
||||
for lost treasure or ancient wisdom, had forgotten to put at the top of
|
||||
the list 'the man who arrived just before you'.
|
||||
|
||||
[The Last Hero, by Terry Pratchett]
|
||||
[The Last Hero, written by Terry Pratchett, illustrated by Paul Kidby]
|
||||
%e passage
|
||||
# pg. 5 (1st page of text, 4th & 5th paragraphs)
|
||||
# second paragraph is a bit "on the nose" but is too good to leave out
|
||||
%passage 2
|
||||
The reason for the story was a mix of many things. There was humanity's
|
||||
desire to do forebidden deeds merely because they were forebidden.
|
||||
There was its desire to find new horizon's and kill the people who live
|
||||
beyond them. There were the mysterious scrolls. There was the cucumber.
|
||||
But mostly there was the knowledge that one day, it would all be over.
|
||||
|
||||
'Ah, well, life goes on,' people say when someone dies. But from the
|
||||
point of view of the person who has just died, it doesn't. It's the
|
||||
universe that goes on. Just as the deceased was getting the hang of
|
||||
everything it's all whisked away, by illness or accident or, in one
|
||||
case, a cucumber. Why this has to be is one of the imponderables of
|
||||
life, in the face of which people either start to pray...
|
||||
or become really, really angry.
|
||||
|
||||
[The Last Hero, written by Terry Pratchett, illustrated by Paul Kidby]
|
||||
%e passage
|
||||
# pg. 19 (bottom 20%)
|
||||
%passage 3
|
||||
'And they're /heroes/,' said Mr Betteridge of the Guild of Historians.
|
||||
|
||||
'And that means, exactly?' said the Patrician, sighing.
|
||||
|
||||
'They're good at doing what they want to do.'
|
||||
|
||||
'But they are also, as I understand it, very old men.'
|
||||
|
||||
'Very old /heroes/,' the historian corrected him. 'That just means
|
||||
they've had a lot of /experience/ in doing what they want to do.
|
||||
|
||||
Lord Vetinari sighed again. He did not like to live in a world of
|
||||
heroes. You had civilisation, such as it was, and you had heroes.
|
||||
|
||||
[The Last Hero, written by Terry Pratchett, illustrated by Paul Kidby]
|
||||
%e passage
|
||||
# pg. 25 (2nd & 3rd fifths)
|
||||
%passage 4
|
||||
They were, all of them, old men. Their background conversation was
|
||||
a litany of complaints about feet, stomachs and backs. They moved
|
||||
slowly. But they had a /look/ about them. It was in their eyes.
|
||||
|
||||
Their eyes said that wherever it was, they had been there. Whatever
|
||||
it was, they had done it, sometimes more than once. But they would
|
||||
never, ever, /buy/ the T-shirt. And they /did/ know the meaning of
|
||||
the word 'fear'. It was something that happened to other people.
|
||||
|
||||
[The Last Hero, written by Terry Pratchett, illustrated by Paul Kidby]
|
||||
%e passage
|
||||
# pg. 97 (middle)
|
||||
%passage 5
|
||||
Captain Carrot saluted. 'Force is always the last resort, sir,' he said.
|
||||
|
||||
'I believe for Cohen it's the first choice,' said Lord Vetinari.
|
||||
|
||||
'He's not too bad if you don't come up behind him suddenly,' said Rincewind.
|
||||
|
||||
'Ah, there is the voice of our mission specialist,' said the Patrician.
|
||||
'I just hope-- What is that on your badge, Captain Carrot?'
|
||||
|
||||
'Mission motto, sir,' said Carrot cheerfully. '/Morituri Nolumus Mori/.
|
||||
Rincewind suggested it.'
|
||||
|
||||
'I imagine he did,' said Lord Vetinari, observing the wizard coldly.
|
||||
'And would you care to give us a colloquial translation, Mr Rincewind?'
|
||||
|
||||
'Er...' Rincewind hesitated, but there really was no escape. 'Er...
|
||||
roughly speaking, it means, "We who are about to die don't want to", sir.'
|
||||
|
||||
[The Last Hero, written by Terry Pratchett, illustrated by Paul Kidby]
|
||||
%e passage
|
||||
# pg. 125 (near top, then continued half way down)
|
||||
%passage 6
|
||||
'A good wizard, Rincewind,' said the Chair of Indefinite Studies. 'Not
|
||||
particularly bright, but, frankly, I've never been quite happy with
|
||||
intelligence. An overrated talent, in my humble opinion.'
|
||||
|
||||
Ponder's ears went red.
|
||||
|
||||
[...]
|
||||
|
||||
'Mr Stibbons was right, was he?' said Ridcully, staring at Ponder. 'How
|
||||
did you work that out so /exactly/, Mr Stibbons?'
|
||||
|
||||
'I, er...' Ponder felt the eyes of the wizards on him. 'I--' He stopped.
|
||||
'It was a lucky guess, sir.'
|
||||
|
||||
The wizards relaxed. They were extremely uneasy with cleverness, but
|
||||
lucky guessing was what being a wizard was all about.
|
||||
|
||||
[The Last Hero, written by Terry Pratchett, illustrated by Paul Kidby]
|
||||
%e passage
|
||||
# pg. 146 (top)
|
||||
%passage 7
|
||||
Evil Harry looked down and shuffled his feet, his face a battle between
|
||||
pride and relief.
|
||||
|
||||
'Good of you to say that, lads,' he mumbled. 'I mean, you know, if it
|
||||
was up to me I wouldn't do this to yer, but I got a reputation to--'
|
||||
|
||||
'I said we /understand/,' said Cohen. 'It's just like with us. You see
|
||||
a big hairy thing galloping towards you, you don't stop to think: Is
|
||||
this a rare species on the point of extinction? No, you hack its head
|
||||
off. 'Cos that's heroing, am I right? An' /you/ see someone, you
|
||||
betray 'em, quick as a wink. 'Cos that's villaining.'
|
||||
|
||||
[The Last Hero, written by Terry Pratchett, illustrated by Paul Kidby]
|
||||
%e passage
|
||||
%e title
|
||||
#
|
||||
@@ -520,9 +636,19 @@ When Mister Safety Catch Is Not On, Mister Crossbow Is Not Your Friend.
|
||||
#
|
||||
%title Monstrous Regiment (1)
|
||||
%passage 1
|
||||
Monstrous Regiment, by Terry Pratchett
|
||||
'How can you protect yourself by carrying a sword if
|
||||
you don't know how to use it?'
|
||||
|
||||
'Not me, sir. Other people. They see the sword and
|
||||
don't attack me,' said Maladict patiently.
|
||||
|
||||
'Yes, but if they did, lad, you wouldn't be any good with it,' said the sergeant.
|
||||
|
||||
'No, sir. I'd probably settle for just ripping their heads off, sir.
|
||||
That's what I mean by protection, sir. Theirs, not mine.
|
||||
And I'd get hell from the League if I did that, sir'
|
||||
|
||||
[Monstrous Regiment, by Terry Pratchett]
|
||||
%e passage
|
||||
%e title
|
||||
#
|
||||
@@ -530,9 +656,16 @@ Monstrous Regiment, by Terry Pratchett
|
||||
#
|
||||
%title A Hat Full of Sky (1)
|
||||
%passage 1
|
||||
A Hat Full of Sky, by Terry Pratchett
|
||||
|
||||
Why do you go away?
|
||||
|
||||
So that you can come back. So that you can see the place
|
||||
you came from with new eyes and extra colors. And the people
|
||||
there see you differently, too.
|
||||
|
||||
Coming back to where you started is not the same as never leaving.
|
||||
|
||||
[A Hat Full of Sky, by Terry Pratchett]
|
||||
%e passage
|
||||
%e title
|
||||
#
|
||||
@@ -540,9 +673,14 @@ A Hat Full of Sky, by Terry Pratchett
|
||||
#
|
||||
%title Going Postal (1)
|
||||
%passage 1
|
||||
Going Postal, by Terry Pratchett
|
||||
|
||||
What was magic, after all, but something that happened at the
|
||||
snap of a finger? Where was the magic in that? It was mumbled
|
||||
words and weird drawings in old books and in the wrong hands it
|
||||
was dangerous as hell, but not one half as dangerous as it could
|
||||
be in the right hands.
|
||||
|
||||
[Going Postal, by Terry Pratchett]
|
||||
%e passage
|
||||
%e title
|
||||
#
|
||||
@@ -550,9 +688,9 @@ Going Postal, by Terry Pratchett
|
||||
#
|
||||
%title Thud! (1)
|
||||
%passage 1
|
||||
Thud!, by Terry Pratchett
|
||||
|
||||
Why bother with a cunning plan when a simple one will do?
|
||||
|
||||
[Thud!, by Terry Pratchett]
|
||||
%e passage
|
||||
%e title
|
||||
#
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
NetHack 3.6 window.doc $NHDT-Date: 1433806574 2015/06/08 23:36:14 $ $NHDT-Branch: master $:$NHDT-Revision: 1.40 $
|
||||
NetHack 3.6 window.doc $NHDT-Date: 1433901374 2015/06/10 01:56:14 $ $NHDT-Branch: master $:$NHDT-Revision: 1.42 $
|
||||
|
||||
Introduction
|
||||
|
||||
@@ -200,7 +200,8 @@ print_glyph(window, x, y, glyph, bkglyph)
|
||||
-- bkglyph is a background glyph for potential use by some
|
||||
graphical or tiled environments to allow the depiction
|
||||
to fall against a background consistent with the grid
|
||||
around x,y.
|
||||
around x,y. If bkglyph is NO_GLYPH, then the parameter
|
||||
should be ignored (do nothing with it).
|
||||
|
||||
char yn_function(const char *ques, const char *choices, char default)
|
||||
-- Print a prompt made up of ques, choices and default.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* NetHack 3.6 display.c $NHDT-Date: 1433925299 2015/06/10 08:34:59 $ $NHDT-Branch: win32-x64-working $:$NHDT-Revision: 1.65 $ */
|
||||
/* NetHack 3.6 display.c $NHDT-Date: 1433901380 2015/06/10 01:56:20 $ $NHDT-Branch: master $:$NHDT-Revision: 1.62 $ */
|
||||
/* Copyright (c) Dean Luick, with acknowledgements to Kevin Darcy */
|
||||
/* and Dave Cohrs, 1990. */
|
||||
/* NetHack may be freely redistributed. See license for details. */
|
||||
|
||||
310
sys/unix/hints/macosx10.10
Normal file
310
sys/unix/hints/macosx10.10
Normal file
@@ -0,0 +1,310 @@
|
||||
#
|
||||
# NetHack 3.5 macosx10.10 $NHDT-Date$ $NHDT-Branch$:$NHDT-Revision$
|
||||
# NetHack 3.5 macosx10.10 $Date: 2012/01/18 22:32:24 $ $Revision: 1.4 $
|
||||
# Copyright (c) Kenneth Lorber, Kensington, Maryland, 2009.
|
||||
# NetHack may be freely redistributed. See license for details.
|
||||
#
|
||||
#-PRE
|
||||
# Mac OS X (Darwin) hints file
|
||||
# This is for Mac OS X 10.10.3. If this doesn't work for some other version
|
||||
# of Mac OS X, make a new file for that OS, don't change this one. And
|
||||
# let us know about it.
|
||||
# Useful info: http://www.opensource.apple.com/darwinsource/index.html
|
||||
|
||||
# This hints file can build several different types of installations.
|
||||
# Edit the next section to match the type of build you need.
|
||||
|
||||
# 1. Which window system(s) should be included in this binary?
|
||||
WANT_WIN_TTY=1
|
||||
WANT_WIN_X11=1
|
||||
#WANT_WIN_QT=1
|
||||
|
||||
# 1a. What is the default window system?
|
||||
WANT_DEFAULT=tty
|
||||
#WANT_DEFAULT=x11
|
||||
#WANT_DEFAULT=qt
|
||||
|
||||
# 1b. If you set WANT_WIN_QT, you need to
|
||||
# A) set QTDIR either here or in the environment to point to the Qt2 or Qt3
|
||||
# library installation root. (Qt4 will not work; Qt3 does not presently
|
||||
# compile under Leopard (MacOSX 10.5) out-of-the-box.)
|
||||
# B) set XPMLIB to point to the Xpm library
|
||||
ifdef WANT_WIN_QT
|
||||
QTDIR=/Developer/Qt
|
||||
LIBXPM= -L/Developer/SDKs/MacOSX10.3.9.sdk/usr/X11R6/lib -lXpm
|
||||
endif # WANT_WIN_QT
|
||||
|
||||
# 2. Is this a build for a binary that will be shared among different users
|
||||
# or will it be private to you?
|
||||
# If it is shared:
|
||||
# - it will be owned by the user and group listed
|
||||
# - if the user does not exist, you MUST create it before installing
|
||||
# NetHack
|
||||
# - if the group does not exist, it will be created.
|
||||
# NB: if the group already exists and is being used for something
|
||||
# besides games, you probably want to specify a new group instead
|
||||
# NB: the group will be created locally; if your computer is centrally
|
||||
# administered this may not be what you (or your admin) want.
|
||||
# Consider a non-shared install (WANT_SHARE_INSTALL=0) instead.
|
||||
# - 'make install' must be run as "sudo make install"
|
||||
#WANT_SHARE_INSTALL=1
|
||||
GAMEUID = $(USER)
|
||||
GAMEGRP = games
|
||||
# build to run in the source tree - primarily for development. Build with "make all"
|
||||
#WANT_SOURCE_INSTALL=1
|
||||
|
||||
CC=gcc
|
||||
|
||||
# At the moment this is just for debugging, but in the future it could be
|
||||
# useful for other things. Requires SYSCF and an ANSI compiler.
|
||||
#WANT_WIN_CHAIN=1
|
||||
|
||||
#
|
||||
# You shouldn't need to change anything below here.
|
||||
#
|
||||
|
||||
#CFLAGS+=-W -Wimplicit -Wreturn-type -Wunused -Wformat -Wswitch -Wshadow -Wcast-qual -Wwrite-strings -DGCC_WARN
|
||||
CFLAGS+=-Wall -Wextra -Wno-missing-field-initializers -Wimplicit -Wreturn-type -Wunused -Wformat -Wswitch -Wshadow -Wwrite-strings -DGCC_WARN -ansi -pedantic
|
||||
# As of LLVM build 2336.1.00, this gives dozens of spurious messages, so
|
||||
# leave it out by default.
|
||||
#CFLAGS+=-Wunreachable-code
|
||||
|
||||
# XXX -g vs -O should go here, -I../include goes in the makefile
|
||||
CFLAGS+=-g -I../include
|
||||
# older binaries use NOCLIPPING, but that disables SIGWINCH
|
||||
#CFLAGS+=-DNOCLIPPING
|
||||
CFLAGS+= -DNOMAIL -DNOTPARMDECL -DHACKDIR=\"$(HACKDIR)\"
|
||||
CFLAGS+= -DDEFAULT_WINDOW_SYS=\"$(WANT_DEFAULT)\" -DDLB
|
||||
|
||||
CFLAGS+= -DGREPPATH=\"/usr/bin/grep\"
|
||||
|
||||
ifdef WANT_WIN_CHAIN
|
||||
CFLAGS+= -DWINCHAIN
|
||||
HINTSRC=$(CHAINSRC)
|
||||
HINTOBJ=$(CHAINOBJ)
|
||||
endif
|
||||
|
||||
ifdef WANT_WIN_TTY
|
||||
WINSRC = $(WINTTYSRC)
|
||||
WINOBJ = $(WINTTYOBJ)
|
||||
WINLIB = $(WINTTYLIB)
|
||||
WINTTYLIB=-lncurses
|
||||
else # !WANT_WIN_TTY
|
||||
CFLAGS += -DNOTTYGRAPHICS
|
||||
endif # !WANT_WIN_TTY
|
||||
|
||||
ifdef WANT_WIN_X11
|
||||
WINSRC += $(WINX11SRC)
|
||||
WINOBJ += $(WINX11OBJ)
|
||||
WINLIB += $(WINX11LIB)
|
||||
LFLAGS=-L/usr/X11R6/lib
|
||||
VARDATND = x11tiles NetHack.ad pet_mark.xbm
|
||||
POSTINSTALL+= bdftopcf win/X11/nh10.bdf > $(HACKDIR)/nh10.pcf; (cd $(HACKDIR); mkfontdir);
|
||||
CFLAGS += -DX11_GRAPHICS -I/usr/X11R6/include
|
||||
endif # WANT_WIN_X11
|
||||
|
||||
ifdef WANT_WIN_QT
|
||||
CFLAGS += -DQT_GRAPHICS -DNOUSER_SOUNDS
|
||||
CFLAGS += -isysroot /Developer/SDKs/MacOSX10.4u.sdk -mmacosx-version-min=10.4
|
||||
LINK=g++
|
||||
WINSRC += $(WINQTSRC)
|
||||
WINLIB += $(WINQTLIB) $(LIBXPM)
|
||||
WINLIB += -framework Carbon -framework QuickTime -lz -framework OpenGL
|
||||
WINLIB += -framework AGL
|
||||
ifdef WANT_WIN_X11
|
||||
# prevent duplicate tile.o in WINOBJ
|
||||
WINOBJ = $(sort $(WINQTOBJ) $(WINX11OBJ))
|
||||
ifdef WANT_WIN_TTY
|
||||
WINOBJ += $(WINTTYOBJ)
|
||||
endif # WANT_WIN_TTY
|
||||
else # !WANT_WIN_X11
|
||||
WINOBJ += $(WINQTOBJ)
|
||||
endif # !WANT_WIN_X11
|
||||
|
||||
# XXX if /Developer/qt exists and QTDIR not set, use that
|
||||
ifndef QTDIR
|
||||
$(error QTDIR not defined in the environment or Makefile)
|
||||
endif # QTDIR
|
||||
# XXX make sure QTDIR points to something reasonable
|
||||
else # !WANT_WIN_QT
|
||||
LINK=$(CC)
|
||||
endif # !WANT_WIN_QT
|
||||
|
||||
ifdef WANT_SHARE_INSTALL
|
||||
# if $GAMEUID is root, we install into roughly proper Mac locations, otherwise
|
||||
# we install into ~/nethackdir
|
||||
ifeq ($(GAMEUID),root)
|
||||
PREFIX:=/Library/NetHack
|
||||
SHELLDIR=/usr/local/bin
|
||||
HACKDIR=$(PREFIX)/nethackdir
|
||||
CHOWN=chown
|
||||
CHGRP=chgrp
|
||||
# We run sgid so the game has access to both HACKDIR and user preferences.
|
||||
GAMEPERM = 02755
|
||||
else # ! root
|
||||
PREFIX:=/Users/$(GAMEUID)
|
||||
SHELLDIR=$(PREFIX)/bin
|
||||
HACKDIR=$(PREFIX)/nethackdir
|
||||
CHOWN=/usr/bin/true
|
||||
CHGRP=/usr/bin/true
|
||||
GAMEPERM = 0500
|
||||
endif # ! root
|
||||
VARFILEPERM = 0664
|
||||
VARDIRPERM = 0775
|
||||
ROOTCHECK= [[ `id -u` == 0 ]] || ( echo "Must run install with sudo."; exit 1)
|
||||
# XXX it's nice we don't write over sysconf, but we've already erased it
|
||||
# make sure we have group GAMEUID and group GAMEGRP
|
||||
PREINSTALL= . sys/unix/hints/macosx.sh user2 $(GAMEUID); . sys/unix/hints/macosx.sh group2 $(GAMEGRP); mkdir $(SHELLDIR); chown $(GAMEUID) $(SHELLDIR)
|
||||
POSTINSTALL+= cp -n sys/unix/sysconf $(HACKDIR)/sysconf; $(CHOWN) $(GAMEUID) $(HACKDIR)/sysconf; $(CHGRP) $(GAMEGRP) $(HACKDIR)/sysconf; chmod $(VARFILEPERM) $(HACKDIR)/sysconf;
|
||||
CFLAGS+=-DSYSCF -DSYSCF_FILE=\"$(HACKDIR)/sysconf\" -DSECURE
|
||||
else ifdef WANT_SOURCE_INSTALL
|
||||
PREFIX=$(abspath $(NHSROOT))
|
||||
# suppress nethack.sh
|
||||
#SHELLDIR=
|
||||
HACKDIR=$(PREFIX)/playground
|
||||
CHOWN=/usr/bin/true
|
||||
CHGRP=/usr/bin/true
|
||||
GAMEPERM = 0700
|
||||
VARFILEPERM = 0600
|
||||
VARDIRPERM = 0700
|
||||
# We can use "make all" to build the whole thing - but it misses some things:
|
||||
MOREALL=$(MAKE) install
|
||||
CFLAGS+=-DSYSCF -DSYSCF_FILE=\"$(HACKDIR)/sysconf\" -DSECURE
|
||||
else # !WANT_SOURCE_INSTALL
|
||||
PREFIX:=$(wildcard ~)
|
||||
SHELLDIR=$(PREFIX)/bin
|
||||
HACKDIR=$(PREFIX)/nethackdir
|
||||
CHOWN=/usr/bin/true
|
||||
CHGRP=/usr/bin/true
|
||||
GAMEPERM = 0700
|
||||
VARFILEPERM = 0600
|
||||
VARDIRPERM = 0700
|
||||
ifdef WANT_WIN_X11
|
||||
# install nethack.rc as ~/.nethackrc if no ~/.nethackrc exists
|
||||
PREINSTALL= cp -n win/X11/nethack.rc ~/.nethackrc
|
||||
endif # WANT_WIN_X11
|
||||
POSTINSTALL+= cp -n sys/unix/sysconf $(HACKDIR)/sysconf; $(CHOWN) $(GAMEUID) $(HACKDIR)/sysconf; $(CHGRP) $(GAMEGRP) $(HACKDIR)/sysconf; chmod $(VARFILEPERM) $(HACKDIR)/sysconf;
|
||||
CFLAGS+=-DSYSCF -DSYSCF_FILE=\"$(HACKDIR)/sysconf\" -DSECURE
|
||||
endif # !WANT_SOURCE_INSTALL
|
||||
|
||||
|
||||
# ~/Library/Preferences/NetHack Defaults
|
||||
# OPTIONS=name:player,number_pad,menustyle:partial,!time,showexp
|
||||
# OPTIONS=hilite_pet,toptenwin,msghistory:200,windowtype:Qt
|
||||
#
|
||||
# Install.Qt mentions a patch for macos - it's not there (it seems to be in the Qt binary
|
||||
# package under the docs directory).
|
||||
|
||||
#-POST
|
||||
ifdef MAKEFILE_TOP
|
||||
###
|
||||
### Packaging
|
||||
###
|
||||
# Notes:
|
||||
# 1) The Apple developer utilities must be installed in the default location.
|
||||
# 2) Do a normal build before trying to package the game.
|
||||
# 3) This matches the 3.4.3 Term package, but there are some things that should
|
||||
# be changed.
|
||||
|
||||
ifdef WANT_WIN_TTY
|
||||
DEVUTIL=/Developer/Applications/Utilities
|
||||
PKGR=$(DEVUTIL)/PackageMaker.app/Contents/MacOS/PackageMaker
|
||||
SVS=$(shell $(NHSROOT)/util/makedefs --svs)
|
||||
SVSDOT=$(shell $(NHSROOT)/util/makedefs --svs .)
|
||||
|
||||
PKGROOT_UG = PKGROOT/usr/games
|
||||
PKGROOT_UGLN = PKGROOT/usr/games/lib/nethackdir
|
||||
build_tty_pkg:
|
||||
ifneq (,$(WANT_WIN_X11)$(WANT_WIN_QT))
|
||||
-echo build_tty_pkg only works for a tty-only build
|
||||
exit 1
|
||||
else
|
||||
rm -rf NetHack-$(SVS)-mac-Term.pkg NetHack-$(SVS)-mac-Term.dmg
|
||||
$(MAKE) build_package_root
|
||||
rm -rf RESOURCES
|
||||
mkdir RESOURCES
|
||||
#enscript --language=rtf -o - < dat/license >RESOURCES/License.rtf
|
||||
sys/unix/hints/macosx.sh descplist > RESOURCES/Description.plist
|
||||
sys/unix/hints/macosx.sh infoplist > Info.plist
|
||||
|
||||
mkdir PKGROOT/Applications
|
||||
#osacompile -o NetHackQt/NetHackQt.app/nethackdir/NetHackRecover.app \
|
||||
# win/macosx/NetHackRecover.applescript
|
||||
#cp win/macosx/recover.pl NetHackQt/NetHackQt.app/nethackdir
|
||||
osacompile -o PKGROOT/Applications/NetHackRecover.app \
|
||||
win/macosx/NetHackRecover.applescript
|
||||
cp win/macosx/recover.pl $(PKGROOT_UGLN)
|
||||
|
||||
osacompile -o PKGROOT/Applications/NetHackTerm.app \
|
||||
win/macosx/NetHackTerm.applescript
|
||||
|
||||
# XXX integrate into Makefile.doc
|
||||
(cd doc; cat Guidebook.mn | ../util/makedefs --grep --input - --output - \
|
||||
| tbl tmac.n - | groff |ps2pdf - > Guidebook.pdf)
|
||||
cp doc/Guidebook.pdf $(PKGROOT_UG)/doc/NetHackGuidebook.pdf
|
||||
|
||||
osacompile -o PKGROOT/Applications/NetHackGuidebook.app \
|
||||
win/macosx/NetHackGuidebook.applescript
|
||||
|
||||
$(PKGR) --root PKGROOT --info Info.plist -e RESOURCES -v -o NetHack-$(SVS)-mac-Term.pkg
|
||||
hdiutil create -verbose -srcfolder NetHack-$(SVS)-mac-Term.pkg NetHack-$(SVS)-mac-Term.dmg
|
||||
|
||||
build_package_root:
|
||||
cd src/.. # make sure we are at TOP
|
||||
rm -rf PKGROOT
|
||||
mkdir -p $(PKGROOT_UG)/lib $(PKGROOT_UG)/bin $(PKGROOT_UG)/man/man6 $(PKGROOT_UG)/doc $(PKGROOT_UGLN)
|
||||
install -p src/nethack $(PKGROOT_UG)/bin
|
||||
# XXX should this be called nethackrecover?
|
||||
install -p util/recover $(PKGROOT_UG)/bin
|
||||
install -p doc/nethack.6 $(PKGROOT_UG)/man/man6
|
||||
install -p doc/recover.6 $(PKGROOT_UG)/man/man6
|
||||
install -p doc/Guidebook $(PKGROOT_UG)/doc
|
||||
install -p dat/nhdat $(PKGROOT_UGLN)
|
||||
cd dat; install -p $(DATNODLB) ../$(PKGROOT_UGLN)
|
||||
# XXX these files should be somewhere else for good Mac form
|
||||
touch $(PKGROOT_UGLN)/perm $(PKGROOT_UGLN)/record $(PKGROOT_UGLN)/logfile
|
||||
# XXX may need postinstall script to get perms right for sgid, etc.
|
||||
mkdir $(PKGROOT_UGLN)/save
|
||||
# XXX what about a news file?
|
||||
endif # end of build_tty_pkg
|
||||
endif # WANT_WIN_TTY for packaging
|
||||
|
||||
ifdef WANT_WIN_QT
|
||||
# XXX untested and incomplete (see below)
|
||||
build_qt_pkg:
|
||||
ifneq (,$(WANT_WIN_X11)$(WANT_WIN_TTY))
|
||||
-echo build_qt_pkg only works for a qt-only build
|
||||
exit 1
|
||||
else
|
||||
$(MAKE) build_package_root
|
||||
rm -rf NetHackQt
|
||||
mkdir -p NetHackQt/NetHackQt.app/nethackdir/save
|
||||
mkdir NetHackQt/Documentation
|
||||
cp doc/Guidebook.txt doc/nethack.txt doc/recover.txt NetHackQt/Documentation
|
||||
|
||||
osacompile -o NetHackQt/NetHackQt.app/nethackdir/NetHackRecover.app \
|
||||
win/macosx/NetHackRecover.applescript
|
||||
cp win/macosx/recover.pl NetHackQt/NetHackQt.app/nethackdir
|
||||
|
||||
mkdir -p NetHackQt/NetHackQt.app/Contents/Frameworks
|
||||
cp $(QTDIR)/libqt-mt.3.dylib NetHackQt/NetHackQt.app/Contents/Frameworks
|
||||
|
||||
mkdir NetHackQt/NetHackQt.app/Contents/MacOS
|
||||
mv PKGROOT/nethack NetHackQt/NetHackQt.app/Contents/MacOS
|
||||
|
||||
mv PKGROOT/lib/nethackdir NetHackQt/NetHackQt.app/nethackdir
|
||||
|
||||
# XXX still missing:
|
||||
#NetHackQt/NetHackQt.app
|
||||
# /Contents
|
||||
# Info.plist
|
||||
# Resources/nethack.icns
|
||||
#NetHackQt/Documentation
|
||||
#NetHackQtRecover.txt
|
||||
#NetHack Defaults.txt
|
||||
#changes.patch XXX is this still needed? why isn't it part of the tree?
|
||||
# doesn't go here
|
||||
hdiutil create -verbose -srcfolder NetHackQt NetHack-$(SVS)-macosx-qt.dmg
|
||||
endif # end of build_qt_pkg
|
||||
endif # WANT_WIN_QT for packaging
|
||||
endif # MAKEFILE_TOP
|
||||
Reference in New Issue
Block a user