Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is there a way to rename an installed .deb package with dpkg?

Context: I have installed a library compiled for debug using checkinstall, now I wish to install the library compiled for release, for the release version I renamed the package mypackage-release and I would like to rename the debug package (currently know to dpkg as mypackage) to mypackage-debug.

share|improve this question

migrated from stackoverflow.com Sep 2 '11 at 20:28

This question came from our site for professional and enthusiast programmers.

    
The only thing worse than using checkinstall is modifying the resultant package willy nilly. – PriceChild Sep 2 '11 at 21:20
    
Can you comment on why you feel this way about these things PriceChild? – dukedave Sep 15 '11 at 0:43
    
For starters, I don't see how you can work out dependencies effectively. Checkinstall 'sort of works' but I'd definitely advocate building your own debian package and doing it properly. It's a slog, but once you've done it once, updating it will be far more manageable. – PriceChild Sep 15 '11 at 10:14

Just Don't Do It. And in the future, refrain from putting version and build information in the package name; you want something like mypackage_1.0~debug and mypackage_1.0 instead.

share|improve this answer
    
Can you elaborate further? Is the use of '~' a special naming convention I am unaware of? – dukedave Sep 15 '11 at 0:44
1  
The version numbering of deb packages has a special feature so you can create "prerelease" packages. packagename-1.0 is always regarded as newer than packagename-1.0~anything but they are the same package. (If you need to be able to install both at the same time, then of course this doesn't make sense. Create a separate packagename-debug package in that case, perhaps only containing the debug symbols for the main package.) Normally, the sort order is such that any suffix is regarded as "newer" than a version string with no suffix. – tripleee Sep 16 '11 at 7:01
    
I don't understand. "packagename-1.0 is always regarded as newer than packagename-1.0~anything" + "any suffix is regarded as "newer" than a version string with no suffix" ? – andresp Mar 2 at 12:46
1  
@andresp: Any suffix except one starting with a tilde is regarded as newer, but the tilde is a special case devised precisely for this scenario. – tripleee Mar 2 at 13:30
    
ah. thanks for the clarification! – andresp Mar 2 at 17:55

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .