Problems compiling rtems-libbsd

Jiri Gaisler jiri at gaisler.se
Sun Nov 1 16:54:24 UTC 2020


I am trying to build the rtems-libbsd package to test the new network
stack. Configuration works fine, but compiling fails quickly. Log below,
any ideas ...?

jiri at carbon:~/ibm/src/rtems/rtems-libbsd$ python3 ./waf configure
--rtems-bsps=sparc/leon3 --prefix=/opt/rtems/6
--buildset=buildset/default.ini
Setting top to                           :
/home/jiri/ibm/src/rtems/rtems-libbsd
Setting out to                           :
/home/jiri/ibm/src/rtems/rtems-libbsd/build
RTEMS Version                            : 6
Architectures                            : riscv-rtems6, sparc-rtems6
Board Support Package (BSP)              : sparc-rtems6-leon3
Show commands                            : no
Long commands                            : no
Checking for program 'sparc-rtems6-gcc'  :
/opt/rtems/6/bin/sparc-rtems6-gcc
Checking for program 'sparc-rtems6-g++'  :
/opt/rtems/6/bin/sparc-rtems6-g++
Checking for program 'sparc-rtems6-gcc'  :
/opt/rtems/6/bin/sparc-rtems6-gcc
Checking for program 'sparc-rtems6-ld'   : /opt/rtems/6/bin/sparc-rtems6-ld
Checking for program 'sparc-rtems6-ar'   : /opt/rtems/6/bin/sparc-rtems6-ar
Checking for program 'sparc-rtems6-nm'   : /opt/rtems/6/bin/sparc-rtems6-nm
Checking for program 'sparc-rtems6-objdump' :
/opt/rtems/6/bin/sparc-rtems6-objdump
Checking for program 'sparc-rtems6-objcopy' :
/opt/rtems/6/bin/sparc-rtems6-objcopy
Checking for program 'sparc-rtems6-readelf' :
/opt/rtems/6/bin/sparc-rtems6-readelf
Checking for program 'sparc-rtems6-strip'   :
/opt/rtems/6/bin/sparc-rtems6-strip
Checking for program 'sparc-rtems6-ranlib'  :
/opt/rtems/6/bin/sparc-rtems6-ranlib
Checking for program 'rtems-ld'             : /opt/rtems/6/bin/rtems-ld
Checking for program 'rtems-tld'            : /opt/rtems/6/bin/rtems-tld
Checking for program 'rtems-syms'           : /opt/rtems/6/bin/rtems-syms
Checking for program 'rtems-bin2c'          : /opt/rtems/6/bin/rtems-bin2c
Checking for program 'tar'                  : /bin/tar
Checking for program 'gcc, cc'              :
/opt/rtems/6/bin/sparc-rtems6-gcc
Checking for program 'ar'                   :
/opt/rtems/6/bin/sparc-rtems6-ar
Checking for program 'g++, c++'             :
/opt/rtems/6/bin/sparc-rtems6-g++
Checking for program 'ar'                   :
/opt/rtems/6/bin/sparc-rtems6-ar
Checking for program 'gas, gcc'             :
/opt/rtems/6/bin/sparc-rtems6-gcc
Checking for program 'ar'                   :
/opt/rtems/6/bin/sparc-rtems6-ar
Checking for c flags '-MMD'                 : yes
Checking for cxx flags '-MMD'               : yes
Compiler version (sparc-rtems6-gcc)         : 10.2.1 20200904 (RTEMS 6,
RSB 31f936a7b74d60bda609a9960c6e1a705ba54974, Newlib a0d7982)
Checking for a valid RTEMS BSP installation : yes
Checking for RTEMS_DEBUG                    : no
Checking for RTEMS_MULTIPROCESSING          : no
Checking for RTEMS_NEWLIB                   : yes
Checking for RTEMS_POSIX_API                : yes
Checking for RTEMS_SMP                      : no
Checking for RTEMS_NETWORKING               : no
Checking for header dlfcn.h                 : yes
Checking for header rtems/pci.h             : yes
Configure variant:                          : sparc-rtems6-leon3-default
Checking for library debugger               : yes
'configure' finished successfully (0.871s)
jiri at carbon:~/ibm/src/rtems/rtems-libbsd$ python3 ./waf
Waf: Entering directory
`/home/jiri/ibm/src/rtems/rtems-libbsd/build/sparc-rtems6-leon3-default'
[   7/1954] Compiling freebsd/contrib/libpcap/grammar.c
[   9/1954] Compiling freebsd/sbin/pfctl/parse.c
[  12/1954] Compiling freebsd/contrib/expat/lib/xmltok_ns.c
[  13/1954] Compiling freebsd/contrib/expat/lib/xmltok_impl.c
[  14/1954] Compiling freebsd/contrib/expat/lib/xmltok.c
[  15/1954] Compiling freebsd/lib/libc/net/getnetbynis.c
grammar.y: In function 'pcap_parse':
grammar.y:693:31: error: 'BPF_MOD' undeclared (first use in this
function); did you mean 'BPF_MODE'?
grammar.y:693:31: note: each undeclared identifier is reported only once
for each function it appears in
grammar.y:696:31: error: 'BPF_XOR' undeclared (first use in this
function); did you mean 'BPF_OR'?

parse.y: In function '_bsd_pfctl_expand_label_str':
parse.y:4853:10: error: macro "free" requires 2 arguments, but only 1 given
In file included from
/opt/rtems/6/sparc-rtems6/leon3/lib/include/sys/malloc.h:39,
                 from ../../freebsd/sys/net/pfvar.h:42,
                 from parse.y:64:
/opt/rtems/6/sparc-rtems6/leon3/lib/include/rtems/rtems_bsdnet_internal.h:148:
note: macro "free" defined here
  148 | #define free(ptr,type) rtems_bsdnet_free(ptr,type)
      |
parse.y: In function '_bsd_pfctl_expand_altq':
parse.y:5009:39: error: macro "free" requires 2 arguments, but only 1 given
In file included from
/opt/rtems/6/sparc-rtems6/leon3/lib/include/sys/malloc.h:39,
                 from ../../freebsd/sys/net/pfvar.h:42,
                 from parse.y:64:
/opt/rtems/6/sparc-rtems6/leon3/lib/include/rtems/rtems_bsdnet_internal.h:148:
note: macro "free" defined here
  148 | #define free(ptr,type) rtems_bsdnet_free(ptr,type)
      |




More information about the devel mailing list