Hengband Application for macOS

Binaries | English screen shot | Japanese screen shot | Feedback | Source code | 2.2.1.7 Changes | 1.6.2 Changes

Source Code

If you want to compile the code yourself or examine the changes I made, you can either get one of the packaged source code archives, hengband-2.2.1.7e.tar.gz is the latest for the version based on Hengband 2.2.1.7 and hengband-1.6.2a.tar.gz is the latest for the version based on Hengband 1.6.2, from https://osdn.net/projbects/hengbandforosx/releases/ or clone the git repository, git://git.osdn.net/gitroot/hengbandforosx/hengbandosx.git . Within the git repository, the version-2-2-1 branch corresponds to the version based on 2.2.1.7 and the version-1-6-2 branch corresponds to the version based on 1.6.2.

If you cloned the git repository and want to compile the code, you'll first need to create the configure script and some of the files it uses. To do so, run this command in the top-level directory of the directory tree with the source code (you'll need to have autoconf and automake in the path):

  1. ./bootstrap

To compile the changed code and generate an English version of the game which uses the Cocoa user interface for macOS, run these commands from the top-level directory of the directory tree with the source code:

  1. ./configure --disable-japanese --enable-cocoa
  2. make install

That will create the full application, hengband.app, in the top-level directory. You can move that wherever you want. If you want the curses interface or, if you have the X11 libraries installed, the X11 interface, do not specify --enable-cocoa when running configure. The curses or X11 interface will not use hengband.app. Instead you'll get an executable, hengband, in the directory where you ran configure and that executable will pull information from the lib subdirectory there. To get the Japanese version, do not specify --disable-japanese when running configure. Compilation of the Japanese version requires the utility, nkf, unless you are building the code based on Hengband 1.6.2. Source code for that utility is available from https://osdn.net/projects/nkf/.

To compile an English version that will run natively on either x86_64 or arm machines, you can use these commands from the top-level directory of the directory tree with the source code:

  1. env CFLAGS="-arch x86_64 -arch arm64" OBJCFLAGS="-arch x86_64 -arch arm64" LDFLAGS="-arch x86_64 -arch arm64" ./configure --disable-dependency-tracking --enable-cocoa --disable-japanese
  2. make install

For a Japanese version with a universal binary, the steps are much the same. The only difference is to omit --disable-japanese when running configure.

Eventually, the hope is that the changes made here will be incorporated into the standard version of Hengband and you can get both the source code and binaries from them.