Add newlib patch to RTEMS RSB

Joel Sherrill joel at rtems.org
Fri Jun 21 13:49:14 UTC 2019


On Fri, Jun 21, 2019 at 3:37 AM Vaibhav Gupta <vaibhavgupta40 at gmail.com>
wrote:

> Hello,
> I figured it out.
> .
> Below is the output given by shell
> ......
> ......
> ......
> config: tools/rtems-gcc-7.4.0-newlib-1d35a003f.cfg
> warning: rtems-gcc-7.4.0-newlib-1d35a003f.cfg:29: invalid format: '%setup
> patch newlib -p'
> *error: gcc-common-1.cfg:80: %patch already setup source: newlib -p1*
> Build FAILED
> Build Set: Time 0:06:29.257451
> Build FAILED
> .
> .
> .
> .
> I realized, the name of group of my patch and the source of newlib-source
> was same in        rtems-gcc-7.4.0-newlib-1d35a003f.cfg. Also, I had put
> "%patch setup" statement before "%patch add" .
> .
> .
> .
> Here is the new git-diff. This got compiled successfully
>

Great! How is the testing going?

For the RSB until the patch is merged upstream in newlib, it is preferred
to get patches from tickets or mailing list posts. Since there is a ticket
(2972) for adding ndbm, adding your patch to that and letting the RSB fetch
it from there is the right approach.

Also there is a ticket #2833 which lists POSIX .h files missing in newlib.
It should be updated when all is merged.




> diff --git a/rtems/config/tools/rtems-gcc-7.4.0-newlib-1d35a003f.cfg
> b/rtems/config/tools/rtems-gcc-7.4.0-newlib-1d35a003f.cfg
> index b28a4b1..5c5c346 100644
> --- a/rtems/config/tools/rtems-gcc-7.4.0-newlib-1d35a003f.cfg
> +++ b/rtems/config/tools/rtems-gcc-7.4.0-newlib-1d35a003f.cfg
> @@ -23,6 +23,11 @@
>  %source set newlib --rsb-file=newlib-%{newlib_version}.tar.gz
> https://codeload.github.com/RTEMS/sourceware-mirror-newlib-cygwin/tar.gz/%{newlib_version}
>  %hash sha512 newlib-%{newlib_version}.tar.gz
> eb5943b207eca05fde4497c29491bbd3d07624e4becb410640ae8e177bd9212ca06cf726ee3882d6db5758cd03daf1462715e4b9b404abcc8f7cee5f811fd48b
>
> +%patch add newlib_ndbm file://0001-Port-ndbm.patch
> +%hash sha512 0001-Port-ndbm.patch
> 0e05d97d0a6f8a436a233fe4fb3cbda7c0cfeab11cfda1c155d8aa5b80289f386896b0e8c28e5858e1d7409fd22c8d1cbaaccb181bc376845fe6d50b16359db6
> +
> +%patch setup newlib_ndbm -p1
> +
>  %define isl_version 0.16.1
>  %hash sha512 isl-%{isl_version}.tar.bz2
> c188667a84dc5bdddb4ab7c35f89c91bf15a8171f4fcaf41301cf285fb7328846d9a367c096012fec4cc69d244f0bc9e95d84c09ec097394cd4093076f2a041b
>
> @@ -40,3 +45,4 @@
>  %define with_iconv   1
>
>  %include %{_configdir}/gcc-7.2-1.cfg
>
>
> On Fri, Jun 21, 2019 at 4:25 AM Chris Johns <chrisj at rtems.org> wrote:
>
>> On 21/6/19 4:43 am, Gedare Bloom wrote:
>> > On Thu, Jun 20, 2019 at 11:32 AM Vaibhav Gupta <
>> vaibhavgupta40 at gmail.com> wrote:
>> >> + /bin/cat
>> /home/varodek/development/rtems/rsb/rtems/patches/0001-Port-ndbm.patch
>> >> + /usr/bin/patch -p3
>> >
>> > This is the problem, the -p3 is wrong. I don't know where this is
>> > coming from though.
>>
>> This must be from a `%patch` statement. The RSB has no preset patch
>> options and
>> there is no `-p3` in my repo.
>>
>> I suggest you run with --trace and then look at the macro maps to see
>> where is
>> it is coming from.
>>
>> Chris
>>
> _______________________________________________
> devel mailing list
> devel at rtems.org
> http://lists.rtems.org/mailman/listinfo/devel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/devel/attachments/20190621/791cd9ce/attachment-0001.html>


More information about the devel mailing list