3.2 Platform Specific Notes

This section contains some installation notes that are platform specific under UNIX.

Mac OS X
If you intend to use the Jasper Java interface you need the latest Java development tools. These are downloadable from Apple at http://developer.apple.com/java. As an alternative, you can use the pre-built installation. Most easily by using the SICStus Installer Tool or by invoking InstallSICStus with the --all-questions argument.

An executable built with spld will only work if there is a properly configured subdirectory sp-3.12.11 in the same directory as the executable; see Runtime Systems on UNIX Target Machines. Alternatively, the option --wrapper can be passed to spld. In this case a wrapper script is created that will set up various environment variables and invoke the real executable.

It is not possible to prelink dynamic foreign resources into a dynamically linked Prolog executable. That is, except for data resources, spld --resources ... does not work, whereas spld --static --resources ... will. This is no great loss; pre-linking dynamic foreign resources is pointless, at best.

When using third-party products like BDB, you may need to set up DYLD_LIBRARY_PATH so that the Mac OS X dynamic linker can find them. When using the SICStus development executable (sicstus), this should happen automatically.

File names are encoded in UTF-8 on Mac OS X. This is handled correctly by SICStus. If SICStus encounters a file name that is not encoded in UTF-8, it will interpret the name as Latin 1 (ISO 8859/1) instead. This can happen on file systems where files have been created by some other OS than Mac OS X, e.g. on network file servers accessed by other UNIX flavors or Windows.

Sometimes, the default limit on the process's data-segment is unreasonably small, which may lead to unexpected memory allocation failures. To check this limit, do

          tcsh> limit data
          datasize 	6144 kbytes
          bash> ulimit -d

This indicates that the maximum size of the data-segment is only 6 Mb. To remove the limit, do

          tcsh> limit datasize unlimited
          datasize 	unlimited
          bash> ulimit -d unlimited
          bash> ulimit -d
Please note: limit (ulimit) is a shell built-in in csh/tcsh (sh/bash). It may have a different name in other shells.
Please note: The limit will also affect SICStus when started from within Emacs, e.g. with M-x run-prolog. To change the limit used by Emacs and its sub-processes (such as SICStus) you will need to change the limit in the shell used to start Emacs. Alternatively you can create a shell wrapper for the emacs command.

As of SICStus 3.12.7 SICStus will set the data segment size of itself according to the value of the environment variable SP_ULIMIT_DATA_SEGMENT_SIZE. If you set this variable in the initialization file for your shell you do not have to use the ulimit command.

The default character encoding for SICStus is Latin1 (ISO-8859-1) (see WCX Environment Variables). This will come in conflict with the default character encoding for the Terminal application which is UTF-8. A clickable launcher for SICStus is optionally installed in the Applications folder. This launcher will set the character encoding to Latin1 for both the Terminal and SICStus.