Xiang Xiao
beb38917d1
signal: Replace NuttX special SIGWORK with SIGPAGING(SIGRTMIN)
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-03-26 08:31:36 -06:00
chao an
3428d15d04
libc/math: rename libc/math.csv to libm/libm.csv
...
Signed-off-by: chao an <anchao@xiaomi.com>
2023-03-24 14:58:10 -03:00
Petro Karashchenko
5651715486
signal: remove unused SIGCONDTIMEDOUT
...
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-03-23 17:17:25 -06:00
Petro Karashchenko
a261439b8b
libs/libx: relax compiler check for workaround with "GCC 12.2"
...
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-03-21 21:59:30 -03:00
chao an
c839fc45af
libc/settimeofday: correct prototype of settimeofday()
...
Signed-off-by: chao an <anchao@xiaomi.com>
2023-03-21 11:16:30 -03:00
Xiang Xiao
b63994b7f7
drivers/serial: Always support c_oflag, c_iflag and c_lflag in termios
...
CONFIG_SERIAL_TERMIOS only decide whether to support c_cflag field since
many terminal application need the first three fields to work correctly.
For more information please reference:
https://www.mail-archive.com/dev@nuttx.apache.org/msg09321.html
before this change(olimexino-stm32:tiny):
text data bss dec hex filename
34884 328 1768 36980 9074 nuttx
after this change:
text data bss dec hex filename
35052 340 1768 37160 9128 nuttx
delta
text data bss dec hex filename
168 12 0 180 b4 nuttx
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-03-19 14:54:59 -06:00
zhangyuan21
cf56e4113a
arch: remove unnecessary sem_setprotocol code
...
Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-03-17 16:53:19 -03:00
yinshengkai
1cc3fd59ed
libc/syslogstream: fix nxstyle error
...
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-03-13 22:24:53 +02:00
yinshengkai
ca290e85ea
libc: stream adds length check
...
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-03-13 22:24:53 +02:00
Karel Kočí
62661600b2
treewide: add DOWNLOAD variable as unification of curl call
...
This is a followup to the commit
03b164f59c
.
2023-03-08 17:05:05 +08:00
yinshengkai
81a4f21f1b
libc/libvsprintf: use puts to replace the putc
...
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-03-08 16:56:17 +08:00
yinshengkai
b8e622ea5d
libc/stream: unify stream behavior
...
Return the error code when all gets occur when an error is wrong
and return immediately when obtaining any valid data
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-03-04 01:48:22 +08:00
yinshengkai
205ca26556
libc/streams: Implement gets/puts for all streams
...
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-03-03 00:49:04 +08:00
Huang Qi
dfc70b1ddb
libc/stdio: Implement lib_get_stream
...
Use lib_get_stream() to fetch stdin/stdout/stderr,
since is more easy to works with other language by function call
than export native C structure memory layout.
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-03-02 09:56:57 +01:00
Huang Qi
b99a96a7d0
stream: Exchange name of lib_rawsostream.c and lib_rawoutstream.c
...
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-03-01 10:07:36 -03:00
Huang Qi
b96035885a
stdio: Implement simple buffered out stream for vdprintf
...
Improve performance for raw fd based printf like operation.
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-03-01 13:08:59 +09:00
YAMAMOTO Takashi
e9158efd42
libcxx.defs: Disable a warning and explain why
2023-02-27 23:55:52 +08: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
yinshengkai
8d16fa04df
libc/stream: Implement lowoutstream_puts
...
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-02-25 18:39:27 +08:00
chenrun1
4f3c73fb45
libc/lib_bzero:Add bzero prototype.
...
Implement the bzero function as an alternative to macro expansion.
2023-02-25 08:07:07 +02:00
lilei19
38f64f559d
change strcpy to strlcpy
...
Signed-off-by: lilei19 <lilei19@xiaomi.com>
2023-02-24 12:15:40 +08:00
Xiang Xiao
68ff73c5fb
stdio: lib_fgets convert \r\n to \n
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-02-24 10:39:48 +08:00
Xiang Xiao
cd74a1df22
libc/stdio: Make gets/gets_s work without CONFIG_FILE_STREAM
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-02-24 10:39:48 +08:00
chenrun1
5430de72f8
libc/lib_rawmemchr.c:Add rawmemchr methon.
2023-02-24 04:06:04 +08:00
Huang Qi
ca61c40453
stdio: Remove CONFIG_EOL_IS_XXX
...
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-02-24 00:35:19 +08:00
Xiang Xiao
8b4ecac6c2
libc: Move math library from libs/libc/math to libs/libm/libm
...
to prepare the support of other implementation e.g.:
https://github.com/JuliaMath/openlibm
https://gitlab.com/gtd-gmbh/libmcs
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-02-23 10:40:07 +02:00
chao an
0f8ecc0150
libs/libc: export exit() if configured in flat mode
...
Signed-off-by: chao an <anchao@xiaomi.com>
2023-02-23 13:50:03 +08:00
Xiang Xiao
a05ab2ab49
libc: Remove dependence of LIBC_FLOATINGPOINT and LIBC_LONG_LONG from LIBC_NUMBERED_ARGS
...
since LIBC_NUMBERED_ARGS can work without both
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-02-22 16:37:48 +08:00
lilei19
e6e2017d3c
fix a bug of strtof
2023-02-22 01:20:21 +08:00
Ville Juven
f8d3032732
libc/lib_assert.c: Remove the re-definition of abort()
...
This should now be irrelevant, as abort() is forwarded to _exit() instead.
2023-02-22 01:10:39 +08:00
Ville Juven
07039b8a36
lib_abort.c: Change call to userspace exit() into syscall _exit()
...
The POSIX standard dictates that during abnormal termination the functions
registered by atexit() are _not_ called, also flushing the streams is
optional. So in this case, it is perfectly legal / better to call the
kernel system call _exit() instead.
This fixes regression issues caused by removal exit() from the kernel.
2023-02-22 01:10:39 +08:00
chao an
5fac313df7
libs/libxx: Fix typo in shell expressions
...
Signed-off-by: chao an <anchao@xiaomi.com>
2023-02-22 01:05:46 +08:00
chao an
1d41182755
libs/libxx: check GCC version before set special flags
...
Signed-off-by: chao an <anchao@xiaomi.com>
2023-02-21 15:33:18 +08:00
chao an
e29d275ef8
libs/libcxx: Workaround -Wmaybe-uninitialized warning with "GCC 12.2"
...
Signed-off-by: chao an <anchao@xiaomi.com>
2023-02-20 19:26:55 +08:00
Xiang Xiao
fa3e0faffc
fs: Map FD_SETSIZE to OPEN_MAX instead hardcoding 256
...
and change the default value of LIBC_OPEN_MAX to 256.
Here has more discussion:
https://www.mail-archive.com/dev@nuttx.apache.org/msg09095.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-02-19 19:17:20 +02:00
Ville Juven
e9ef70e24b
sched/assert: Call abort() instead of exit() in assert
...
POSIX dictates that assert() terminates via abort(), even though in NuttX
abort() just calls exit(EXIT_FAILURE) it is better to use the correct
API here, if at some point a proper implementation for abort() is made.
Also, as the kernel must not use abort() which is a userspace API, direct
the exit to PANIC() if for some reason _assert() returns (it should not
but trap it here just in case).
2023-02-17 23:07:17 +08:00
Ville Juven
df1d7dd480
libc/exit: Purge calls to userspace API exit() from kernel
...
Remove calls to the userspace API exit() from the kernel. The problem
with doing such calls is that the exit functions are called with kernel
mode privileges which is a big security no-no.
2023-02-17 23:07:17 +08:00
Fotis Panagiotopoulos
85ceb7920e
Typo fixes.
2023-02-17 11:17:11 -03:00
Takeyoshi Kikuchi
70ce4b4fc1
libc: unistd: lib_getrlimit: set cur/max value for RLIMIT_NOFILE to "OPEN_MAX".
...
Signed-off-by: Takeyoshi Kikuchi <kikuchi@centurysys.co.jp>
2023-02-17 18:07:30 +08:00
Takeyoshi Kikuchi
c4fc414b09
libc: unistd: lib_getrlimit: use INT_MAX as dummy rlim_max value.
...
Signed-off-by: Takeyoshi Kikuchi <kikuchi@centurysys.co.jp>
2023-02-17 18:07:30 +08:00
Takeyoshi Kikuchi
2e5a20612c
libc: unistd: lib_getrlimit: return a value for RLIMIT_NOFILE request.
...
In the Nim language "selectors"(I/O multiplexing) module, the maximum
number of file descriptors is obtained with getrlimit() as follows.
var fdLim: RLimit
var res = int(getrlimit(RLIMIT_NOFILE, fdLim))
if res >= 0:
res = int(fdLim.rlim_cur) - 1
To be able to use the same implementation as other POSIX-based OS,
getrlimit() should return a value.
(For now, let it return 128.)
Signed-off-by: Takeyoshi Kikuchi <kikuchi@centurysys.co.jp>
2023-02-17 18:07:30 +08:00
crafcat7
33b22f51da
libc/lib_memcpy.c: Add mempcpy method.
...
Signed-off-by: crafcat7 <chenrun1@xiaomi.com>
2023-02-17 15:15:19 +08:00
Nathan Hartman
409e2f3701
drivers/serial, libc/termios: Implement tcsendbreak
...
The TERMIOS(3) function tcsendbreak() and the IOCTLs TCSBRK and TCSBRKP
transmit a serial line Break.
Previously NuttX included an extern declaration for tcsendbreak() and
defines for TCSBRK and TCSBRKP but none of these were implemented.
Attempting to build programs that called tcsendbreak() would fail with
a linker error; attempting to use TCSBRK and TCSBRKP would result in an
error at runtime.
This changeset adds the tcsendbreak() function and handling for TCSBRK
and TCSBRKP; tcsendbreak() is implemented in terms of TCSBRK. Both
TCSBRK and TCSBRKP are implemented in terms of the BSD-compatible Break
IOCTLs TIOCSBRK and TIOCCBRK, which must be provided by the lower half
serial driver. Currently, not all lower half serial drivers in NuttX
support these IOCTLs. Those that do implement them may need one or more
Kconfig options to be set, such as `CONFIG_*_U[S]ART_BREAKS` and, on
some architectures, a separate `CONFIG_*_SERIALBRK_BSDCOMPAT`.
* drivers/serial/serial.c
(uart_tcsendbreak): New function.
(uart_ioctl): Implement TCSBRK and TCSBRKP.
* libs/libc/termios/lib_tcsendbreak.c
(): New file.
* libs/libc/termios/Make.defs
(CSRCS): Add lib_tcsendbreak.c to the build.
Thanks to Xiang Xiao for PR feedback.
Co-authored-by: Xiang Xiao <xiaoxiang781216@gmail.com>
2023-02-15 07:50:02 +08:00
Xiang Xiao
dc2e9b8771
libc: Move memfd related stuff to sys/mman.h
...
follow the freebsd definition:
https://github.com/freebsd/freebsd-src/blob/master/sys/sys/mman.h#L207-L228
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-02-13 16:00:37 +01:00
Huang Qi
a66f0a6369
stdlib: Guard fflush in exit with CONFIG_FILE_STREAM
...
If CONFIG_FILE_STREAM disabled, fflush is a undefined function.
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-02-12 00:09:29 +08:00
lilei19
23344846f6
fix some bug of strtold
...
with the test of sim:lua ,I have fixed some bug of error output
1.input: " " and error output string is "NULL"
2.input: "1.2e+", error output string is "NULL"
3.input: "." error output string is "NULL"
2023-02-10 22:45:24 +08:00
chao an
634baa5a2f
libs: workaround for Visual Studio(MSVC) Compiler Error C2124
...
D:\archer\code\nuttx\libs\libc\stdlib\lib_strtod.c: error C2124: divide or mod by zero
Windows MSVC restrictions, MSVC doesn't allow division through a
zero literal, but allows it through const variable set to zero
Reference:
https://docs.microsoft.com/en-us/cpp/error-messages/compiler-errors-1/compiler-error-c2124?view=msvc-170
Signed-off-by: chao an <anchao@xiaomi.com>
2023-02-09 20:11:55 +08:00
chao an
8761cc9bfc
libs: fix visual studio Compiler Error C2036
...
D:\code\nuttx\libs\libc\net\lib_inetpton.c(300,52): error C2036: "void *" : unknown size
Reference:
https://learn.microsoft.com/en-us/cpp/error-messages/compiler-errors-1/compiler-error-c2036?view=msvc-170
Signed-off-by: chao an <anchao@xiaomi.com>
2023-02-09 20:11:55 +08:00
chao an
e942a7c55e
build/Kconfig: fix warnings detected by kconfiglib
...
Signed-off-by: chao an <anchao@xiaomi.com>
2023-02-09 20:07:46 +08:00
chao an
3a0fdb019d
nuttx: replace all ARRAY_SIZE()/ARRAYSIZE() to nitems()
...
Signed-off-by: chao an <anchao@xiaomi.com>
2023-02-09 20:05:44 +08:00
dongjiuzhu1
14f8a6c2dd
fs: support openat/fchmodat/mkfifoat/fstatat/...at api
...
Refs to:
https://linux.die.net/man/2/openat
Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
2023-02-07 03:45:38 +08:00
lilei19
de21025702
fix a bug of strtold
...
if input is -1e308,The output should be -100000000......
but the output is -inf
2023-02-06 20:26:45 +08:00
chao an
02a9e76f73
misc/mutex: fix assertion if nxmutex_reset() before nxmutex_unlock()
...
sim/rpserver
NuttShell (NSH) NuttX-12.0.0
server> cu
_assert: Current Version: NuttX server 12.0.0 3ead669e7a-dirty Feb 2 2023 23:53:48 sim
_assert: Assertion failed : at file: libs/libc/misc/lib_mutex.c:303 task: cu 0x5662fff4
Signed-off-by: chao an <anchao@xiaomi.com>
2023-02-04 02:13:15 +08:00
chao an
7625126c91
Remove the remain MIN/MAX like macro
...
Signed-off-by: chao an <anchao@xiaomi.com>
2023-02-03 23:22:41 +08:00
yinshengkai
35ae47788b
libc: Keep printf("%pS", p) behavior consistent
...
When ALLSYMS is not turned on, %pS will be treated as %p
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-02-03 09:19:06 +02:00
chao an
4c8d244fae
sched/getpid: replace syscall getpid/tid/ppid() to kernel version
...
NuttX kernel should not use the syscall functions, especially after
enabling CONFIG_SCHED_INSTRUMENTATION_SYSCALL, all system functions
will be traced to backend, which will impact system performance.
Signed-off-by: chao an <anchao@xiaomi.com>
2023-02-02 10:33:01 +08:00
chao an
c9981036a5
nuttx/mutex: move mutex implement to libc
...
Signed-off-by: chao an <anchao@xiaomi.com>
2023-02-02 10:33:01 +08:00
Gustavo Henrique Nihei
e6b204f438
nuttx: Use MIN/MAX definitions from "sys/param.h"
...
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2023-02-01 23:47:44 +08:00
Huang Qi
4caf24a00c
libc/stdio: Minor comments fix
...
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2023-02-01 21:47:30 +08:00
yinshengkai
ab2b09e557
Revert "Makefile: fix redundant delimiters when using make V=1"
...
This reverts commit 64d39a8b7b
.
2023-02-01 20:39:52 +08:00
Nathan Hartman
c65a632788
libc/termios: Fix comment in cfmakeraw docstring.
2023-02-01 09:47:55 +08:00
yinshengkai
64d39a8b7b
Makefile: fix redundant delimiters when using make V=1
...
rm-none-eabi-ar rcs libc.a bin//lib_assert.o bin//lib_builtin_getname.o
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-01-31 15:12:36 -03:00
Zhe Weng
8819eeaf15
net: Implement shutdown() interface and tcp shutdown
...
Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
2023-01-31 11:15:01 +08:00
lilei19
1d8af7e105
add holder for mutex
...
Signed-off-by: lilei19 <lilei19@xiaomi.com>
2023-01-31 12:08:05 +09:00
Nathan Hartman
6b89b6f945
Remove executable permissions from source files
...
* arch/arm/src/sama5/sam_flexcom_spi.h,
arch/risc-v/src/mpfs/mpfs_ihc_sbi.c,
drivers/usbdev/adb.c,
libs/libc/math/lib_scalbn.c,
libs/libc/math/lib_scalbnf.c,
net/ipfrag/Make.defs,
net/ipfrag/ipfrag.c,
net/ipfrag/ipfrag.h,
net/ipfrag/ipv4_frag.c,
net/ipfrag/ipv6_frag.c: Remove executable permission.
2023-01-30 20:34:51 -03:00
wangxuedong
ba016eb5eb
libc/stdio: fix rounding errors for fractional values less than 1
...
Signed-off-by: wangxuedong <wangxuedong@xiaomi.com>
2023-01-30 23:39:56 +08:00
chao an
fa63da22ae
libs/netdb: add sanity check to avoid null pointer reference
...
Signed-off-by: chao an <anchao@xiaomi.com>
2023-01-30 23:37:29 +08:00
yinshengkai
2466c07aa3
libc/stream: fix syslogstream_addstring length error
...
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-01-30 14:27:04 +01:00
Xiang Xiao
631a8da1e2
sched: Map SCHED_OTHER to SCHED_FIFO or SCHED_RR
...
this behaviour is explicitly specified here:
https://pubs.opengroup.org/onlinepubs/009695399/functions/xsh_chap02_08.html
and map SCHED_NORMAL to SCHED_OTHER like Linux:
https://man7.org/linux/man-pages/man7/sched.7.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-30 03:01:03 +02:00
zhanghongyu
4de0e626d0
Revert "netdb: fix access within misaligned address error"
...
This reverts commit 3f94828f6b
.
Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2023-01-29 14:35:01 +08:00
liangchaozhong
d8777fa77d
invalid dns cache entry after ttl expires
...
Log ttl after receive dns query and invalid dns cache entry when ttl expires.
Signed-off-by: liangchaozhong <liangchaozhong@xiaomi.com>
2023-01-29 14:32:33 +08:00
anjiahao
fcdc7afcb5
libc:lib_psfa_dddup2,add return check
...
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2023-01-28 23:23:47 +02:00
ligd
367fa640c1
asctime_r: add param check to asctime_r()
2023-01-28 23:23:12 +02:00
Xiang Xiao
7d66a16c53
Minor style clean up
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-28 19:53:20 +02:00
anjiahao
287467b81b
netdb: Add return check in rexec_af
...
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2023-01-27 15:31:28 -03:00
Xiang Xiao
819fbd22cc
sched: Implement tkill/tgkill
...
https://linux.die.net/man/2/tgkill
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-26 08:11:56 +02:00
Petro Karashchenko
f952b8456c
assert: switch from ASSERT(0/false) to PANIC
...
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-01-26 10:15:34 +08:00
Xiang Xiao
c05cdd6598
libc: Move on_exit and __cxa_atexit in lib_atexit.c
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-25 14:31:37 +02:00
Xiang Xiao
5333c30d45
libc: abort should always call exit not pthread_exit
...
since pthread_exit just exit the calling thread not the whole process
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-25 14:31:37 +02:00
Xiang Xiao
bcd1ebf260
libc: Implement quick_exit and at_quick_exit
...
Defined by c11:
https://en.cppreference.com/w/c/program/quick_exit
https://en.cppreference.com/w/c/program/at_quick_exit
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-25 14:31:37 +02:00
Xiang Xiao
43e7b13697
assert: Log the assertion expression in case of fail
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-24 15:00:19 -03:00
Xiang Xiao
8bf693b362
libc/pthread: Implement pthread_condattr_[set|get]pshared
...
https://pubs.opengroup.org/onlinepubs/009696799/functions/pthread_condattr_getpshared.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-24 13:53:02 -03:00
Xiang Xiao
c11cd7f103
libc/pthread: Implement pthread_attr_[set|get]stackaddr
...
https://pubs.opengroup.org/onlinepubs/009696799/functions/pthread_attr_getstackaddr.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-24 13:53:02 -03:00
Xiang Xiao
36b74bab02
libc/pthread: Implement pthread_rwlockattr API
...
https://pubs.opengroup.org/onlinepubs/9699919799/functions/pthread_rwlockattr_getpshared.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-24 13:53:02 -03:00
Xiang Xiao
82550887c2
c++: Change the default value of CXX_STANDARD from c++17 to gnu++17
...
since many 3rd party code use some gnu c++ extension
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-19 08:21:48 +01:00
Masayuki Ishikawa
dc454765fb
Revert "add holder for mutex"
...
This reverts commit fc176addeb
.
2023-01-19 06:04:48 +09:00
lilei19
fc176addeb
add holder for mutex
...
Signed-off-by: lilei19 <lilei19@xiaomi.com>
2023-01-18 17:40:58 +08:00
zhangyuan21
acd108a5ed
pthread: fixed pthread_cancel and pthread_exit crash in SMP mode
...
1. When pthread exit, set the default cancellability state to NONCANCELABLE state.
2. Make sure modify tcb->flags is atomic operations.
Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-01-18 11:57:40 +08:00
Xiang Xiao
f64da13e9b
libxx: Add CXX_STANDARD to select -std=c++??
...
and default to "c++17"
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-16 15:41:57 +02:00
lilei19
04f15d9dc1
fix the bug of strtold
2023-01-15 19:57:56 +08:00
Xiang Xiao
ee9787a254
libc: Let _SC_PAGESIZE return 4096 when CONFIG_MM_PGSIZE isn't defined
...
since most application doesn't expect the page size equals one
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-15 08:39:19 +02:00
dongjiuzhu1
28027d0bee
libc/versionsort: support versionsort and strverscmp
...
Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
2023-01-15 11:24:40 +08:00
lilei19
1f95cfdde8
fix the some else bug of strtold
...
I accidentally changed it when I was optimizing the code
Signed-off-by: lilei19 <lilei19@xiaomi.com>
2023-01-13 15:11:20 +02:00
Xiang Xiao
695f42f8d2
net: Move accept to libc after https://github.com/apache/nuttx/pull/8083
...
since accept can simply forward to kernel accept4 function
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-13 11:23:42 +02:00
lilei19
120594079a
add function for strtof
2023-01-12 23:46:23 +08:00
zhanghongyu
4de3387eb2
getaddrinfo: add AI_NUMERICHOST flag handle
...
Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2023-01-12 01:40:11 +08:00
Xuxingliang
431e31b6b2
libc/math: add simple implementation for sincos API
...
Signed-off-by: Xuxingliang <xuxingliang@xiaomi.com>
2023-01-12 00:07:44 +08:00
Xiang Xiao
ef65d443ad
sem: Remove PRIOINHERIT_FLAGS_ENABLE and use SEM_PRIO_INHERIT instead
...
and refine the code to prepare the support of new flags
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-11 17:35:28 +02:00
zhangyuan21
e34f79aa28
libc: don't redefined __ARM_ARCH_XXX when __ARM_ARCH defined
...
Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-01-10 14:58:35 +02:00
zhangyuan21
fae5aef4fe
libc: add arm64 libc function
...
Porting memory and string optimize functions from newlib and bionic
Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-01-10 11:31:26 +08:00