psxfenv01 fails to compile for RISCV
Jiri Gaisler
jiri at gaisler.se
Sat Nov 9 19:38:31 UTC 2019
On 11/9/19 7:57 PM, Joel Sherrill wrote:
>
>
> On Sat, Nov 9, 2019, 12:40 PM Jiri Gaisler <jiri at gaisler.se
> <mailto:jiri at gaisler.se>> wrote:
>
> I get this error for psxfenv01 with the latest RTEMS and RSB build:
>
> riscv-rtems5-gcc -DHAVE_CONFIG_H -I.
> -I/home/jiri/ibm/src/rtems/rtems/c/src/../../testsuites/psxtests -I.
> -I/home/jiri/src/rtems/riscvmp/riscv-rtems5/c/griscv/include
> -I/home/jiri/ibm/src/rtems/rtems/cpukit/include
> -I/home/jiri/ibm/src/rtems/rtems/cpukit/score/cpu/riscv/include
> -I/home/jiri/src/rtems/riscvmp/riscv-rtems5/c/griscv/lib/libbsp/riscv/griscv/include
> -I/home/jiri/ibm/src/rtems/rtems/bsps/include
> -I/home/jiri/ibm/src/rtems/rtems/bsps/riscv/include
> -I/home/jiri/ibm/src/rtems/rtems/bsps/riscv/griscv/include
> -DT_FILE_NAME='"init.c"'
> -I/home/jiri/ibm/src/rtems/rtems/c/src/../../testsuites/psxtests/../support/include
> -march=rv32imafd -mabi=ilp32d -O2 -g -ffunction-sections
> -fdata-sections
> -Wall -Wmissing-prototypes -Wimplicit-function-declaration
> -Wstrict-prototypes -Wnested-externs -MT
> psxfenv01/psxfenv01-init.o -MD
> -MP -MF psxfenv01/.deps/psxfenv01-init.Tpo -c -o
> psxfenv01/psxfenv01-init.o `test -f 'psxfenv01/init.c' || echo
> '/home/jiri/ibm/src/rtems/rtems/c/src/../../testsuites/psxtests/'`psxfenv01/init.c
> In file included from
> /home/jiri/src/rtems/5/riscv-rtems5/include/fenv.h:15,
> from
> /home/jiri/ibm/src/rtems/rtems/c/src/../../testsuites/psxtests/psxfenv01/init.c:42:
> /home/jiri/ibm/src/rtems/rtems/c/src/../../testsuites/psxtests/psxfenv01/init.c:
> In function 'Init':
> /home/jiri/ibm/src/rtems/rtems/c/src/../../testsuites/psxtests/psxfenv01/init.c:71:18:
> error: 'fe_dfl_env_p' undeclared (first use in this function); did you
> mean 'fe_dfl_env'?
> 71 | r = fesetenv(FE_DFL_ENV);
> | ^~~~~~~~~~
> /home/jiri/ibm/src/rtems/rtems/c/src/../../testsuites/psxtests/psxfenv01/init.c:71:18:
> note: each undeclared identifier is reported only once for each
> function
> it appears in
> Makefile:10569: recipe for target 'psxfenv01/psxfenv01-init.o' failed
> make[5]: *** [psxfenv01/psxfenv01-init.o] Error 1
> make[5]: Leaving directory
> '/home/jiri/src/rtems/riscvmp/riscv-rtems5/c/griscv/testsuites/psxtests'
> Makefile:663: recipe for target 'psxtests' failed
> make[4]: *** [psxtests] Error 2
> make[4]: Leaving directory
> '/home/jiri/src/rtems/riscvmp/riscv-rtems5/c/griscv/testsuites'
> Makefile:1222: recipe for target 'testsuites' failed
> make[3]: *** [testsuites] Error 2
> make[3]: Leaving directory
> '/home/jiri/src/rtems/riscvmp/riscv-rtems5/c/griscv'
> Makefile:716: recipe for target 'all-recursive' failed
> make[2]: *** [all-recursive] Error 1
> make[2]: Leaving directory
> '/home/jiri/src/rtems/riscvmp/riscv-rtems5/c/griscv'
> Makefile:289: recipe for target 'all-recursive' failed
> make[1]: *** [all-recursive] Error 1
> make[1]: Leaving directory
> '/home/jiri/src/rtems/riscvmp/riscv-rtems5/c'
> Makefile:410: recipe for target 'all-recursive' failed
> make: *** [all-recursive] Error 1
> jiri at office:~/src/rtems/riscvmp$
>
>
> I thought I fixed this in the upstream newlib.
>
> https://sourceware.org/git/gitweb.cgi?p=newlib-cygwin.git;a=commit;h=9e06ba1ac310c5a2392bb9d150e4686bbb118d6c
>
> Either I didn't really fix it or your newlib is a bit old.
>
> Did Sebastian bump 5's newlib recently? I recall a binutils bump.
>
>
My RSB is in sync with git head, and I rebuilt the tool-chain 2 hours
ago. The installed fenv.h for RISCV ends with:
typedef size_t fenv_t;
typedef size_t fexcept_t;
extern const fenv_t fe_dfl_env;
#define FE_DFL_ENV fe_dfl_env_p
#endif /* _FENV_H_ */
fe_dfl_env_p seems to be missing it's declaration ...?
>
> _______________________________________________
> devel mailing list
> devel at rtems.org <mailto: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/20191109/2c2c30eb/attachment-0001.html>
More information about the devel
mailing list