Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
BaiXuePrincess
rt-thread
提交
d43a68e9
R
rt-thread
项目概览
BaiXuePrincess
/
rt-thread
与 Fork 源项目一致
Fork自
RT-Thread / rt-thread
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
rt-thread
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
未验证
提交
d43a68e9
编写于
9月 28, 2021
作者:
B
Bernard Xiong
提交者:
GitHub
9月 28, 2021
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #5105 from mysterywolf/part
[libc]新建gcc文件夹,将newlib和partical文件夹并入
上级
ae49c3f5
c8068812
变更
22
隐藏空白更改
内联
并排
Showing
22 changed file
with
59 addition
and
69 deletion
+59
-69
bsp/ls1bdev/Kconfig
bsp/ls1bdev/Kconfig
+0
-4
bsp/ls1cdev/Kconfig
bsp/ls1cdev/Kconfig
+0
-4
bsp/ls2kdev/Kconfig
bsp/ls2kdev/Kconfig
+0
-4
components/finsh/msh.c
components/finsh/msh.c
+0
-15
components/libc/compilers/armlibc/syscalls.c
components/libc/compilers/armlibc/syscalls.c
+0
-10
components/libc/compilers/common/partial/ls/readme.md
components/libc/compilers/common/partial/ls/readme.md
+0
-9
components/libc/compilers/common/stdlib.c
components/libc/compilers/common/stdlib.c
+15
-5
components/libc/compilers/dlib/syscalls.c
components/libc/compilers/dlib/syscalls.c
+0
-7
components/libc/compilers/gcc/SConscript
components/libc/compilers/gcc/SConscript
+0
-0
components/libc/compilers/gcc/newlib/README.md
components/libc/compilers/gcc/newlib/README.md
+2
-1
components/libc/compilers/gcc/newlib/SConscript
components/libc/compilers/gcc/newlib/SConscript
+0
-0
components/libc/compilers/gcc/newlib/libc.c
components/libc/compilers/gcc/newlib/libc.c
+0
-0
components/libc/compilers/gcc/newlib/libc.h
components/libc/compilers/gcc/newlib/libc.h
+0
-0
components/libc/compilers/gcc/newlib/libc_syms.c
components/libc/compilers/gcc/newlib/libc_syms.c
+0
-0
components/libc/compilers/gcc/newlib/machine/time.h
components/libc/compilers/gcc/newlib/machine/time.h
+0
-0
components/libc/compilers/gcc/newlib/stdio.c
components/libc/compilers/gcc/newlib/stdio.c
+0
-0
components/libc/compilers/gcc/newlib/syscalls.c
components/libc/compilers/gcc/newlib/syscalls.c
+1
-10
components/libc/compilers/gcc/partial/SConscript
components/libc/compilers/gcc/partial/SConscript
+15
-0
components/libc/compilers/gcc/partial/mips/SConscript
components/libc/compilers/gcc/partial/mips/SConscript
+20
-0
components/libc/compilers/gcc/partial/mips/readme.md
components/libc/compilers/gcc/partial/mips/readme.md
+4
-0
components/libc/compilers/gcc/partial/mips/sys/select.h
components/libc/compilers/gcc/partial/mips/sys/select.h
+0
-0
components/libc/compilers/gcc/partial/readme.md
components/libc/compilers/gcc/partial/readme.md
+2
-0
未找到文件。
bsp/ls1bdev/Kconfig
浏览文件 @
d43a68e9
...
...
@@ -18,10 +18,6 @@ config PKGS_DIR
source "$RTT_DIR/Kconfig"
source "$PKGS_DIR/Kconfig"
config SOC_LS
bool
default y
config SOC_LS1B
bool
select RT_USING_COMPONENTS_INIT
...
...
bsp/ls1cdev/Kconfig
浏览文件 @
d43a68e9
...
...
@@ -19,10 +19,6 @@ source "$RTT_DIR/Kconfig"
source "$RTT_DIR/libcpu/mips/common/Kconfig"
source "$PKGS_DIR/Kconfig"
config SOC_LS
bool
default y
config SOC_LS1C300
bool
select RT_USING_COMPONENTS_INIT
...
...
bsp/ls2kdev/Kconfig
浏览文件 @
d43a68e9
...
...
@@ -22,10 +22,6 @@ source "$RTT_DIR/Kconfig"
source "$RTT_DIR/libcpu/mips/common/Kconfig"
source "$PKGS_DIR/Kconfig"
config SOC_LS
bool
default y
config SOC_LS2K1000
bool
select ARCH_MIPS64
...
...
components/finsh/msh.c
浏览文件 @
d43a68e9
...
...
@@ -257,21 +257,6 @@ int msh_exec_module(const char *cmd_line, int size)
rt_free
(
pg_name
);
return
ret
;
}
int
system
(
const
char
*
command
)
{
int
ret
=
-
RT_ENOMEM
;
char
*
cmd
=
rt_strdup
(
command
);
if
(
cmd
)
{
ret
=
msh_exec
(
cmd
,
rt_strlen
(
cmd
));
rt_free
(
cmd
);
}
return
ret
;
}
RTM_EXPORT
(
system
);
#endif
/* defined(RT_USING_MODULE) && defined(RT_USING_DFS) */
static
int
_msh_exec_cmd
(
char
*
cmd
,
rt_size_t
length
,
int
*
retp
)
...
...
components/libc/compilers/armlibc/syscalls.c
浏览文件 @
d43a68e9
...
...
@@ -319,16 +319,6 @@ int remove(const char *filename)
#endif
}
#if defined(RT_USING_FINSH) && defined(RT_USING_MODULE) && defined(RT_USING_DFS)
/* use system(const char *string) implementation in the msh */
#else
int
system
(
const
char
*
string
)
{
extern
int
__rt_libc_system
(
const
char
*
string
);
return
__rt_libc_system
(
string
);
}
#endif
#ifdef __MICROLIB
#include <stdio.h>
...
...
components/libc/compilers/common/partial/ls/readme.md
已删除
100644 → 0
浏览文件 @
ae49c3f5
This folder will be included when compiling the BSPs as follow:
-
ls1bdev
-
ls1cdev
-
ls2kdev
These files will be generated by scons automatically , and
**DO NOT**
change them:
-
sys/select.h
\ No newline at end of file
components/libc/compilers/common/stdlib.c
浏览文件 @
d43a68e9
...
...
@@ -25,11 +25,21 @@ void __rt_libc_exit(int status)
}
}
int
__rt_libc_system
(
const
char
*
string
)
{
#ifdef RT_USING_MSH
int
system
(
const
char
*
command
)
{
extern
int
msh_exec
(
char
*
cmd
,
rt_size_t
length
);
msh_exec
((
char
*
)
string
,
rt_strlen
(
string
));
#endif
return
0
;
int
ret
=
-
RT_ENOMEM
;
char
*
cmd
=
rt_strdup
(
command
);
if
(
cmd
)
{
ret
=
msh_exec
(
cmd
,
rt_strlen
(
cmd
));
rt_free
(
cmd
);
}
return
ret
;
}
RTM_EXPORT
(
system
);
#endif
components/libc/compilers/dlib/syscalls.c
浏览文件 @
d43a68e9
...
...
@@ -6,7 +6,6 @@
* Change Logs:
* Date Author Notes
* 2021-02-13 Meco Man implement exit() and abort()
* 2021-02-20 Meco Man add system()
*/
#include <rtthread.h>
...
...
@@ -17,9 +16,3 @@ void __exit (int status)
__rt_libc_exit
(
status
);
while
(
1
);
}
int
system
(
const
char
*
string
)
{
extern
int
__rt_libc_system
(
const
char
*
string
);
return
__rt_libc_system
(
string
);
}
components/libc/compilers/
common/partial
/SConscript
→
components/libc/compilers/
gcc
/SConscript
浏览文件 @
d43a68e9
文件已移动
components/libc/compilers/newlib/README.md
→
components/libc/compilers/
gcc/
newlib/README.md
浏览文件 @
d43a68e9
...
...
@@ -6,4 +6,5 @@ Please define RT_USING_LIBC and compile RT-Thread with GCC compiler.
## More Information
https://sourceware.org/newlib/libc.html#Reentrancy
\ No newline at end of file
https://sourceware.org/newlib/libc.html#Reentrancy
components/libc/compilers/newlib/SConscript
→
components/libc/compilers/
gcc/
newlib/SConscript
浏览文件 @
d43a68e9
文件已移动
components/libc/compilers/newlib/libc.c
→
components/libc/compilers/
gcc/
newlib/libc.c
浏览文件 @
d43a68e9
文件已移动
components/libc/compilers/newlib/libc.h
→
components/libc/compilers/
gcc/
newlib/libc.h
浏览文件 @
d43a68e9
文件已移动
components/libc/compilers/newlib/libc_syms.c
→
components/libc/compilers/
gcc/
newlib/libc_syms.c
浏览文件 @
d43a68e9
文件已移动
components/libc/compilers/newlib/machine/time.h
→
components/libc/compilers/
gcc/
newlib/machine/time.h
浏览文件 @
d43a68e9
文件已移动
components/libc/compilers/newlib/stdio.c
→
components/libc/compilers/
gcc/
newlib/stdio.c
浏览文件 @
d43a68e9
文件已移动
components/libc/compilers/newlib/syscalls.c
→
components/libc/compilers/
gcc/
newlib/syscalls.c
浏览文件 @
d43a68e9
...
...
@@ -85,6 +85,7 @@ void __libc_init_array(void)
#ifdef RT_USING_LIBC
#include <reent.h>
#include <stdio.h>
#include "libc.h"
#ifdef RT_USING_DFS
#include <dfs_posix.h>
#endif
...
...
@@ -92,10 +93,6 @@ void __libc_init_array(void)
#include <dlmodule.h>
#endif
#define DBG_TAG "newlib.syscalls"
#define DBG_LVL DBG_INFO
#include <rtdbg.h>
/* Reentrant versions of system calls. */
#ifndef _REENT_ONLY
...
...
@@ -311,12 +308,6 @@ _ssize_t _write_r(struct _reent *ptr, int fd, const void *buf, size_t nbytes)
#endif
}
void
_system
(
const
char
*
s
)
{
extern
int
__rt_libc_system
(
const
char
*
string
);
__rt_libc_system
(
s
);
}
/* for exit() and abort() */
__attribute__
((
noreturn
))
void
_exit
(
int
status
)
{
...
...
components/libc/compilers/gcc/partial/SConscript
0 → 100644
浏览文件 @
d43a68e9
# RT-Thread building script for bridge
import
os
from
building
import
*
cwd
=
GetCurrentDir
()
objs
=
[]
list
=
os
.
listdir
(
cwd
)
for
d
in
list
:
path
=
os
.
path
.
join
(
cwd
,
d
)
if
os
.
path
.
isfile
(
os
.
path
.
join
(
path
,
'SConscript'
)):
objs
=
objs
+
SConscript
(
os
.
path
.
join
(
d
,
'SConscript'
))
Return
(
'objs'
)
components/libc/compilers/
common/partial/l
s/SConscript
→
components/libc/compilers/
gcc/partial/mip
s/SConscript
浏览文件 @
d43a68e9
...
...
@@ -8,16 +8,13 @@ cwd = GetCurrentDir()
CPPPATH
=
[
cwd
]
group
=
[]
if
rtconfig
.
PLATFORM
==
'gcc'
and
GetDepend
(
'SOC_LS'
):
if
rtconfig
.
PLATFORM
==
'gcc'
and
(
'mips'
in
rtconfig
.
PREFIX
):
# identify mips gcc tool chain
try
:
# There is no 'sys/select.h' in t
hese bsp's gcc toolchain; thus, we need to copy this file
from 'nogcc/sys/select.h'
copy
(
"../../nogcc/sys/select.h"
,
"./sys/select.h"
)
# There is no 'sys/select.h' in t
the mips gcc toolchain; it will be copied
from 'nogcc/sys/select.h'
copy
(
"../../
../common/
nogcc/sys/select.h"
,
"./sys/select.h"
)
except
:
pass
if
GetDepend
(
'RT_USING_LIBC'
):
src
+=
Glob
(
'*.c'
)
group
=
DefineGroup
(
'libc'
,
src
,
depend
=
[],
CPPPATH
=
CPPPATH
)
Return
(
'group'
)
components/libc/compilers/gcc/partial/mips/readme.md
0 → 100644
浏览文件 @
d43a68e9
These files don't exist in the mips gcc toolchain. They will be generated by scons automatically , and
**DO NOT**
change them:
-
sys/select.h
components/libc/compilers/
common/partial/l
s/sys/select.h
→
components/libc/compilers/
gcc/partial/mip
s/sys/select.h
浏览文件 @
d43a68e9
文件已移动
components/libc/compilers/gcc/partial/readme.md
0 → 100644
浏览文件 @
d43a68e9
This folder is for some particular targets.
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录