On Thu, Jan 19, 2017, at 12:44 PM, Li-Chun Ko wrote:
> Hi all,
> 

> 2. Error message when executing $newt test all:
> 
> lcko@lcko-VirtualBox:~/dev/go/myproj$ cd repos
> lcko@lcko-VirtualBox:~/dev/go/myproj/repos$ $newt test all
> Testing package @apache-mynewt-core/boot/boot_serial/test
> Compiling boot_serial.c
> In file included from /usr/include/assert.h:35:0,
>                  from boot_serial.c:19:
> /usr/include/features.h:367:25: fatal error: sys/cdefs.h: No such file or
> directory
> compilation terminated.
> Testing package @apache-mynewt-core/boot/bootutil/test
> Compiling bootutil_misc.c
> In file included from /usr/include/assert.h:35:0,
>                  from bootutil_misc.c:20:
> /usr/include/features.h:367:25: fatal error: sys/cdefs.h: No such file or
> directory
> compilation terminated.
> Testing package @apache-mynewt-core/crypto/mbedtls/test
> Compiling bootutil_misc.c
> In file included from /usr/include/assert.h:35:0,
>                  from bootutil_misc.c:20:
> /usr/include/features.h:367:25: fatal error: sys/cdefs.h: No such file or
> directory
> compilation terminated.
> Testing package @apache-mynewt-core/encoding/base64/test
> Compiling bootutil_misc.c
> In file included from /usr/include/assert.h:35:0,
>                  from bootutil_misc.c:20:
> /usr/include/features.h:367:25: fatal error: sys/cdefs.h: No such file or
> directory
> compilation terminated.
> Testing package @apache-mynewt-core/encoding/json/test
> Compiling bootutil_misc.c
> In file included from /usr/include/assert.h:35:0,
>                  from bootutil_misc.c:20:
> /usr/include/features.h:367:25: fatal error: sys/cdefs.h: No such file or
> directory
> compilation terminated.
> Testing package @apache-mynewt-core/fs/fcb/test
> Compiling bootutil_misc.c
> In file included from /usr/include/assert.h:35:0,
>                  from bootutil_misc.c:20:
> /usr/include/features.h:367:25: fatal error: sys/cdefs.h: No such file or
> directory
> compilation terminated.
> Testing package @apache-mynewt-core/fs/nffs/test
> Compiling bootutil_misc.c
> In file included from /usr/include/assert.h:35:0,
>                  from bootutil_misc.c:20:
> /usr/include/features.h:367:25: fatal error: sys/cdefs.h: No such file or
> directory
> compilation terminated.
> Testing package @apache-mynewt-core/kernel/os/test
> Compiling bootutil_misc.c
> In file included from /usr/include/assert.h:35:0,
>                  from bootutil_misc.c:20:
> /usr/include/features.h:367:25: fatal error: sys/cdefs.h: No such file or
> directory
> compilation terminated.
> Testing package @apache-mynewt-core/net/ip/mn_socket/test
> Compiling bootutil_misc.c
> In file included from /usr/include/assert.h:35:0,
>                  from bootutil_misc.c:20:
> /usr/include/features.h:367:25: fatal error: sys/cdefs.h: No such file or
> directory
> compilation terminated.
> Testing package @apache-mynewt-core/net/nimble/host/test
> Compiling bootutil_misc.c
> In file included from /usr/include/assert.h:35:0,
>                  from bootutil_misc.c:20:
> /usr/include/features.h:367:25: fatal error: sys/cdefs.h: No such file or
> directory
> compilation terminated.
> Testing package @apache-mynewt-core/sys/config/test-fcb
> Compiling bootutil_misc.c
> In file included from /usr/include/assert.h:35:0,
>                  from bootutil_misc.c:20:
> /usr/include/features.h:367:25: fatal error: sys/cdefs.h: No such file or
> directory
> compilation terminated.
> Testing package @apache-mynewt-core/sys/config/test-nffs
> Compiling bootutil_misc.c
> In file included from /usr/include/assert.h:35:0,
>                  from bootutil_misc.c:20:
> /usr/include/features.h:367:25: fatal error: sys/cdefs.h: No such file or
> directory
> compilation terminated.
> Testing package @apache-mynewt-core/sys/flash_map/test
> Compiling bootutil_misc.c
> In file included from /usr/include/assert.h:35:0,
>                  from bootutil_misc.c:20:
> /usr/include/features.h:367:25: fatal error: sys/cdefs.h: No such file or
> directory
> compilation terminated.
> Testing package @apache-mynewt-core/sys/log/test
> Compiling bootutil_misc.c
> In file included from /usr/include/assert.h:35:0,
>                  from bootutil_misc.c:20:
> /usr/include/features.h:367:25: fatal error: sys/cdefs.h: No such file or
> directory
> compilation terminated.
> Testing package @apache-mynewt-core/util/cbmem/test
> Compiling bootutil_misc.c
> In file included from /usr/include/assert.h:35:0,
>                  from bootutil_misc.c:20:
> /usr/include/features.h:367:25: fatal error: sys/cdefs.h: No such file or
> directory
> compilation terminated.
> Error: Test failure(s):
> Passed tests: []
> Failed tests: [boot/boot_serial/test boot/bootutil/test
> crypto/mbedtls/test
> encoding/base64/test encoding/json/test fs/fcb/test fs/nffs/test
> kernel/os/test net/ip/mn_socket/test net/nimble/host/test
> sys/config/test-fcb sys/config/test-nffs sys/flash_map/test sys/log/test
> util/cbmem/test]
> exit status 1

You're probably running the standard gcc for 64-bit machines. It doesn't
support 32-bit. You need to install multiboot gcc. What distro are you
using? (btw, try looking for a package named something like
multiboot-gcc).

Reply via email to