Compiling DWSIM on Linux

From DWSIM - Chemical Process Simulator
Jump to: navigation, search
Monodevelop3.png

Introduction

Starting from the 5.12 preview branch, Mono now includes the Roslyn-based VB.NET compiler, which enables DWSIM v5.2 and newer to be compiled and tested (debugged) on Linux.

Setup the Environment

You must install Mono 5.12.0 (preview version). Follow the steps on this page to do it, or run the following commands if you're running Ubuntu 16.04 (x64):

sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
sudo apt install apt-transport-https
echo "deb https://download.mono-project.com/repo/ubuntu preview-xenial main" | sudo tee /etc/apt/sources.list.d/mono-official-preview.list
sudo apt update

Install git:

sudo apt-get install git

Install the latest preview version of MonoDevelop (v7.6) and Mono Framework (v5.12.0):

sudo apt-get install mono-complete
sudo apt-get install monodevelop

Monodevelop1.png

Download DWSIM source code

Download DWSIM's source code from GitHub:

git clone https://github.com/DanWBR/dwsim5 dwsim5

Switch to the monodevelop branch

cd dwsim5
git checkout monodevelop

Compile and Run

Open MonoDevelop:

monodevelop
  1. Go to 'File' > 'Open' and locate the solution file DWSIM5.sln at the root folder of the project source.
  2. Change the build configuration to 'Debug' or 'Release' and 'x64'.
  3. Build the solution.
  4. The Classic UI executable (DWSIM.exe) will be located on DWSIM/bin/Debug/ or DWSIM/bin/Release/, depending on your build configuration.
  5. The Cross-Platform UI executable (DWSIM.UI.Desktop.exe) will be located on DWSIM.UI.Desktop/bin/Debug/ or DWSIM.UI.Desktop/bin/Release/, depending on your build configuration.
  6. Before running DWSIM, copy all files from PlatformFiles/Common and PlatformFiles/Linux, in this order, to the build output/destination directory. This is required so you won't get an error regarding a missing CoolProp native library:

Monodevelop2.png

Support

For questions related to compiling and testing DWSIM on Linux, use the support forums on SourceForge.