Installing Flora-2

Flora-2 has a simplified installation procedure for official pre-compiled releases and the full, more complex procedure, if you downloaded Flora-2 from the SVN repository.

The SVN option is suitable only for the developers and those users who need to frequently update their copy of Flora-2 in order to take advantage of the most up-to-date bug fixes and the new, cutting-edge features. Most other users should opt for the latest official release and take advantage of the simplified installation procedure. The simplified procedure does not depend on the availability of other software, such as the C++ compiler or make/nmake, and it does not involve separate steps like downloading an installing XSB.


Simplified Installation (for official releases - most users)

Download the latest official release. For Unix-based systems (Linux, Mac, Solaris, Cygwin), the file is called; for Windows, it is Flora-2.exe. Both bundles already contain a suitable version of XSB, so it does not need to be downloaded separately.

Note: you may notice that during the first few uses of the systems under Windows, some internal Flora-2 files might get recompiled on their own. This is harmless. The cause is a Windows misfeature whereby it often changes file timestamps during the unpacking process.

Installing Flora-2 from SVN (bleeding-edge users)

First, download and install XSB: either the latest released version or the development version from XSB's SVN repository. Make sure the sources are installed. If you are using the XSB Windows installer, you need to verify that the appropriate boxes are checked. Otherwise, the installer will install only the base system and the subsequent installation of Flora-2 will fail.

Note: XSB cannot be compiled in a directory whose path contains spaces. However, once compiled, XSB can be moved to any directory (even one containing spaces).

Check out Flora-2 from SVN into in a separate directory outside the XSB source tree (for instance, ~/FLORA or C:\FLORA). The Flora-2 sources will be placed in a subdirectory called flora2. Follow the instructions below.


Change to the flora2 folder at the root of your Flora-2 installation and type the following commands:

   ./makeflora clean
   ./makeflora all path-to-/XSB/bin/xsb

If xsb is aliased to the XSB executable of your XSB installation or if path-for-/XSB/bin/xsb is on the system search path for executables, then the arguments all and path-for-/XSB/bin/xsb can be omitted:

   ./makeflora clean

If everything went well, you will be able to run Flora-2 using the script ./runflora.


You will need Microsoft's nmake, which can be downloaded as part of Visual C++ Express from Install Visual C++.

Use the following commands to configure Flora-2 (assuming that XSB is installed and configured, its invocation script is in the folder  D:\XSB\bin\, and Flora-2 is installed in the folder   D:\FLORA\flora2\):

   PATH=C:\Program Files\Microsoft Visual Studio 10.0\VC\BIN;%PATH%
   cd D:\FLORA\flora2
   makeflora  clean
   makeflora  D:\XSB\bin\xsb.bat

Important: This assumes that Visual Studio was installed in the folder named C:\Program Files\Microsoft Visual Studio 10.0. If it is installed elsewhere, make the appropriate adjustments.

If you are using the 64-bit version of XSB, then configure Flora-2 using

  makeflora D:\XSB\bin\xsb64.bat

instead of D:\XSB\bin\xsb.bat.

Note: the Windows version of makeflora takes only one parameter, while its Unix counterpart takes two.

It may be useful to set the environment variable HOME on your Windows system to some directory accessible from your account. XSB and Flora-2 will place various auxiliary files in the subfolder .xsb in that directory. Environment variables are usually set by opening the System folder, which is located inside the Settings folder. If HOME is not set, XSB will use the location specified in the USERPROFILE system variable.

Once Flora-2 is installed, you can run it using the command D:\FLORA\flora2\runflora


Cygwin is a free Unix emulator for Windows. The advantage of using XSB and Flora-2 under Cygwin is that the system will run faster than under native Windows due to special optimizations that XSB has for the GCC compiler. The main disadvantage of Cygwin is that it is a fundamentally a 32 bit system, which can use only up to 3GB of main memory. If your applications of Flora-2 require more, you should bypass this option in favor of a native 64-bit builds of XSB and Flora-2.

You need a reasonably full installation of Cygwin. In particular, GCC and the related development tools (such as autoconf, make, etc.) must be installed. It is also desirable to have makedepend, which usually comes with the X11 package of Cygwin. If you are planning to access a database, the ODBC DLL must also be installed. XSB must be configured for Cygwin as well.

Other than that, the installation steps for Cygwin are the same as under Linux