Compiling in other IDEs - musescore/MuseScore GitHub Wiki
Instructions assume you have already completed the required steps in:
- Set up developer environment
- Install Qt and Qt Creator
- Get MuseScore's source code
- Install dependencies
If you're a new developer, you should compile on the command line before you attempt to set up an IDE.
Qt Creator is a cross-platform IDE that comes with Qt and is specifically designed for building Qt software. For instructions, see Compile in Qt Creator.
The internal team uses Qt Creator, so you'll find it's better supported than the other options. Nevertheless, if you prefer to use a different IDE, feel free to add instructions for it below. Many contributors successfully and easily compile, run, and debug MuseScore Studio in Visual Studio (support is available on Discord).
Summary:
Your CMake profile for MuseScore is where you can make configuration changes. Create one for MuseScore, and deselect the "share" box so it doesn't bother you in other projects. Set the build type to Debug.
It is recommended under the Qt Creator guide to have a dummy install directory under your build. To do this in CLion, add -DCMAKE_INSTALL_PREFIX=$CMakeCurrentBuildDir$/install to the CMake Options field.
Under the run configurations menu (left of the green run arrow), click edit configurations. Create a new CMake application and choose a name for it (e.g. TestRun). Change the target to "All targets" (the topmost option in the dropdown).
Set the executable field to $CMakeCurrentBuildDir$/install/bin/mscore. Under "Before launch," remove the default build step and add the install step.
With the new run configuration, debugging should work as normal with CLion.
This guide shows how to build MuseScore on Windows using Visual Studio 2022/2026:
WARNING: There are known issues where one or more projects may fail to build on Windows due to some paths exceeding 255 characters even if you have long paths enabled. Usually these failures are in the tests projects and the MuseScoreStudio project builds fine which means you can ignore the failures. To avoid this, it is recommended to choose a folder for MuseScoreStudio as short as possible, e.g. C:\MuseScore rather than C:\<your_name>\development\MuseScoreStudio.
-
Prerequisites
- Install Visual Studio 2022/2026 with the Desktop development with C++ workload.
- Install CMake version ≥ 3.21 for VS 2022 and ≥ 4.2 for VS 2026.
- Install Git.
- Add Qt's
binfolder (e.g.C:\Tools\Qt\6.11.0\msvc2022_64\bindepending on where and which version of Qt you have) to your PATH environment variable.
-
Clone the repo
-
Optional: Disable CMake Presets in VS If you have Always use CMake Presets enabled, Visual Studio will ignore your
CMakeSettings.jsonand generate aCMakePresets.jsoninstead—so you won’t see the expectedmsvc.build_x64folder. To restore the default behavior:- In Visual Studio go to Tools → Options → CMake → General.
- Under CMake configuration file, select Never use CMake Presets.
- Reload your “Standard Build” configuration; you’ll again get the
msvc.build_x64folder.
-
Configure
mkdir build cd build cmake .. -G "Visual Studio 17 2022" -A x64 -DCMAKE_BUILD_TYPE=RelWithDebInfo
- You can use any name you want for the build folder but don't make it long due to the possible long paths issue mentioned above.
- For VS 2026 use "Visual Studio 18 2026".
- Replace
RelWithDebInfowith another configuration (e.g.Debug) if you prefer. Keep in mind thatDebugruns really slowly.
-
Open & Build
- Double-click
MuseScore.sln(MuseScore.slnxfor VS 2026) in thebuildfolder to open the solution in Visual Studio. - Select the RelWithDebInfo configuration from the toolbar (or Debug if you went with
Debugabove). - Choose Build → Build Solution (or press Ctrl+Shift+B).
- Double-click
-
Run & Debug
- Press F5 to launch MuseScore under the debugger.
- Set breakpoints in C++ or QML and step through as needed.
Older instructions are here in the old Developer's Handbook. Feel free to transfer them to this page (omit anything covered in Prerequisites).
TODO: How to compile and debug MuseScore Studio in Visual Studio Code (aka VS Code).
- Within VS Code, go to File > Open Folder and select the MuseScore source folder on your machine.
- Install extensions for VS Code:
- ...
Instructions are here in the old Developer's Handbook. Feel free to transfer them to this page (omit anything covered in Prerequisites).