I have a package that depends on openssl, but what I observe is Ubuntu 20.04 and earlier ships openssl 1.1.x and ubuntu 22.04 and higher ships openssl 3.0.x.So I had to build 2 packages of my product one depends on openssl 3.x for ubuntu 22.04 and later and other depends on openssl 1.x for ubuntu 20.04 and earlier. However, the product versions remain same and only the release string is different, for example:secure-dev-gen-1.1.0.5-0 for ubuntu >=22.04secure-dev-gen-1.1.0.5-1 for ubuntu <=20.04
But for both the packages the orig.tar.gz file has the same name:secure-dev-gen-1.1.0.5.orig.tar.gz
Now when I push the packages to the respective releases, i.e. Jammy and Focal, the first upload is successful and the later upload fails with a error email saying the orig.tar.gz file already exists with different contents...I cannot make the package versions different as the source code is same and only links to different openssl library versions.
Can anyone suggest how to go around this issue?
UPDATE:
I found this help topic from launchpad:https://help.launchpad.net/Packaging/PPA/Uploading
If your package does need to be recompiled to support multiple Ubuntu series, then you should add a suffix of the series version to the version number. So a package for Ubuntu 17.04 could be named myapp_1.0-2~ppa1~ubuntu17.04.1 and for Ubuntu 16.04 myapp_1.0-2~ppa1~ubuntu16.04.1. (The exact spelling of the suffix is not very important, but it should be based on the series version rather than the series name, since series names aren't guaranteed to sort lexicographically.) If you need to release an updated package, increment the ~ppan suffix. Specifying the series version here doesn't change the series that you are targetting; this must still be set correctly as described in the Ubuntu packaging guide's section on the changelog file.
I am not very happy with the above approach, but this works... Can anyone suggest a better way?