Skip to content
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

configvar_check_cxxfuncs("HAVE_CLOCK_GETTIME", "clock_gettime", { includes = "time.h" }) 在check时,没有将函数添加进去 #3596

Closed
guijiyang opened this issue Apr 4, 2023 · 2 comments
Labels
Milestone

Comments

@guijiyang
Copy link
Contributor

Xmake 版本

2.7.7

操作系统版本和架构

windows10

描述问题

check时,生成的临时编译文件中,没有添加需要check的函数,直接check通过:

xmake f -cvD
checking for platform ... windows
checking for architecture ... x64
checking for cl.exe ... C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.35.32215\bin\HostX64\x64\cl.exe
checking for Microsoft Visual Studio (x64) version ... 2022
checkinfo: cannot runv(zig.exe version), No such file or directory
checking for zig ... no
checkinfo: cannot runv(zig.exe version), No such file or directory
checking for zig ... no
checking for FOLLY_HAVE_SHADOW_LOCAL_WARNINGS ... no
checking for cl.exe ... C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.35.32215\bin\HostX64\x64\cl.exe
checking for the c compiler (cc) ... cl.exe
> "C:\\Program Files\\Microsoft Visual Studio\\2022\\Professional\\VC\\Tools\\MSVC\\14.35.32215\\bin\\HostX64\\x64\\cl.exe" -c -nologo -FoC:\Users\guiji\AppData\Local\Temp\.xmake\230404\_8FCA9E9FB8784E20899A9543E4BDDA60.o C:\Users\guiji\AppData\Local\Temp\.xmake\230404\_F48B04C3325346D2A69EB4203E37E7D7.c
> checking for c includes(time.h)
checking for HAVE_CLOCK_GETTIME ... ok

生成的临时文件_F48B04C3325346D2A69EB4203E37E7D7.c:

#include <time.h>


int main(int argc, char** argv)
{

    return 0;
}

期待的结果

可以准确的检测函数

工程配置

No response

附加信息和错误日志

No response

@waruqi
Copy link
Member

waruqi commented Apr 7, 2023

再试试,修复了 xmake update -s dev

@waruqi waruqi added this to the v2.7.9 milestone Apr 7, 2023
@guijiyang
Copy link
Contributor Author

再试试,修复了 xmake update -s dev
好的

@waruqi waruqi closed this as completed Apr 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants