Commit Graph

166 Commits

Author SHA1 Message Date
Michal Lenc
51bae917b7 ci: add fmemopen test and merge fopencookie and fmemopen to stdio test
CI test for fmemopen() function was added. The test was merged with
fopencookie interface test and merged into single test_stdio.

Signed-off-by: Michal Lenc <michallenc@seznam.cz>
2023-10-27 08:55:24 +08:00
xuxin19
906699e0a5 ci:enable RISC-V qemu cmake build ci
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2023-10-26 21:01:46 +08:00
Michal Lenc
2d8fc9522f ci: add error status check for ostest
ostest should return OK (0) if successful.

Signed-off-by: Michal Lenc <michallenc@seznam.cz>
2023-10-19 21:39:24 +08:00
Michal Lenc
f43701c7c9 ci: fix file system CI test
File system CI test was not testing the correct behavior of scanf and just
checked whether program did not end with hard fault. This adds
functionality check and required configuration options to run FS test.

Signed-off-by: Michal Lenc <michallenc@seznam.cz>
2023-10-19 21:39:24 +08:00
Michal Lenc
7463052c8e ci: fix scanf CI test
Scanf CI test was not testing the correct behavior of scanf and just
checked whether program did not end with hard fault. This adds
functionality check and required configuration options to run scanf
test.

Signed-off-by: Michal Lenc <michallenc@seznam.cz>
2023-10-19 21:39:24 +08:00
Michal Lenc
6e4ffb9ea1 ci: add fopencookie test
This adds fopencookie test for simulator CI.

Signed-off-by: Michal Lenc <michallenc@seznam.cz>
2023-10-18 21:13:01 +08:00
Xiang Xiao
65e2a68e48 tools/ci: Skip build sabre-6quad:libcxx temporarily
since linker can't find basic_string::~basic_string() oddly:
arm-none-eabi-ld: /home/xiaoxiang/backup/os/nuttx/nuttx/staging/libxx.a(libcxx/src/locale.o): in function `__tcf_0':
/home/xiaoxiang/backup/os/nuttx/nuttx/libs/libxx/libcxx/src/locale.cpp:4941: undefined reference to `std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >::~basic_string()'

another fix is removing the follow code from _LIBCPP_STRING_V1_EXTERN_TEMPLATE_LIST and _LIBCPP_STRING_UNSTABLE_EXTERN_TEMPLATE_LIST:
_Func(_LIBCPP_FUNC_VIS basic_string<_CharType>::~basic_string()) \

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-24 08:40:10 +03:00
Xiang Xiao
f6681218f4 ci: Update aarch64 gcc toolchain to 12.3.rel1
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-19 22:37:54 +08:00
Huang Qi
7d3f11af1f cibuild.sh: Using GCC from xPack for riscv
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-09-19 12:59:48 +03:00
Huang Qi
89e409a194 tools: Switch riscv GCC to 12.3
GCC13 have compatibility issue with libcxx (need libcxx 17+).

Please refer to: https://github.com/llvm/llvm-project/issues/62396

Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-09-19 11:42:51 +08:00
Huang Qi
43610f75f1 tools: Use GCC 13.2 from xPack for risc-v 2023-09-18 21:25:13 +08:00
Xiang Xiao
43af86bdfe tools/ci: Fix "flock: Command not found" on macOS
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-14 15:19:59 +08:00
Xiang Xiao
5217dd36f0 tools/ci: Unify the version print: command xxx --version
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-14 15:19:59 +08:00
Petro Karashchenko
03614d60ee tools/ci: ensure removing python and openssl related commands
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-08-29 22:19:59 +08:00
raiden00pl
03b058dddc boards/stm32h7: add nucleo-h745zi 2023-08-26 03:35:32 +08:00
fangfei6
d0f84bd745 tools/ci: Update docker to ubuntu 22.04 and Update Renesas toolchain 8.3.0
Signed-off-by: fangfei6 <fangfei6@xiaomi.com>
2023-08-24 00:03:06 +08:00
Xiang Xiao
a107cc2ee0 tools/ci: Update arm toolchain to 12.3rel1
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-08-23 10:12:52 +08:00
raiden00pl
3fd8dab991 ci: enable cmake for nucleo-f446re/systemview 2023-08-22 23:37:08 +08:00
Xiang Xiao
e2166eca55 Revert "ci/Dockerfile: Update riscv toolchain to gcc13.2.0"
This reverts commit 7b34583996.
2023-08-22 22:33:37 +08:00
Xiang Xiao
7b34583996 ci/Dockerfile: Update riscv toolchain to gcc13.2.0
and change the default toolchain to riscv32-unknown-elf-

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-08-22 15:14:44 +08:00
Xiang Xiao
cd93b8c5ab tools/ci: Don't install CodeChecker in the final docker image
since it fail to install on ubuntu 22.04:
ERROR: failed to solve: process "/bin/sh -c pip3 install CodeChecker" did not complete successfully: exit code: 1
Error: buildx failed with: ERROR: failed to solve: process "/bin/sh -c pip3 install CodeChecker" did not complete successfully: exit code: 1

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-08-18 15:35:59 +03:00
Xiang Xiao
c04d8560d3 tools/ci: Update the final docker image to ubuntu 22.04
g++ need update to the new version for libcxx 15.0.7

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-08-18 15:35:59 +03:00
raiden00pl
ec97cc8a31 ci: build arduino-nano-33ble and arduino-nano-33ble-rev2 with cmake 2023-08-14 20:42:59 +08:00
Xiang Xiao
6ba12d4b96 ci: Fix the openssl installation fail on macOS
+ brew install u-boot-tools
==> Fetching dependencies for u-boot-tools: openssl@3
==> Fetching openssl@3
==> Downloading https://ghcr.io/v2/homebrew/core/openssl/3/manifests/3.1.2-1
Already downloaded: /Users/runner/work/nuttx/nuttx/sources/tools/homebrew/downloads/d235bbcbe9c405bfbe837454515b9cb2793542891a2050e5948a94f596e2a51e--openssl@3-3.1.2-1.bottle_manifest.json
==> Downloading https://ghcr.io/v2/homebrew/core/openssl/3/blobs/sha256:2bea791e9eacc59e0a9099065f3229afaf2b68a9b7b3136ec508103985b1176c
Already downloaded: /Users/runner/work/nuttx/nuttx/sources/tools/homebrew/downloads/d082c3abe2fd32b11d857fb7111adc0fc02a0b345044c07f2e7db7160f15300e--openssl@3--3.1.2.ventura.bottle.1.tar.gz
==> Fetching u-boot-tools
==> Downloading https://ghcr.io/v2/homebrew/core/u-boot-tools/manifests/2023.07.02
Already downloaded: /Users/runner/work/nuttx/nuttx/sources/tools/homebrew/downloads/5e0a4a2e6eda6e1dc965b8523549685de4c2da7f1c68d8431bbd7c536642bfee--u-boot-tools-2023.07.02.bottle_manifest.json
==> Downloading https://ghcr.io/v2/homebrew/core/u-boot-tools/blobs/sha256:bfd54176e94ffd2ad380ab7cbd25e091afe9338b17343881cd957f5f6c30d5ed
Already downloaded: /Users/runner/work/nuttx/nuttx/sources/tools/homebrew/downloads/8ce6e97fdea98c1581ffe5f52ccd876f3cbf373da9a70f889948b5c888528402--u-boot-tools--2023.07.02.ventura.bottle.tar.gz
==> Installing dependencies for u-boot-tools: openssl@3
==> Installing u-boot-tools dependency: openssl@3
==> Pouring openssl@3--3.1.2.ventura.bottle.1.tar.gz
Error: Could not symlink bin/openssl
Target /usr/local/bin/openssl
is a symlink belonging to openssl@1.1. You can unlink it:
  brew unlink openssl@1.1

To force the link and overwrite all conflicting files:
  brew link --overwrite openssl@3

To list all files that would be deleted:
  brew link --overwrite --dry-run openssl@3

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-08-08 22:39:33 +03:00
raiden00pl
4cba6630fb cmake: enable more stm32 builds in ci 2023-08-07 05:44:52 -07:00
Petro Karashchenko
e26b015644 Revert "tools/ci/testrun: increase ostest timeout on CI"
This reverts commit eab86b72c4.
2023-08-02 19:48:24 -07:00
Petro Karashchenko
eab86b72c4 tools/ci/testrun: increase ostest timeout on CI
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-07-31 18:58:48 -07:00
raiden00pl
e48d730273 cmake: enable more cmake builds 2023-07-25 06:18:22 -07:00
chao an
06af0d47aa tools/ci: add rpproxy/rpserver into cmake build
Signed-off-by: chao an <anchao@xiaomi.com>
2023-07-25 15:00:10 +02:00
raiden00pl
44b5eb3751 cmake: update docker cmake to 3.26.0 2023-07-24 09:53:22 -07:00
raiden00pl
26dda05cdf tools/ci: migrate some ci build configurations to CMake 2023-07-22 00:59:44 +08:00
chao an
df9f700c28 tools/ci: print cmake warning message only once
1. print cmake warning message only once
2. Touch Dockerfile to update the ci-docker

Signed-off-by: chao an <anchao@xiaomi.com>
2023-07-20 21:40:34 +08:00
YAMAMOTO Takashi
d524403c4c cibuild.sh: drop pip --force-reinstall for now
according to https://github.com/apache/nuttx/pull/7903
it was to fix "the macOS runners occasionally failing".

cython issue workaround seems more important because it always fails.
2023-07-19 13:40:20 +08:00
YAMAMOTO Takashi
8ff9ca064e CI: workaround Cython issue 2023-07-19 13:40:20 +08:00
chao an
7eff229838 tools/ci/checkpatch: add cmake style check into ci-check
Signed-off-by: chao an <anchao@xiaomi.com>
2023-07-18 10:09:48 -03:00
chao an
dc6f1406d1 tools/ci: migrate some ci build configurations to CMake
Signed-off-by: chao an <anchao@xiaomi.com>
2023-07-15 23:32:36 +08:00
Petro Karashchenko
d7af2f4c0a tools/ci: remove 'brew update' needed for AVR toolchain installation on OSX
Remove 'brew update' introduced by https://github.com/apache/nuttx-testing/pull/88
as it seems to be not longer needed

Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-07-03 19:16:19 -03:00
chao an
df6d799577 tools/ci: Update GNU Arm Embedded Toolchain to Version 12.2-2022.12.22
x86_64 Linux hosted cross toolchains
AArch32 bare-metal target (arm-none-eabi)

arm-gnu-toolchain-12.2.rel1-x86_64-arm-none-eabi.tar.xz

Remove toolchain workaround which already fixed by ARM:
https://developer.arm.com/downloads/-/arm-gnu-toolchain-downloads
https://community.arm.com/support-forums/f/compilers-and-libraries-forum/53470/arm-gnu-toolchain-11-3-rel1-x86_64-arm-none-eabi-wrong-newlib-version-strings-error-when-stdlib-h-is-included

Signed-off-by: chao an <anchao@xiaomi.com>
2023-06-26 20:03:38 +08:00
zhangyuan21
514e77b75e semaphore: Optimize priority inheritance with only one holder
This PR is a modification that optimizes priority inheritance
for only one holder. After the above modifications are completed,
the mutex lock->unlock process that supports priority inheritance
can be optimized by 200 cycles.

Before modify: 2000 cycle
After modify: 1742 cycle

Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-06-17 08:26:46 +03:00
Fotis Panagiotopoulos
1530e04f20 ostest: Enabled KASAN, UBSAN & assertions. 2023-04-19 02:44:48 +08:00
chao an
41f1044fa0 ci/cibuild.sh: upgrade esptool to 4.5.1
Signed-off-by: chao an <anchao@xiaomi.com>
2023-04-12 23:14:45 +03:00
Lucas Saavedra Vaz
1b87c86619 boards: Update and fix configs for ESP boards 2023-03-25 12:23:35 +02:00
Petro Karashchenko
f84f30fe17 tools/ci: upgrade to the latest Xtensa ESP32 toolchains
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-03-21 21:59:30 -03:00
chao an
a7de849944 tools/ci: setup wasi-sdk/wamrc into cibuild
wasi-sdk:
https://github.com/WebAssembly/wasi-sdk
wamrc:
https://github.com/bytecodealliance/wasm-micro-runtime

Signed-off-by: chao an <anchao@xiaomi.com>
2023-03-04 01:40:25 +08:00
zhangyuan21
83bbb54558 tools/ci: Don't build simusb on macOS
Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-03-03 14:31:30 -03:00
chao an
b01b93cb54 sim/wamr: add example of WAMR(WebAssembly Micro Runtime)
Added compilation rules to support the construction of WebAssembly(WASM/WAMR):

1. Compile Toolchain
 1> Download WASI sdk and export the WASI_SDK_PATH path:

$ wget https://github.com/WebAssembly/wasi-sdk/releases/download/wasi-sdk-19/wasi-sdk-19.0-linux.tar.gz
$ tar xf wasi-sdk-19.0-linux.tar.gz
Put wasi-sdk-19.0 to your host WASI_SDK_PATH environment variable, like:
$ export WASI_SDK_PATH=`pwd`/wasi-sdk-19.0

 2> Download Wamr "wamrc" AOT compiler and export to the PATH:
$ mkdir wamrc
$ wget https://github.com/bytecodealliance/wasm-micro-runtime/releases/download/WAMR-1.1.2/wamrc-1.1.2-x86_64-ubuntu-20.04.tar.gz
$ tar xf wamrc-1.1.2-x86_64-ubuntu-20.04.tar.gz
$ export PATH=$PATH:$PWD

2. Configuring and running

 1> Configuring sim/wamr and compile:

nuttx$ ./tools/configure.sh  sim/wamr
nuttx$ make
...
Wamrc Generate AoT: /home/archer/code/nuttx/n5/apps/wasm/hello.aot
Wamrc Generate AoT: /home/archer/code/nuttx/n5/apps/wasm/coremark.aot
LD:  nuttx

 2> Copy the generated wasm file(Interpreter/AoT)

nuttx$ cp ../apps/wasm/hello.aot .
nuttx$ cp ../apps/wasm/hello.wasm .
nuttx$ cp ../apps/wasm/coremark.wasm .

 3> Run iwasm

nuttx$ ./nuttx
NuttShell (NSH) NuttX-10.4.0
nsh> iwasm /data/hello.wasm
Hello, World!!
nsh> iwasm /data/hello.aot
Hello, World!!
nsh> iwasm /data/coremark.wasm
2K performance run parameters for coremark.
CoreMark Size    : 666
Total ticks      : 12000
Total time (secs): 12.000000
Iterations/Sec   : 5.000000
Iterations       : 60
Compiler version : Clang 15.0.7
Compiler flags   : Using NuttX compilation options
Memory location  : Defined by the NuttX configuration
seedcrc          : 0xe9f5
[0]crclist       : 0xe714
[0]crcmatrix     : 0x1fd7
[0]crcstate      : 0x8e3a
[0]crcfinal      : 0xa14c
Correct operation validated. See README.md for run and reporting rules.
CoreMark 1.0 : 5.000000 / Clang 15.0.7 Using NuttX compilation options / Defined by the NuttX configuration

Signed-off-by: chao an <anchao@xiaomi.com>
2023-03-02 09:56:35 +01:00
Xiang Xiao
2c5f653bfd Remove the tail spaces from all files except Documentation
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-02-26 13:24:24 -08:00
zhangyuan21
3c162b1e14 tools/ci: add libusb1.0 package
Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-02-26 22:39:57 +08:00
chao an
b8ef55d201 Revert "tools/ci: Update GNU Arm Embedded Toolchain to Version 12.2-2022.12.22"
This reverts commit 809252e3fd.

Wrong warning array subscript [0] is outside array bounds:

|  chip/lpc43_usb0dev.c: In function 'lpc43_getframe':
|  arch/arm/src/common/arm_internal.h:134:25: warning: array subscript 0 is outside array bounds of 'volatile uint32_t[0]' {aka 'volatile long unsigned int[]'} [-Warray-bounds]
|    134 | #define getreg32(a)    (*(volatile uint32_t *)(a))
|        |                        ~^~~~~~~~~~~~~~~~~~~~~~~~~~
|  chip/lpc43_usb0dev.c:347:33: note: in expansion of macro 'getreg32'
|    347 | # define lpc43_getreg(addr)     getreg32(addr)
|        |                                 ^~~~~~~~
|  chip/lpc43_usb0dev.c:2605:15: note: in expansion of macro 'lpc43_getreg'
|   2605 |   return (int)lpc43_getreg(LPC43_USBDEV_FRINDEX_OFFSET);
|        |

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105523

Signed-off-by: chao an <anchao@xiaomi.com>
2023-02-20 20:05:13 +08:00
chao an
809252e3fd tools/ci: Update GNU Arm Embedded Toolchain to Version 12.2-2022.12.22
x86_64 Linux hosted cross toolchains
AArch32 bare-metal target (arm-none-eabi)

arm-gnu-toolchain-12.2.rel1-x86_64-arm-none-eabi.tar.xz

Remove toolchain workaround which already fixed by ARM:
https://developer.arm.com/downloads/-/arm-gnu-toolchain-downloads
https://community.arm.com/support-forums/f/compilers-and-libraries-forum/53470/arm-gnu-toolchain-11-3-rel1-x86_64-arm-none-eabi-wrong-newlib-version-strings-error-when-stdlib-h-is-included

Signed-off-by: chao an <anchao@xiaomi.com>
2023-02-20 16:20:39 +08:00