Add clang64 MinGW environment to CI
run-test262 required pthreads, so let's add that. In addition, in MinGW, clock_gettime is implemented in the pthreads library, so we want to link it too. This doesn't get us anywhere closer to building with ClangCL on Windows, but hey, another target that required some tweaking...
This commit is contained in:
parent
0b920e7411
commit
00d104e519
3 changed files with 7 additions and 3 deletions
1
.github/workflows/ci.yml
vendored
1
.github/workflows/ci.yml
vendored
|
@ -228,6 +228,7 @@ jobs:
|
||||||
sys:
|
sys:
|
||||||
- mingw32
|
- mingw32
|
||||||
- mingw64
|
- mingw64
|
||||||
|
- clang64
|
||||||
- ucrt64
|
- ucrt64
|
||||||
defaults:
|
defaults:
|
||||||
run:
|
run:
|
||||||
|
|
|
@ -131,8 +131,11 @@ if(BUILD_QJS_LIBC)
|
||||||
endif()
|
endif()
|
||||||
list(APPEND qjs_defines _GNU_SOURCE)
|
list(APPEND qjs_defines _GNU_SOURCE)
|
||||||
list(APPEND qjs_libs qjs m)
|
list(APPEND qjs_libs qjs m)
|
||||||
if(NOT MINGW)
|
if(NOT WIN32)
|
||||||
list(APPEND qjs_libs dl pthread)
|
list(APPEND qjs_libs dl)
|
||||||
|
endif()
|
||||||
|
if(NOT MSVC)
|
||||||
|
list(APPEND qjs_libs pthread)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
add_library(qjs ${qjs_sources})
|
add_library(qjs ${qjs_sources})
|
||||||
|
|
2
qjs.c
2
qjs.c
|
@ -144,7 +144,7 @@ static inline size_t js_trace_malloc_usable_size(void *ptr)
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
#ifdef _WIN32
|
#if defined(_WIN32) && !defined(__clang__)
|
||||||
/* mingw printf is used */
|
/* mingw printf is used */
|
||||||
__attribute__((format(gnu_printf, 2, 3)))
|
__attribute__((format(gnu_printf, 2, 3)))
|
||||||
#else
|
#else
|
||||||
|
|
Loading…
Reference in a new issue