Fuego
This page contains notes about Computer Go in general, and programs playing Go in particular (notably Fuego and GoGui).
Fuego
Building Fuego with Visual C++
The most recent official Fuego release is 1.1. The instructions to build Fuego 1.1 with Visual C++ are here:
http://fuego.sourceforge.net/fuego-doc-1.1/general/generalvisualcplusplus.html
A newer version of that document for building the "trunk" version of Fuego can be found here. The document is still in its raw Doxygen format.
https://sourceforge.net/p/fuego/code/HEAD/tree/trunk/doc/doxygen/general/pages/visualcplusplus.cpp
The official documentation "only" has rough guidelines for setting up the Visual Studio project. Here are step-by-step instructions for setting up a project with Visual Studio 2013:
- Start wizard: File > New > Project from existing code
- Type of project = Visual C++
- Project location = Root of Fuego's source tree (e.g. where you checked out "trunk")
- Project Name = Fuego
- Select these folders as file sources (make sure that "Add subfolders" is unchecked; subfolders contain tests only)
gtpengine, smartgame, go, gouct, features, simpleplayers and fuegomain
- Project type = Console application project
- Do not add support for ATL, MFC or the Common Language Runtime (CLR)
- Preprocessor definitions: None
- Include search paths: None (it's better to set these up after the wizard has finished)
- Once the project is complete, perform the following modifications
- Create subfolders (named "Filters") below "Header Files" and "Source Files" for better organization of the source code
- Change project settings
- Select "All configurations"
- Add the following paths to "Configuration Properties > C/C++ > General > Additional Include Directories"
\path\to\32-bit-boost_root_folder $(ProjectDir)/gtpengine $(ProjectDir)/smartgame $(ProjectDir)/go $(ProjectDir)/gouct
- Add this path to "Linker > General > Additional Library Directories"
\path\to\32-bit-boost_root_folder\stage\lib
- Create the x64 platform
- Open the "Configuration Manager"
- Create a new platform "x64". Select the existing platform "Win32" to copy settings from
- Make sure that the checkbox "Create new project platforms" is checked
- Back in the project configuration dialog, select the x64 platform, then "All configurations"
- For the following settings, change the boost directory to use the 64-bit Boost root folder
- Configuration Properties > C/C++ > General > Additional Include Directories
- Linker > General > Additional Library Directories
- Set "Linker > Advanced > Target Machine" = MachineX64
Building Fuego with MinGW
The most recent official Fuego release is 1.1. The instructions to build Fuego 1.1 with MinGW are here:
http://fuego.sourceforge.net/fuego-doc-1.1/general/generalmingw.html
A newer version of that document for building the "trunk" version of Fuego can be found here. The document is still in its raw Doxygen format.
https://sourceforge.net/p/fuego/code/HEAD/tree/trunk/doc/doxygen/general/pages/mingw.cpp
Installing MinGW
- Read http://mingw.org/wiki/Getting_Started
- Download GUI installer
- Run installer
- Select the following packages
- Under "Basic Setup": mingw32-base, mingw32-gcc-g++, msys-base
- Under "MINGW": mingw32-autotools (required for autoreconf)
- Under "MSYS": msys-vim
- Install
- Create the file
C:\MinGW\msys\1.0\etc
- Add a single line to the file in a text editor (make sure that an empty line exists at the end of the file)
C:\MinGW /mingw
- Create a shortcut in the Start menu that launches the MSYS command line shell. The shortcut command line is
C:\MinGW\msys\1.0\msys.bat
- Launch MSYS shell and install the POSIX threads library (without this the Fuego configure process will fail)
mingw-get install pthreads
GoGui
Building GoGui.app on Mac OS X with Homebrew
Using Homebrew, install the following packages:
- ant
- docbook-xls
Open build.xml
in any text editor and make the following changes:
- Search for
source="1.5"
and replace 1.5 by a newer Java version. At the time of writing, version 1.6 still worked, although a deprecation warning was issued. - Repeat the above for
target="1.5"
- Search for
JavaApplicationStub
. Replace the source path with the path to theuniversalJavaApplicationStub
script from this GitHub repository: https://github.com/herzbube/universalJavaApplicationStub
Open mac/packaging/Info.plist.in
in any text editor and make the following changes:
- Search for
JavaApplicationStub
and replace it withuniversalJavaApplicationStub
Build GoGui.app with this command (change the docbook-xsl path according to the version installed on the system):
ant -Ddocbook-xsl.dir=/usr/local/Cellar/docbook-xsl/1.79.1/docbook-xsl -Dquaqua.ignore=true -Dosx.setfile="$(xcrun --find SetFile)" gogui.app
Copy GoGui.app from the build
folder to somewhere appropriate, e.g.
/Applications/GoGui.app
If the GoGui.app bundle does not work on modern macOS versions, GoGui can also be installed by running install.sh
something like this (pre-condition is that .jar
files were created):
./install.sh -p $(pwd)/gogui
Launch GoGui with English UI
In general, the language and country code used by a Java program can be determined on the command line with these two options:
- -Duser.language=<language code>. This must be a 2 character language code from ISO 639.
- -Duser.region=<country code>. This must be a 2 character country code from ISO 3166.
The language used by the UI is determined by the language code. To launch GoGui with an English UI, add this to the command line that launches GoGui:
-Duser.language=en
To make this work for the GoGui.app bundle, add the following sub-dictionary to the "Java" dictionary inside the app bundle's Info.plist
file:
<key>Properties</key> <dict> <key>user.language</key> <string>en</string> </dict>
Things that do not work:
- Setting the LANG environment variable
- The Java control panel does not offer a way how to set
user.language
globally