Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

second argument #4

Open
treinen opened this issue Jun 21, 2019 · 4 comments
Open

second argument #4

treinen opened this issue Jun 21, 2019 · 4 comments

Comments

@treinen
Copy link

treinen commented Jun 21, 2019

An idea for the second argument of the maintainer scripts:

one place where these are used is when the arguments of the maintainer script are passed on to dpkg-maintscript-helper. Dpkg-maintscript helper then checks whether the version passed as
second argument to the script is <= than the version pased as prior-version to dpkg-maintscript helper.

So what one could do is go over the CST of the scripts of the package and identify all
prior-version arguments of dpkg-maintscript-helper (these are expected at different positions that depend on the sub-command to dpkg-maintscript-helper) and use these as possible
second arguments to the maintainer script. This would IMO allow to execute the different code paths of dpkg-maintscript-helper.

@Niols
Copy link
Member

Niols commented Jun 21, 2019

That is indeed a good idea, to crawl through the script to guess interesting versions. We should also probably find all the uses of dpkg --compare-versions. An other way that is less complete but probably gives some results would be to use a minimum and a maximum versions. But they don't exist, right? I guess we can just take a really low (with ~?) and a really high version (with a really high epoch?)

@treinen
Copy link
Author

treinen commented Jun 24, 2019

Right, we also have to look at dpkg --compare-version.

The order on debian versions is dense without endpoints. However, it is trivial to construct from a given version one that is strictly smaller (by adding "" at the end") and one that is strictly larger (by adding
something not starting on "
" at the end)

@Niols
Copy link
Member

Niols commented Jun 24, 2019 via email

@treinen
Copy link
Author

treinen commented Jun 25, 2019 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants