The Problem

You have created a language based on mbeddr Platform, MPS Extensions, or KernelF (or all of the above). Now the time has come to create a build script for your language to package it for delivery to the users. However, after creating the build script you get an error message saying Error: dependency on a module not visible from current build project:

Dependency on a module not visible from current build

What Is Going On Here?

The solution jetbrains.mps.samples.theSimplestLanguage.sandbox depends on the org.iets3.core.base module1 but the build script doesn’t have the information required to locate this module. The MPS IDE probably has this module in one of the configured project libraries, but the build language requires that you provide these paths explicitly to the build script.

The Solution

Add the build script of the project you want to depend on to the dependencies: section of your build script. You may need to import the model containing the build script: either by using the usual Ctrl/Cmd+R shortcut and searching for the build script or using Ctrl/Cmd+M and searching for the model containing the build script.

The result should look like this:

Dependency on org.iets3.opensource added

After adding the dependency use the Reload modules from disk intention to update the module dependencies and the error should disappear. To execute the generated build script you will also need to specify the artifacts location for the newly added dependency.

Here are the build scripts you need to depend on for some of the popular libraries (as of August 2019). The build script link opens the script in MPS:

Project Build Script Containing Model
KernelF/iets3.opensource org.iets3.opensource
mbeddr Platform com.mbeddr.platform
MPS extensions de.itemis.mps.extensions

More Resources

  • Kolja Dummann has recorded a Twitch stream on the topic of setting up the build of an MPS project. The video is part of the “Heavy Meta” series of videos about MPS.

  1. This is of course just an artificial dependency added for demonstration purposes. [return]