-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Posix standard implementation for pse51 #5376
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
int clock_nanosleep(clockid_t clockid, int flags, const struct timespec *rqtp, struct timespec *rmtp) | ||
{ | ||
if ((clockid != CLOCK_REALTIME) || (rqtp == RT_NULL)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sys/time.h没有给出这个函数的声明
int nanosleep(const struct timespec *rqtp, struct timespec *rmtp) | ||
{ | ||
uint32_t time_ms = rqtp->tv_sec * 1000; | ||
uint32_t time_us = rqtp->tv_nsec / 1000; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sys/time.h没有给出这个函数的声明
@@ -11,12 +11,14 @@ libc_ver = GetDepend('LIBC_VERSION') | |||
try: | |||
ver = libc_ver.split(' ') | |||
ver = ver[1] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个位置怎么加回来了?
/* | ||
* Copyright (c) 2006-2021, RT-Thread Development Team | ||
* | ||
* SPDX-License-Identifier: Apache-2.0 | ||
* | ||
* Change Logs: | ||
* Date Author Notes | ||
* 2021-07-21 xiangxistu The first version | ||
*/ | ||
|
||
#ifndef _SYS__TIMESPEC_H_ | ||
#define _SYS__TIMESPEC_H_ | ||
|
||
#include <sys/_types.h> | ||
|
||
#if !defined(__time_t_defined) && !defined(_TIME_T_DECLARED) | ||
typedef _TIME_T_ time_t; | ||
#define __time_t_defined | ||
#define _TIME_T_DECLARED |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个文件删掉
copy("../../../common/nogcc/sys/select.h", "./sys/select.h") | ||
copy("../../../common/nogcc/sys/_timespec.h", "./sys/_timespec.h") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
删除掉此句
|
||
#if !(defined(__GNUC__) && !defined(__ARMCC_VERSION)/*GCC*/) && \ | ||
!(defined(__ICCARM__) && (__VER__ >= 8010001)) && \ | ||
!defined(_WIN32) | ||
#ifndef _TIMESPEC_DEFINED | ||
#define _TIMESPEC_DEFINED |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
revert此文件的修改
#ifdef __SPU__ | ||
#include <sys/_timespec.h> | ||
int nanosleep (const struct timespec *, struct timespec *); | ||
#endif | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这段删掉吧
把time相关的先都移除吧 这部分我来处理,只需要帮我把这里删除掉就可以了machine/time.h :
|
拉取/合并请求描述:(PR description)
[
]
以下的内容不应该在提交PR时的message修改,修改下述message,PR会被直接关闭。请在提交PR后,浏览器查看PR并对以下检查项逐项check,没问题后逐条在页面上打钩。
The following content must not be changed in the submitted PR message. Otherwise, the PR will be closed immediately. After submitted PR, please use a web browser to visit PR, and check items one by one, and ticked them if no problem.
当前拉取/合并请求的状态 Intent for your PR
必须选择一项 Choose one (Mandatory):
代码质量 Code Quality:
我在这个拉取/合并请求中已经考虑了 As part of this pull request, I've considered the following:
#if 0
代码,不包含已经被注释了的代码 All redundant code is removed and cleaned up