This approach allows you to install a *-build-deps
package that can be easily apt autoremove
d later when you don't need the dependencies anymore.
- Install packaging tools:
sudo apt install devscripts equivs
- Generate a
build-deps
package (in this case we usenextcloud-desktop
as an example):mk-build-deps nextcloud-desktop
- Install it:
sudo apt install ./nextcloud-desktop-build-deps_x.y.z_amd64.deb
- Try to compile the package. If some build dependencies are missing at this point, you can install them with an additional package. To do that:
- Create a control file like this:
Package: nextcloud-desktop-build-deps-more Version: 0.1.0 Architecture: amd64 Maintainer: Your Name <[email protected]> Installed-Size: 10 Depends: libkf5archive-dev:amd64, qtbase5-private-dev:amd64 Section: devel Priority: optional Multi-Arch: foreign Description: Additional build dependencies for nextcloud-desktop
- Generate a DEB package:
#!/bin/sh equivs-build nextcloud-desktop-build-deps-more.control
- Install it:
sudo apt install ./nextcloud-desktop-build-deps-more_0.1.0_amd64.deb
- When you are done with compiling:
sudo apt autoremove nextcloud-desktop-build-deps nextcloud-desktop-build-deps-more