How to use a older version of a package from the same PPA as a dependency while building is Launchpad?

Solution 1:

The package cardano-node explicitly depends on libsodium-dev (= 1.0.17.1-0ubuntu1) which is in the PPA. However, version 1.0.18-1 is already available in the repositories, and the older version would not be installed.

You have two options.

  1. If the version in the Ubuntu repositories work for you, then remove the explicit version number of the dependency libsodium-dev in the debian/control file.
  2. If you really need this older version with your package, then rebuild the older version under a fake version number like 2:1.0.17.1-0, and again remove the explicit version number from the debian/control file, so that the older version of libsodium-dev (now 2:1.0.17.1-0) would get a higher preference.