0

I've had this .deb package that I built with, I think, checkinstall, directly from its git source; and it got a version like libmypackage1_0.10.7-1_armhf.deb. Then after a some months, I did a git pull in the same source, and built new version of the .deb, but it again got the libmypackage1_0.10.7-1_armhf.deb name.

Now, after some months, I am not sure anymore, which of the debs is installed - the first, or the second build - because the git hash of the commit I've built does not get included in the file name or version.

However, I've kept the build outputs from both runs, and I can see a libmypackage1_0.10.7-1_armhf.buildinfo. So, my question is - when I install such a "built" package via dpkg -i ..., does any information from the .buildinfo end up somewhere, so that I can query it with apt, dpkg, or another tool? Basically I want to query, for instance, "what is the build date of the currently installed libmypackage1_0.10.7-1?" - or any other piece of info that would help me discriminate the two builds.

If we need to navigate a bit away from the libmypackage example - let's say I want to retrieve the same info about the bash package; I know I can do this, for instance:

$ apt-show-versions bash
bash:armhf/stretch 4.4-5 uptodate

Could I issue some command, which would tell me, for instance, the build date for this package?

2

buildinfo information isn’t currently kept with deb packages.

There are a number of other ways to determine the information you need. deb packages preserve timestamps, so assuming you can trust them (which seems to be the case here), looking at the timestamps of the files installed by the packages will give you a good approximation of their build timestamp:

ls -ldtR $(dpkg -L libmypackage) | grep -v ^d | head

If you still have the debs, you can check the installed files against their checksums to determine which one is installed:

debsums libmypackage1_0.10.7-1_armhf.deb

To link a deb file to its build information, you can use the checksums in the corresponding changes file.

2

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.