RTEMS 4.11.0 build fails on Windows

Linda Huxley lhuxley at shaw.ca
Tue Apr 11 01:02:19 UTC 2017


Thanks Worth,

Your second patch doesn't look right.  It appears to apply a floating 
point patch specific to an ARM processor.  (I'm building for a SPARK 
processor, but only because that's what's recommended for newbies.  I 
don't see any ARM or SPARK specific build files in my build tree at all.)

So instead of that patch, I manually added the following text:

%patch add newlib 
file:///c/opt/rtems/4.11.0/rtems/gcc-4.9.3-20170404-1.patch
%hash md5 gcc-4.9.3-20170404-1.patch 3204f732cb2ec7a8dff8b7f3463e9262

in the most obvious location in the following file:

/c/opt/rtems/4.11.0/rtems/config/tools/
     rtems-gcc-4.9.3-newlib-2.2.0-20150423-1.cfg

That was the only file that I found that closely resembles the name of 
the file patched by your second patch.  The build now fails while 
processing your first patch.  The pertinent log entries follow at the 
bottom of my reply.

My build directory tree doesn't appear to match yours.  The particular 
directory tree that I have would seem to be a consequence of following 
the instructions in chapter 5 of the RTEMS User Manual.  I have also 
attempted to build from various other recipes on the RTEMS website, (all 
unsuccessfully), and I have noted that different build directory trees 
that have resulted.

At present, I don't have an "rsb" sub-directory anywhere, and I am 
building from here:

/c/opt/rtems/4.11.0/rtems

The problematic file, cfns.gperf, is here:

/c/opt/rtems/4.11.0/rtems/build/srg4n2xwm1/gcc-4.9.3/gcc/cp/cfns.gperf

I'm not sure how to modify your patch file to process that file.  I have 
almost no experience with Linux or MINGW so I'm at a bit of a loss at 
this point.

Can you perhaps suggest what I need to do to modify your patch file?

Regards,

Linda


+ cd newlib-2.2.0.20150423
+ chmod -R a+rX,g-w,o-w .
+ cat /C/opt/rtems/4.11.0/rtems/patches/gcc-4.9.3-20170404-1.patch
+ patch -p1
can't find file to patch at input line 4
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff -Naur gcc-4.9.3-orig/gcc/cp/cfns.gperf 
gcc-4.9.3-fixed/gcc/cp/cfns.gperf
|--- gcc-4.9.3-orig/gcc/cp/cfns.gperf    2014-01-02 17:23:26.000000000 -0500
|+++ gcc-4.9.3-fixed/gcc/cp/cfns.gperf    2017-04-04 14:35:14.729966600 
-0400
--------------------------
File to patch:
Skip this patch? [y]
Skipping patch.
2 out of 2 hunks ignored
can't find file to patch at input line 28
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff -Naur gcc-4.9.3-orig/gcc/cp/cfns.h gcc-4.9.3-fixed/gcc/cp/cfns.h
|--- gcc-4.9.3-orig/gcc/cp/cfns.h    2014-01-02 17:23:26.000000000 -0500
|+++ gcc-4.9.3-fixed/gcc/cp/cfns.h    2017-04-04 14:35:14.729966600 -0400
--------------------------
File to patch:
Skip this patch? [y]
Skipping patch.
4 out of 4 hunks ignored
can't find file to patch at input line 100
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff -Naur gcc-4.9.3-orig/gcc/cp/except.c gcc-4.9.3-fixed/gcc/cp/except.c
|--- gcc-4.9.3-orig/gcc/cp/except.c    2014-01-02 17:23:26.000000000 -0500
|+++ gcc-4.9.3-fixed/gcc/cp/except.c    2017-04-04 14:35:14.729966600 -0400
--------------------------
File to patch:
Skip this patch? [y]
Skipping patch.
1 out of 1 hunk ignored
can't find file to patch at input line 113
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff -Naur gcc-4.9.3-orig/gcc/cp/Make-lang.in 
gcc-4.9.3-fixed/gcc/cp/Make-lang.in
|--- gcc-4.9.3-orig/gcc/cp/Make-lang.in    2014-04-15 04:04:17.000000000 
-0400
|+++ gcc-4.9.3-fixed/gcc/cp/Make-lang.in    2017-04-04 
14:37:24.515417000 -0400
--------------------------
File to patch:
Skip this patch? [y]
Skipping patch.
1 out of 1 hunk ignored
shell cmd failed: sh -ex  /C/opt/rtems/4.11.0/rtems/build/srg4n2xwm1/doit
error: building srg4n2xwm1





On 2017-04-10 08:02, Worth Burruss wrote:
 > Linda,
 >
 > What you are seeing is caused by a recent upgrade of gcc in the MSYS2 
enviornment.  A few
 > months ago it was 5.something and now it is 6.something.  I came 
across this last week in
 > setting up a new machine.  I found a patch from the GCC mailing list 
for 5.something and
 > adjusted it for gcc 4.9.3.
 >
 > Attached are the 2 patches I created and put in a temp area to come 
back to latter and
 > properly fix when I had time.  I have never applied them to another 
system, but am pretty
 > sure they should work.  The gcc patch file goes in your 
rsb/rtems/patches directory and the
 > rsb will do the patch application.  the other patch you have to appy 
with:
 >
 > patch -p1 < rsb-fix-for-gcc-4.11-2017-0405-1.patch
 >
 > with -p1 depending on where you put the patch, I can not remeber for 
sure but think this
 > would be the top level rsb directory.
 >
 > Unfortunatly I do not have time for the next 2 or 3 weeks to actualy 
look into fixing the
 > patches properly so issues still exist, you will definitly get a 
warning about no checksum for
 > the gcc patch file, but it will not stop the build.  I suspect others 
may exist such as carriage
 > return / line feeds.
 >
 > Hopefully this is enough to get you started.
 >
 > Thank you,
 >
 > Worth Burruss



More information about the users mailing list