Unable to build schedsim

Joel Sherrill joel at rtems.org
Tue Mar 8 18:28:28 UTC 2016


On Tue, Mar 8, 2016 at 12:18 PM, Matthew Clark <linux.matthew at gmail.com>
wrote:

> I'm trying to build the rtems schedule simulator on my raspberrypi2 and am
> running into a compilation error.  I'm following the instructions provided
> in schedsim/UsingTheSchedulerSimulator.txt.  The configure step
>
> ./rtems-schedsim.master.git/configure --prefix=/tmp/schedsim
> --enable-maintainer-mode
> --enable-rtemsdir=/home/rtems/rtems-4.11.git
> --enable-rtemsbsp="raspberrypi2"
> --enable-networking --enable-cxx --enable-tests --target=arm-rtems4.11
>
> goes fine, but it blows up at compile:
>
> gcc -std=gnu99 -DHAVE_CONFIG_H -I. -I..
> -I../../../rtems-schedsim.master.git/schedsim/rtems
> -D__RTEMS_VIOLATE_KERNEL_VISIBILITY__ -D_GNU_SOURCE
> -I../score/include
> -I../../../rtems-schedsim.master.git/schedsim/rtems/sched_cpu
> -I/home/rtems/rtems-4.11.git/cpukit/include
> -I/home/rtems/rtems-4.11.git/cpukit/score/include
> -I/home/rtems/rtems-4.11.git/cpukit/rtems/include
> -I/home/rtems/rtems-4.11.git/cpukit/sapi/include
> -I/home/rtems/rtems-4.11.git/cpukit/libcsupport/include
> -I/home/rtems/rtems-4.11.git/cpukit/libmisc/stringto
> -I/home/rtems/rtems-4.11.git/cpukit/posix/include
> -I/home/rtems/rtems-4.11.git/cpukit/posix/include
> -g -O2 -MT librtems_a-rtems_init.o -MD -MP -MF
> .deps/librtems_a-rtems_init.Tpo
> -c -o librtems_a-rtems_init.o `test -f 'rtems_init.c' ||
> echo '../../../rtems-schedsim.master.git/schedsim/rtems/'`rtems_init.c
> In file included from
> /home/rtems/rtems-4.11.git/cpukit/score/include/rtems/score/thread.h:87:0,
>      from
> /home/rtems/rtems-4.11.git/cpukit/score/include/rtems/score/heap.h:22,
>      from
> /home/rtems/rtems-4.11.git/cpukit/rtems/include/rtems/rtems/types.h:26,
>      from
> /home/rtems/rtems-4.11.git/cpukit/rtems/include/rtems/rtems/config.h:24,
>      from /home/rtems/rtems-4.11.git/cpukit/sapi/include/rtems/config.h:57,
>      from
> ../../../rtems-schedsim.master.git/schedsim/rtems/rtems_init.c:25:
> /home/rtems/rtems-4.11.git/cpukit/score/include/rtems/score/timestamp.h:
> In function ‘_Timestamp_Set’:
>
> /home/rtems/rtems-4.11.git/cpukit/score/include/rtems/score/timestamp.h:79:3:
> warning: implicit declaration of function ‘timespec2bintime’
> [-Wimplicit-function-declaration]
>    timespec2bintime( &_ts, _time );
>
> I chased the problem down to the fact that since gcc is being called, it's
> including /usr/include/sys/time.h, which doesn't define timespec2bintime.
>  It's defined in ${RTEMS}/arm-rtems4.11/include/sys/time.h, but gcc won't
> see that.
>
> If I force to use the RTEMS compiler, with something like:
>
> make CC=arm-rtems4.11-gcc
>
> then I'll get an error about another header.
>
>
> ../../../rtems-schedsim.master.git/schedsim/rtems/sched_cpu/sys/features.h:4:28:
> fatal error: bits/posix_opt.h: No such file or directory
>  #include <bits/posix_opt.h>
>
> which doesn't exist under the rtems folder.
>
> So how do I build this?  I need to get a better understanding of the RTEMS
> scheduler and thought this would be a good way to do it.  Thanks.
>
>
It is supposed to be built using the native gcc and produce executables that
can run natively on at least Linux.

But the scheduler simulator hasn't been kept in sync with the source code
and
I wouldn't expect it to completely build unless that is addressed. There are
two areas to address:

+ list of RTEMS source tree files in the Makefile is out of date.
+ Some support methods may have changed.

But overall, the scheduler simulator was for experimenting with new
scheduler
algorithms. If you want to know what RTEMS' schedulers do, it is best to
just ask questions and play.

--joel


> Matt
>
>
>
> _______________________________________________
> users mailing list
> users at rtems.org
> http://lists.rtems.org/mailman/listinfo/users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/users/attachments/20160308/ac0d3ac1/attachment-0002.html>


More information about the users mailing list