[Buildroot] [PATCH] package/bpftool: add a patch to fix cross compilation

Arnout Vandecappelle arnout at mind.be
Tue Jun 14 10:04:58 PDT 2022



On 13/06/2022 22:48, Shahab Vahedi wrote:
> Arnout,
> 
> On 6/13/22 22:21, Arnout Vandecappelle wrote:
>>> The patch file should be git-formatted and have your Signed-off-by.
>> I simply took the patch from [1] (which has your signoff) and added
>> the additional Makefile.include changes
> 
> Thanks for the tweak. I overlooked the "Sign-off" part. I used "diff"
> because of what BR's manual suggests [1]:
> 
>    If the software is under version control, it is recommended to use
>    the upstream SCM software to generate the patch set.
> 
>    Otherwise, concatenate the header with the output of the
>    diff -purN ...
> 
> The proposed patch was made for a tar ball release that is not under
> any version control per se. With the hindsight, maybe I should have
> checked for "v6.8.0" as branch/tag in upstream repo.

  Yeah, bpftool is actually a special situation since the real upstream (where 
you contributed your patch) is a separate repository that gets regularly synced 
into the bpftool repo. I think that at the time you sent this to Buildroot, it 
was not yet synced to bpftool.

>> (of which I don't really understand BTW why they're relevant for Buildroot).
> 
> That extra change (setting "HOSTAR") is necessary, because in upstream
> that was already taken care of before the patch submission. However, in
> v6.8.0 release "HOSTAR" is never initialised and the fix is actually
> using it.

  Since we set it from the .mk file, it doesn't actually *need* to be 
initialized in Buildroot context.

  Also, if that came from a previously applied upstream patch, it's better to 
backport the actual upstream patch. But that can be complicated as well for 
something like bpftool, so it's fully understandable to do it like this. It 
would be nice however in such a case to add a reference to the upstream commit 
that added it.

  Regards,
  Arnout

> 
> [1]
> https://buildroot.org/downloads/manual/manual.html#_format_and_licensing_of_the_package_patches
> 
> 
> Cheers,
> Shahab



More information about the linux-snps-arc mailing list