[Buildroot] [PATCH v2 1/1] linux: xenomai: allow URL for the ADEOS/IPIPE patch

Sébastien Szymanski sebastien.szymanski at armadeus.com
Mon May 20 07:29:55 UTC 2019


Hello,

On 5/19/19 11:17 AM, Yann E. MORIN wrote:
> Thomas, Sébastien, All,
> 
> On 2019-05-18 22:06 +0200, Thomas Petazzoni spake thusly:
>> On Fri, 17 May 2019 14:50:49 +0200
>> Sébastien Szymanski <sebastien.szymanski at armadeus.com> wrote:
>>> diff --git a/linux/linux-ext-xenomai.mk b/linux/linux-ext-xenomai.mk
>>> index d066bb32ac..ed29943e6c 100644
>>> --- a/linux/linux-ext-xenomai.mk
>>> +++ b/linux/linux-ext-xenomai.mk
>>> @@ -8,10 +8,20 @@ LINUX_EXTENSIONS += xenomai
>>>  
>>>  # Adeos patch version
>>>  XENOMAI_ADEOS_PATCH = $(call qstrip,$(BR2_LINUX_KERNEL_EXT_XENOMAI_ADEOS_PATCH))
>>> +
>>> +ifneq ($(filter ftp://% http://% https://%, $(XENOMAI_ADEOS_PATCH)),)
>>> +XENOMAI_ADEOS_PATCH_NAME = $(notdir $(XENOMAI_ADEOS_PATCH))
>>> +XENOMAI_ADEOS_PATCH_PATH = $(LINUX_DL_DIR)/$(XENOMAI_ADEOS_PATCH_NAME)
>>> +LINUX_EXTRA_DOWNLOADS += $(XENOMAI_ADEOS_PATCH)
>>> +BR_NO_CHECK_HASH_FOR += $(XENOMAI_ADEOS_PATCH_NAME)
>>> +else
>>> +XENOMAI_ADEOS_PATCH_PATH = $(subst file://,,$(XENOMAI_ADEOS_PATCH))
>>
>> I don't feel super strongly about this, but everywhere else in
>> Buildroot when paths are specified through configuration options, we do
>> not support having a file:// URI. For example the
>> BR2_LINUX_KERNEL_PATCH option will support file paths only without
>> file://.
>>
>> So for consistency, I would do the same here, and therefore just do:
>>
>> XENOMAI_ADEOS_PATCH_PATH = $(XENOMAI_ADEOS_PATCH)
>>
>> Yann, what do you think ?
> 
> Indeed, I don't see the point in the file:// scheme. I don't even see
> people really using it routinely.
> 
> But as far as I can see, the above, although wrong, does not require
> that the file:// prefix be used. If it is there, it is scrubbed;
> otherwise the filename is used as-is.

I don't understand what you mean with "it is scrubbed", sorry.
With the file:// scheme, Buildroot will try to download the patch with
wget and fail, that's why I filter the file:// scheme out.

But I agree that the file:// scheme is not really useful.

> 
> And it is wrong, because it should only remove it at the beginning.
> $(subst ...) would remove it anywhere. So if we were to use it (and I
> think we should not), we'd have to use $(patsubst ...) instead;
>     XENOMAI_ADEOS_PATCH_PATH = $(patsubst file://%,%,$(XENOMAI_ADEOS_PATCH))

Indeed... Thanks

Regards,

> 
> Regards,
> Yann E. MORIN.
> 


-- 
Sébastien Szymanski
Software engineer, Armadeus Systems
Tel: +33 (0)9 72 29 41 44
Fax: +33 (0)9 72 28 79 26


More information about the buildroot mailing list