For compiling OpenDSS-C in Linux make sure you have the following add-ons installed in your MS VIsual Studio /Code:


Figure 1

Add-ons required for compiling OpenDSS-C using MSVS (Linux)


To build the application, the user must configure the tasks.json file as shown below. This is easily be done by following the sequence of steps:

  1. Use the menu command Terminal → Configure Tasks…. (Figure 2) 
  2. For the “Select a task to configure”, select “Create tasks json.file from template”. (Figure 3) 
  3. For the “Select a Task Template”, select “MSBuild Executes the build target”. (Figure 4)

Figure 2

Configuring tasks

Figure 3

Creating tasks from template

Figure 4

Selecting the template


A new editor tab window will appear with a template for the tasks.json file as shown in Figure 5. 

Figure 5

Editing the template

Edit the content of the tasks.json file as given below.

    "tasks": [

        {

            "label": "CMake Build",

            "type": "cmake",

            "command": "build",

            "group": "build",

            "problemMatcher": []

        }

    ]

Save the file by typing Ctrl-S or using the menu command: File → Save as shown in Figure 6. 

Figure 6

Saving the task configuration file

The user can now invoke the build using Clang by clicking the “Build” button in the bottom taskbar (see red box below). 

Parameters and configuration options in this case are the same as for the windows case. See here for learning how to determine the output type and the project's features.