On May 31, 2011, at 4:14 PM, Robert Xu wrote:

> On Tue, May 31, 2011 at 16:01, Jeff Johnson <n3...@mac.com> wrote:
>> 
>> There's not really much happening in this patch.
>> 
>> The hardest part of a build is getting the %files manifest correct.
>> 
>> All the patch does is try to _ALSO_ do the checkfiles()
>> sanity check so that _ALL_ the errors can be dealt with,
>> rather than having to go through the tedium of
>>        lather ... rinse ... repeat
>> 
>> So its mostly a NICETOHAVE, and rather minor tweak, rather
>> than anything essential.
> 
> That would be easier for anyone, so I'm going to try and figure out
> this patch...
> 

The "best effort" to report all errors is usually (but not in this case)
already implemented @rpm5.org. The reason why the patch doesn't apply
directly is that there's already better/saner error checks than just
running the script find if there are files in %{buildroot} that
aren't in %files.


>> 
>> Yes there's often internal rearrangements of code in rpmbuild
>> that are difficult to understand applying patches but are otherwise
>> mostly cosmetic.
> 
> Hmm... so at files.c line 2896, this would be ok?
> 
>       if ((*t != '\0') && (*t != '\n')) {
>           rc = (_unpackaged_files_terminate_build) ? 1 : 0;
>           rpmlog((rc ? RPMLOG_ERR : RPMLOG_WARNING),
>               _("Installed (but unpackaged) file(s) found:\n%s"), t);
>       }
> +        else
> +            checkUnpackagedFiles(spec);
> 

Not quite (but you are in the right place for the change).

Adding your patch would end up recursing (by calling the same routine).

What would be needed is to find every occurrence of "goto error"
in the checkUnpackagedFiles() routine and to save the global error
code while continuing through the 3 checks that are implemented.

I could likely type out a patch in 15 minutes (but I'm not atm
in any position to test and to get the change checked in on multiple branches
largely because the monthly release from @rpm5.org happens today/tomorrow).

But holler at me if I forget to do the change next month.

No matter what: The patch is truly a minor NICETOHAVE, not anything super 
important.

73 de Jeff

Attachment: smime.p7s
Description: S/MIME cryptographic signature

Reply via email to