Note that the Mac builds of OpenModelica are discontinued after 1.16. An alternative that is fast and works on all recent versions of OSX is installing on a Linux virtual machine; there are pre-built virtual machine images available.


You can use the binary release (only x86_64 version available, built on OSX 10.9 nightly, installs into /Applications/MacPorts/ /opt/openmodelica/bin/ and /opt/openmodelica/share/doc/omc/). Note that there is no uninstaller (see MacPorts guide for some hints on what is safe to remove). Also note that make and system headers are not included in this package so you will also need to install XCode3 (10.6), which is available for free with a registration, or a later version of XCode (which is available for free from the App store). Remember to install the XCode command-line tools (recent distributions of XCode do not install them by default). You will also need Java (which might not come preinstalled on your Mac). You may also need to allow unsigned packages to be installed.

You can also install from source using MacPorts (like the binary builds). Homebrew may also be possible.

For fewer potential issues at the cost of a longer time to install, you can use the source package in our MacPorts repository. The following instructions were tested on OSX El Capitan. After setting up a MacPorts installation, run (as root):

echo rsync:// >> /opt/local/etc/macports/sources.conf # assuming you installed into /opt/local
port selfupdate port install gcc44 # With the addition of llvm/clang as the default compiler in XCode, many ports now fail to build unless you force GCC to be used. Newer MacOS versions may require more recent gfortran compilers available
port install openmodelica-devel +libraries +clang # Or skip choosing compiler here, if it gives you problems. port variant openmodelica-devel lists many alternatives is building with one compiler gives you trouble
port install openmodelica-devel +libraries -qt # If you only want the OpenModelica core port install openmodelica-devel +rml # If you want to compile using rml-mmc instead of bootstrapping (slower and requires the rml-mmc dependency; this used to be the default)

You can also install openmodelica-release for the latest point-release or openmodelica for the latest release marked stable.

To start using the OpenModelica, launch one of the executables or start reading documentation. The following command should give a hint on where to start looking.

port contents openmodelica-devel | egrep "/bin|app$|pdf$|txt$" | grep -v omlibrary

To update OpenModelica once it has been installed:

port selfupdate
port upgrade openmodelica-devel

To install using homebrew from source should be possible with something like the following commands:

brew install omniORB
brew install cmake
brew install homebrew/science/lp_solve
brew install gettext
brew install libtool
./configure LDFLAGS="-L/usr/local/opt/gettext/lib -L/usr/local/Cellar/lp_solve/" CFLAGS="-I/usr/local/opt/gettext/include -I/usr/local/Cellar/lp_solve/"  --without-omniORB --disable-omnotebook --disable-modelica3d --without-paradiseo

Note: OMNotebook does not work properly on OSX because the qt event system is different on OSX than on Linux/Windows, making the application crash when loading too large notebooks.

If you have any questions about the installation, feel free to ask on the forums.

OpenModelica includes SystemDynamics library with World modeling. Instructions: Instructions for systemdynamics World3 simulations.

You are here: