On Thu, Mar 23, 2017 at 9:43 PM, Niels Thykier <ni...@thykier.net> wrote:
> Michael Stapelberg: > > Sorry for the late reply. > > > > Hi again, :) > > > On Sat, Oct 1, 2016 at 11:09 AM, Niels Thykier <ni...@thykier.net> > wrote: > > > >> [...] > >> > >> Hi, > >> > >> I am sympathetic to the end goal. > >> > >> The log file approach could work, but in that case we could even defer > >> it to a separate helper (as it is dh_install is larger than I would like > >> it). > >> > > > > By “defer it”, what exactly do you mean? Checking for files which were > not > > installed? > > > > Put the logic into a separate helper, which has - as sole purpose - the > responsibility for doing "list/fail-on-missing" checks. > Thanks for clarifying. Would dh_missing be an okay name? > > > > >> I am happy to assist with creating a patch for this. > >> > >> A few recommendations: > >> * If the install log is created under debian/.debhelper it is cleaned > >> up automatically. I strongly prefer this for new internal files. > >> (Feel free to use "generated_file()" for this purpose) > >> * Please create a sub in Dh_Lib for registering installed files, so it > >> becomes standardised. > >> (Documentation goes in doc/PROGRAMMING) > >> > > > > Looking at dh_installdocs, I see that it shells out to a combination of > > find+sort+xargs+cp. What’s your recommendation for getting the list of > > affected files? Would it be best to read the output of find+sort, process > > it, then shell out to xargs+cp? > > > > To begin with, I think I would just log the original pattern (for source > files) and let this new helper "re-expand" it. If performance becomes > an issue, we can revisit that decision. The simpler it is to retro-fit > this new functionality into an existing helper, the easier we can have > "third-party" tools adopt it. :) > Makes sense. I looked at dh_installdocs and it’s actually way more complicated than I imagined. It’s too bad we don’t have a point through which all files must pass (like install_file), otherwise the change would be simple. Would it be okay to convert the helpers one-by-one to use the new mechanism? If not, I don’t think I have enough motivation to actually update all dh_* programs to log their files. -- Best regards, Michael