Secondo on macOS Monterey (12): Installation Instructions
To be able to compile the Secondo database system, some tools and libraries must be installed. This document describes how to install all required tools.Fresh Installation
Step 1: Installing xcode command line tools
- open a terminal
- enter the following line:
gcc --version
Step 2: Installing Java-SDK
- open a terminal or use the one of the xcode installation
- enter the following line
javac -version
Step 3: Installing the Berkeley DB
Secondo uses the Berkeley-DB as a storage manager. Thus, an installation of this tool is required. Because of licensing issues, this library cannot be distributed together with Secondo.- open a browser and navigate to the Berkeley-DB download page
- download the db...tar.gz file of the latest Berkeley-DB version
- this requires an Oracle account
if you don't have such account, just create it. it's for free - open a terminal and navigate to the folder containing the db....tar.gz archive
- enter the following commands
(for other versions of the Berkeley-DB, just change the names in the first two commands):
tar -xzf db-18.1.40.tar.gz
cd db-18.1.40
cd build_unix
../dist/configure --prefix=$HOME/BDB --enable-cxx
make
mkdir $HOME/BDB
make install
Step 4: Installing SWI-Prolog
- open a browser and go to the home of SWI-Prolog
- click on Download → Swi-Prolog
- click on Stable release. The SDK is tested with Prolog 8.2.2. Prolog 8.2.3 is not supported because of an issue in this version. Prolog 8.2.4 should work again.
- click on the MacOSX version to download the dmg file
- open Finder, go to Downloads and double click on this dmg file
- some time later, a SWI-Prolog icon is shown together with the application folder
- drag the SWI-Prolog icon into the application folder
- open SWI-Prolog at least one time to ensure it can be opened
Step 5: Install the Required Tools
Note: Some algebras of SECONDO are using further dependencies. We recommend installing the Homebrew package manager for OS X. Using the package manager, these dependencies can be easily installed.- Install the Homebrew package manager for OS X.
- brew install jpeg gmp
Step 6: Install further tools and set environments variables
- open a terminal and navigate into a directory of your choice
- download the required tools for Big Sur
cd ~/Downloads
curl -L http://newton2.fernuni-hagen.de/secondo/download/SDK_OSX_MONTEREY.tar.gz --output SDK_OSX_MONTEREY.tar.gz - unpack the downloaded file
tar -xzf SDK_OSX_MONTEREY.tar.gz - change the directory
cd SDK_Monterey - run the installation script
./Install_On_Monterey.sh - if applicable change your .profile file according to the instructions printed out during the installation process
Step 7: Compiling Secondo
- open a terminal and navigate into the Secondo directory
cd $HOME/secondo - compile Secondo
make - Start Secondo according to the Secondo's User Manual
Upgrade
Please ensure that you have installed at least Xcode 13 and the Xcode 13 command line tools are active (see Xcode → Preferences → Locations → Command Line Tools).
In your Secondo source directory please execute:
That is all, your Secondo SDK is successfully upgraded.
To upgrade from a previous OS X / SDK version, please execute:
Step 5 from the installation processs
mv ${SECONDO_SDK} ${SECONDO_SDK}.oldStep 5 from the installation processs
If you have upgraded your Prolog Installation, please execute the following commands:
JPL=$(find /Applications -name "libjpl.dylib")PL=$(find /Applications -name "libswipl.dylib")SWIPLDIR=$(dirname $PL)install_name_tool -add_rpath $SWIPLDIR $JPLIn your Secondo source directory please execute:
make cleanmake
That is all, your Secondo SDK is successfully upgraded.