<font size=2 face="sans-serif">Hello RTEMS wizards.</font>
<br>
<br><font size=2 face="sans-serif">I am trying to setup a nightly build
process for 4.11/rtems-sparc (which is the target of interest for my section
of the European Space Agency). I managed to get a firewall exception from
our tech department so I can (finally) checkout directly from git.rtems.org.</font>
<br>
<br><font size=2 face="sans-serif">The following sequence of commands,
however, showcases a failed attempt to build 4.11/rtems-sparc :</font>
<br>
<br><font size=2 face="sans-serif"> $ git clone git://git.rtems.org/rtems-source-builder.git</font>
<br><font size=2 face="sans-serif"> $ cd rtems-source-builder</font>
<br><font size=2 face="sans-serif"> $ git checkout 4.11</font>
<br><font size=2 face="sans-serif"> $ sudo apt-get build-dep
binutils gcc g++ gdb unzip git python2.7-dev</font>
<br><font size=2 face="sans-serif"> ...</font>
<br><font size=2 face="sans-serif"> $ ./source-builder/sb-check</font>
<br><font size=2 face="sans-serif"> RTEMS Source Builder -
Check, 4.11 (436ec884a86c)</font>
<br><font size=2 face="sans-serif"> Environment is ok</font>
<br>
<br><font size=2 face="sans-serif"> $ cd rtems</font>
<br><font size=2 face="sans-serif"> $ ../source-builder/sb-set-builder
--log=l-sparc.txt --prefix=$HOME/development/rtems/4.11 4.11/rtems-sparc</font>
<br><font size=2 face="sans-serif"> ...</font>
<br><font size=2 face="sans-serif"> config: tools/rtems-gdb-7.9-1.cfg</font>
<br><font size=2 face="sans-serif"> package: sparc-rtems4.11-gdb-7.9-i686-linux-gnu-1</font>
<br><font size=2 face="sans-serif"> building: sparc-rtems4.11-gdb-7.9-i686-linux-gnu-1</font>
<br><font size=2 face="sans-serif"> reporting: tools/rtems-gdb-7.9-1.cfg
-> sparc-rtems4.11-gdb-7.9-i686-linux-gnu-1.txt</font>
<br><font size=2 face="sans-serif"> reporting: tools/rtems-gdb-7.9-1.cfg
-> sparc-rtems4.11-gdb-7.9-i686-linux-gnu-1.xml</font>
<br><font size=2 face="sans-serif"> config: tools/rtems-tools-4.11-1.cfg</font>
<br><font size=2 face="sans-serif"> package: rtems-tools-4.11-1</font>
<br><font size=2 face="sans-serif"> git: reset: git://git.rtems.org/rtems-tools.git</font>
<br><font size=2 face="sans-serif"> git: checkout: git://git.rtems.org/rtems-tools.git
=> 4.11</font>
<br><font size=2 face="sans-serif"> git: pull: git://git.rtems.org/rtems-tools.git</font>
<br><font size=2 face="sans-serif"> building: rtems-tools-4.11-1</font>
<br><font size=2 face="sans-serif"> error: building rtems-tools-4.11-1</font>
<br><font size=2 face="sans-serif"> Build FAILED</font>
<br>
<br><font size=2 face="sans-serif">Right after building GDB (successfully
- I can see the sparc-rtems4.11-gdb binary in the "temp" build
folder) RSB tries to build rtems-tools-4.11, via an auto-generated "doit"
script. After checking out from git://git.rtems.org/rtems-tools.git the
script tries to "cd rtems-tools-4.11" but in fact the only thing
that exists in that folder after checking out from rtems-tools.git is:</font>
<br>
<br><font size=2 face="sans-serif">thanassis@taste ~/development/rtems/src/rtems-source-builder/rtems/build/rtems-tools-4.11-1</font>
<br><font size=2 face="sans-serif">$ ls -l</font>
<br><font size=2 face="sans-serif">total 20</font>
<br><font size=2 face="sans-serif">drwxr-xr-x 2 thanassis thanassis 4096
Jan 27 10:46 ./</font>
<br><font size=2 face="sans-serif">drwxr-xr-x 8 thanassis thanassis 4096
Jan 27 10:35 ../</font>
<br><font size=2 face="sans-serif">-rwxr-xr-x 1 thanassis thanassis 5313
Jan 27 10:45 doit*</font>
<br><font size=2 face="sans-serif">lrwxrwxrwx 1 thanassis thanassis
92 Jan 27 10:35 rtems-tools.git -> /home/thanassis/development/rtems/src/rtems-source-builder/rtems/sources/git/rtems-tools.git/</font>
<br>
<br><font size=2 face="sans-serif">...so the process fails.</font>
<br>
<br><font size=2 face="sans-serif">I verified that this is indeed the issue
by patching "doit" to introduce a second symlink:</font>
<br>
<br><font size=2 face="sans-serif"> $ diff -u doit doit.new</font>
<br><font size=2 face="sans-serif"> --- doit
2016-01-27 11:24:40.738260198 +0100</font>
<br><font size=2 face="sans-serif"> +++ doit.new 2016-01-27
11:34:12.614248399 +0100</font>
<br><font size=2 face="sans-serif"> @@ -82,6 +82,7 @@</font>
<br><font size=2 face="sans-serif"> cd /home/thanassis/development/rtems/src/rtems-source-builder/rtems/build/rtems-tools-4.11-1</font>
<br><font size=2 face="sans-serif"> /bin/rm -rf ${rtems_tools_source}</font>
<br><font size=2 face="sans-serif"> ln -s /home/thanassis/development/rtems/src/rtems-source-builder/rtems/sources/git/rtems-tools.git
${source_dir_rtems_tools}</font>
<br><font size=2 face="sans-serif"> +ln -s /home/thanassis/development/rtems/src/rtems-source-builder/rtems/sources/git/rtems-tools.git
rtems-tools-4.11</font>
<br><font size=2 face="sans-serif"> cd ${rtems_tools_source}</font>
<br><font size=2 face="sans-serif"> /bin/chmod -R a+rX,g-w,o-w
.</font>
<br>
<br><font size=2 face="sans-serif">After this change, "doit"
completes successfully:</font>
<br>
<br><font size=2 face="sans-serif"> thanassis@taste ~/development/rtems/src/rtems-source-builder/rtems/build/rtems-tools-4.11-1</font>
<br><font size=2 face="sans-serif"> $ ./doit.new</font>
<br><font size=2 face="sans-serif"> => rtems-tools-4.11-1:</font>
<br><font size=2 face="sans-serif"> ==> %prep:</font>
<br><font size=2 face="sans-serif"> ==> clean %{buildroot}:
/home/thanassis/development/rtems/src/rtems-source-builder/rtems/build/tmp/rtems-tools-4.11-1-root-thanassis</font>
<br><font size=2 face="sans-serif"> ==> %build:</font>
<br><font size=2 face="sans-serif"> Setting top to
: /home/thanassis/development/rtems/src/rtems-source-builder/rtems/sources/git/rtems-tools.git</font>
<br><font size=2 face="sans-serif"> Setting out to
: /home/thanassis/development/rtems/src/rtems-source-builder/rtems/sources/git/rtems-tools.git/build</font>
<br><font size=2 face="sans-serif"> Version
: 4.11.3175451a890e_modified (4.11)</font>
<br><font size=2 face="sans-serif"> Checking for 'gcc' (C
compiler) : /usr/bin/gcc</font>
<br><font size=2 face="sans-serif"> Checking for 'g++' (C++
compiler) : /usr/bin/g++</font>
<br><font size=2 face="sans-serif"> Checking for header alloca.h
: yes</font>
<br><font size=2 face="sans-serif"> Checking for header fcntl.h
: yes</font>
<br><font size=2 face="sans-serif"> Checking for header process.h
: not found</font>
<br><font size=2 face="sans-serif"> ...</font>
<br><font size=2 face="sans-serif"> + install /home/thanassis/development/rtems/src/rtems-source-builder/rtems/build/tmp/rtems-tools-4.11-1-root-thanassis/home/thanassis/development/rtems/4.11/share/rtems/tester/rtems/version.cfg
(from tester/rtems/version.cfg)</font>
<br><font size=2 face="sans-serif"> Waf: Leaving directory
`/home/thanassis/development/rtems/src/rtems-source-builder/rtems/sources/git/rtems-tools.git/build'</font>
<br><font size=2 face="sans-serif"> 'install' finished successfully
(0.779s)</font>
<br><font size=2 face="sans-serif"> ==> %clean:</font>
<br>
<br><font size=2 face="sans-serif">Here's the final form of the build folder
afterwards:</font>
<br>
<br><font size=2 face="sans-serif"> thanassis@taste ~/development/rtems/src/rtems-source-builder/rtems/build/rtems-tools-4.11-1</font>
<br><font size=2 face="sans-serif"> $ ls -l</font>
<br><font size=2 face="sans-serif"> total 24</font>
<br><font size=2 face="sans-serif"> -rwxr-xr-x 1 thanassis
thanassis 5308 Jan 27 11:24 doit</font>
<br><font size=2 face="sans-serif"> -rwxr-xr-x 1 thanassis
thanassis 5425 Jan 27 11:34 doit.new</font>
<br><font size=2 face="sans-serif"> lrwxrwxrwx 1 thanassis
thanassis 92 Jan 27 11:34 rtems-tools-4.11 -> /home/thanassis/development/rtems/src/rtems-source-builder/rtems/sources/git/rtems-tools.git</font>
<br><font size=2 face="sans-serif"> lrwxrwxrwx 1 thanassis
thanassis 92 Jan 27 11:24 rtems-tools.git -> /home/thanassis/development/rtems/src/rtems-source-builder/rtems/sources/git/rtems-tools.git</font>
<br>
<br><font size=2 face="sans-serif">The hack works, but I of course need
to somehow introduce this in the process that emits "doit" -
which I understand is driven from the config files.</font>
<br>
<br><font size=2 face="sans-serif">Any help?</font>
<br><font size=2 face="sans-serif">Thanks in advance!</font>
<br>
<br><font size=2 face="sans-serif">P.S. I am not the only one experiencing
this - see relevant question on StackOverflow a month ago: </font>
<br><font size=2 face="sans-serif"> </font><a href="http://stackoverflow.com/questions/34369549/shell-cmd-failed-while-building-rtems-on-linux-mint"><font size=2 color=blue face="sans-serif">http://stackoverflow.com/questions/34369549/shell-cmd-failed-while-building-rtems-on-linux-mint</font></a>
<br><PRE>This message and any attachments are intended for the use of the addressee or addressees only.
The unauthorised disclosure, use, dissemination or copying (either in whole or in part) of its
content is not permitted.
If you received this message in error, please notify the sender and delete it from your system.
Emails can be altered and their integrity cannot be guaranteed by the sender.
Please consider the environment before printing this email.
</PRE>