Unable to determine OS

The problem with recent OS X binary installers still persist just the focus moved to 10.9 Mavericks and 10.10 Yosemite versions of OS X. Although the root cause is solved in the recent source code version.

That is why from some time now solving this issue is just about having a freshly compiled binary package. And for that you might be better of installing smlnj through homebrew. You can do it with these commands:

brew update
brew cask install smlnj

As of 2021, the command to install with cask is

brew install --cask smlnj

This will compile the package for you so you can spare the trouble of checking out the source code and doing the compilation yourself.

Just to clean up your system and avoid duplication you can remove the previous installation simply by doing the following:

sudo rm -rf /usr/local/smlnj*

For the asterisk: I had one bare smlnj folder with the 110.76 inside it and one smlnj-110.75 folder I guess I had tried to install two different versions earlier...

You might need to remove any softlinks that you created yourself that point to the older smlnj folder directly under /usr/local/ removed in the previous step.


If you're using OSX 10.8 or later (uname -r gives you something starting with 12 or higher), SML/NJ pre 110.75 doesn't work too well without some extra tweaking. It's a known issue that can be fixed by adding the 10.8 choice (see the 12 line below) to the OS detection code in .arch-n-opsys:

    :
    10*) OPSYS=darwin; HEAP_OPSYS=darwin ;; # MacOS X 10.6
    11*) OPSYS=darwin; HEAP_OPSYS=darwin ;; # MacOS X 10.7
    12*) OPSYS=darwin; HEAP_OPSYS=darwin ;; # MacOS X 10.8
    13*) OPSYS=darwin; HEAP_OPSYS=darwin ;; # MacOS X 10.9 Mavericks
    14*) OPSYS=darwin; HEAP_OPSYS=darwin ;; # MacOS X 10.10 Yosemite
    15*) OPSYS=darwin; HEAP_OPSYS=darwin ;; # MacOS X 10.11 El Capitan
    16*) OPSYS=darwin; HEAP_OPSYS=darwin ;; # MacOS X 10.12 Sierra
    17*) OPSYS=darwin; HEAP_OPSYS=darwin ;; # MacOS X 10.13 High Sierra

    *)   exit 1;;
esac;;

Tags:

Smlnj