File tree Expand file tree Collapse file tree 6 files changed +49
-5
lines changed
Expand file tree Collapse file tree 6 files changed +49
-5
lines changed Original file line number Diff line number Diff line change @@ -47,9 +47,11 @@ struct pthread_attr {
4747 int32_t detachstate ;
4848 uint32_t initialized ;
4949};
50- #if defined(CONFIG_MINIMAL_LIBC ) || defined(CONFIG_PICOLIBC ) || defined(CONFIG_ARMCLANG_STD_LIBC )
50+ #if defined(CONFIG_MINIMAL_LIBC ) || defined(CONFIG_PICOLIBC ) || defined(CONFIG_ARMCLANG_STD_LIBC ) \
51+ || defined(CONFIG_ARCMWDT_LIBC )
5152typedef struct pthread_attr pthread_attr_t ;
5253#endif
54+
5355BUILD_ASSERT (sizeof (pthread_attr_t ) >= sizeof (struct pthread_attr ));
5456
5557typedef uint32_t pthread_t ;
@@ -63,7 +65,8 @@ typedef uint32_t pthread_mutex_t;
6365struct pthread_mutexattr {
6466 int type ;
6567};
66- #if defined(CONFIG_MINIMAL_LIBC ) || defined(CONFIG_PICOLIBC ) || defined(CONFIG_ARMCLANG_STD_LIBC )
68+ #if defined(CONFIG_MINIMAL_LIBC ) || defined(CONFIG_PICOLIBC ) || defined(CONFIG_ARMCLANG_STD_LIBC ) \
69+ || defined(CONFIG_ARCMWDT_LIBC )
6770typedef struct pthread_mutexattr pthread_mutexattr_t ;
6871#endif
6972BUILD_ASSERT (sizeof (pthread_mutexattr_t ) >= sizeof (struct pthread_mutexattr ));
@@ -74,7 +77,8 @@ typedef uint32_t pthread_cond_t;
7477struct pthread_condattr {
7578};
7679
77- #if defined(CONFIG_MINIMAL_LIBC ) || defined(CONFIG_PICOLIBC ) || defined(CONFIG_ARMCLANG_STD_LIBC )
80+ #if defined(CONFIG_MINIMAL_LIBC ) || defined(CONFIG_PICOLIBC ) || defined(CONFIG_ARMCLANG_STD_LIBC ) \
81+ || defined(CONFIG_ARCMWDT_LIBC )
7882typedef struct pthread_condattr pthread_condattr_t ;
7983#endif
8084BUILD_ASSERT (sizeof (pthread_condattr_t ) >= sizeof (struct pthread_condattr ));
Original file line number Diff line number Diff line change 1313extern "C" {
1414#endif
1515
16+ #if defined(CONFIG_MINIMAL_LIBC ) || defined(CONFIG_PICOLIBC ) || defined(CONFIG_ARMCLANG_STD_LIBC ) \
17+ || defined(CONFIG_ARCMWDT_LIBC )
18+
1619#ifdef CONFIG_PTHREAD_IPC
1720
18- #if defined(CONFIG_MINIMAL_LIBC ) || defined(CONFIG_PICOLIBC ) || defined(CONFIG_ARMCLANG_STD_LIBC )
1921typedef struct {
2022 int is_initialized ;
2123 int init_executed ;
Original file line number Diff line number Diff line change @@ -25,7 +25,8 @@ extern "C" {
2525/* Priority based preemptive scheduling policy */
2626#define SCHED_RR 2
2727
28- #if defined(CONFIG_MINIMAL_LIBC ) || defined(CONFIG_PICOLIBC ) || defined(CONFIG_ARMCLANG_STD_LIBC )
28+ #if defined(CONFIG_MINIMAL_LIBC ) || defined(CONFIG_PICOLIBC ) || defined(CONFIG_ARMCLANG_STD_LIBC ) \
29+ || defined(CONFIG_ARCMWDT_LIBC )
2930struct sched_param {
3031 int sched_priority ;
3132};
Original file line number Diff line number Diff line change 1+ /*
2+ * Copyright (c) 2023 Synopsys.
3+ *
4+ * SPDX-License-Identifier: Apache-2.0
5+ */
6+
7+ /* MWDT has no it's own cdefs. Add this one for satisfy dependencies */
Original file line number Diff line number Diff line change 1+ /*
2+ * Copyright (c) 2023 Synopsys.
3+ *
4+ * SPDX-License-Identifier: Apache-2.0
5+ */
6+
7+ #ifndef LIB_LIBC_ARCMWDT_INCLUDE_SYS_TYPES_H_
8+ #define LIB_LIBC_ARCMWDT_INCLUDE_SYS_TYPES_H_
9+
10+ #include_next "sys/types.h"
11+
12+ #define _DEV_T_DECLARED
13+ #define _INO_T_DECLARED
14+ #define _NLINK_T_DECLARED
15+ #define _UID_T_DECLARED
16+ #define _GID_T_DECLARED
17+
18+ #endif /* LIB_LIBC_ARCMWDT_INCLUDE_SYS_TYPES_H_ */
Original file line number Diff line number Diff line change 1313#include <unistd.h>
1414#include <errno.h>
1515
16+ #ifndef STDIN_FILENO
17+ #define STDIN_FILENO 0
18+ #endif
19+
20+ #ifndef STDOUT_FILENO
21+ #define STDOUT_FILENO 1
22+ #endif
23+
24+ #ifndef STDERR_FILENO
25+ #define STDERR_FILENO 2
26+ #endif
27+
1628static int _stdout_hook_default (int c )
1729{
1830 ARG_UNUSED (c );
You can’t perform that action at this time.
0 commit comments