These are common steps to build Notes from source on Linux distributions.
It's impossible to create a guide that will work for all Linux distros out there, but thankfully the only major difference between all of them will be package names, so feel free to add the appropriate package names for your favorite distro down here (alphabetically, please).
| Distro | Build dependencies1 | Runtime dependencies2 |
|---|---|---|
| Arch Linux3 | cmake gcc git qt6-base qt6-declarative |
hicolor-icon-theme qt6-base qt6-declarative |
| Fedora 37+ | cmake gcc git libxkbcommon-devel qt6-qtbase-private-devel qt6-qtdeclarative-devel |
qt6-qtbase-gui qt6-qtdeclarative |
| openSUSE Leap 15.5+4 | cmake gcc10-c++ git qt6-base-private-devel qt6-declarative-devel |
libQt6Concurrent6 libQt6Gui6 qt6-sql-sqlite |
| Ubuntu 22.04+ | cmake g++ git qt6-base-private-dev qt6-declarative-dev libgl-dev |
libqt6network6 libqt6sql6 libqt6widgets6 qml6-module-qtqml-workerscript qml6-module-qtquick-controls qml6-module-qtquick-layouts qml6-module-qtquick-particles qml6-module-qtquick-templates qml6-module-qtquick-window qt6-qpa-plugins |
Please refer to build_options.md.
First, use git to clone the project and its components, and then navigate into it:
git clone https://github.com/nuttyartist/notes.git --recurse-submodules
cd notesLet's create a build folder called build:
mkdir build
cd buildAfter that, we're ready to build Notes!
Invoke CMake to configure and build the project into a folder called build, in Release mode:
cmake .. -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Release
make -j$(nproc)To run the binary you just built (e.g. for testing purposes), you can simply execute the notes binary in the build folder:
./notesIf you want to install Notes like a regular, Linux desktop application (with its own desktop file and icons), you can simply run (as root):
make installAlternatively, you can also create DEB or RPM packages (see the Packaging section below).
After building, you could also easily create DEB or RPM packages using CPack:
# Create a DEB package
cpack -G DEB
# Create a RPM package
cpack -G RPMPlease note that it only makes sense to create DEB or RPM packages on the same distro you intend to install and run Notes on.
Footnotes
-
These packages are only required to build Notes, meaning you can remove all of them (or some of them) afterward. ↩
-
These packages are required to actually run Notes. ↩
-
We recommend building and installing through the official AUR package. ↩
-
You may need to tell
cmaketo use use GCC 8 (or newer), e.g. runexport CXX=g++-10before you invokecmake. ↩