What is the recommended PPA source package naming schema?

Asked by Thorsten Kunz

Different documents describe different recommended naming conventions for derived source packages uploaded to PPA.

If you read here https://help.launchpad.net/Packaging/PPA/Uploading you'll get the information that you should name your custom package like <original_package>~<ppa_name>n[~<series>]

Example: myapp_1.0-2 -> myapp_1.0-2~ppa1~intrepid1

But if you read here https://help.launchpad.net/Packaging/PPA/BuildingASourcePackage you're told that this is the naming schema supposed to be used: <original_package><ppa_name>n[~<series>]

Example: myapp_1.0-2 -> myapp_1.0-2ppa1~intrepid1

And somewhere else, I am afraid I can't recall where, I saw this notion <original_package>+<ppa_name>n[~<series>]

Example: myapp_1.0-2 -> myapp_1.0-2+ppa1~intrepid1

So the difference between the three options seems to be the separation character between the original package name and the PPA name. Either ~, + or nothing are the options. Which is the correct one to use?

Question information

English Edit question
Launchpad itself Edit question
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Launchpad Janitor (janitor) said :

This question was expired because it remained in the 'Open' state without activity for the last 15 days.

Revision history for this message
Michael Nelson (michael.nelson) said :

As Thorsten shows above, this is an inconsistency in the LP documentation that needs to be addressed. I'm not aware of the pros/cons, but we should find out and update the doc.

Revision history for this message
Michael Nelson (michael.nelson) said :

This is a valid question that shouldn't expire (we were just lazy in responding ;) ).

Revision history for this message
Thorsten Kunz (sfire) said :

Thanks for the response. Since the question had expired I already opened a bug for it a few hours ago. I linked it.

Revision history for this message
Anders Kaseorg (andersk) said :

My thoughts on this topic:

Note that Debian versions sort roughly as follows:
~ < empty string < number < uppercase < lowercase < + < - < . < _
See dpkg --compare-versions in dpkg(1) if you want to test comparisons yourself.

The difference between -XubuntuY~ppa1 and -XubuntuYppa1 is important, not just conventional, because -XubuntuY~ppa1 is defined as earlier than the corresponding official package -XubuntuY, while -XubuntuYppa1 is later.

The difference between -Xppa1 and -X+ppa1 is also important, because -Xppa1 is less than the next official package Xubuntu1 (*), while -X+ppa1 is later. The difference between -XubuntuYppa1 and -XubuntuY+ppa1 is less important, but it is better to be consistent whether you’re patching -X packages or -XubuntuY packages.

It’s not a good idea to go up to -XubuntuZ~ppa1 where Z = Y+1, either, because the next official Ubuntu package might be a stable release update, in which case it would be -XubuntuY.1 instead of -XubuntuZ.

Therefore, I recommend as a general rule to add ~ppa1 when you are backporting an official package from a later distribution, so that the official package will supersede your package, and add ppa1 with no delimeter when you are adding patches on top of an official package, so that your package will supersede the official package but the next official package will supersede yours.

(* This relies on the happy accident that p comes before u. If you don’t wish to rely on this accident, you could use -Xubuntu0ppa1, but I still recommend avoiding + to help others avoid falling into the -X+ppa1 trap.)

Revision history for this message
Curtis Hovey (sinzui) said :

The reported bug is tracking the documentation problem, that is the answer.

Can you help with this problem?

Provide an answer of your own, or ask Thorsten Kunz for more information if necessary.

To post a message you must log in.