diff options
| m--------- | core/src/tbox/tbox | 0 | ||||
| -rw-r--r-- | core/xmake.lua | 6 | ||||
| -rwxr-xr-x | core/xmake.sh | 6 | ||||
| -rw-r--r-- | tests/benchmarks/build_targets/test.lua | 5 | ||||
| -rw-r--r-- | tests/benchmarks/config_targets/test.lua | 5 |
5 files changed, 22 insertions, 0 deletions
diff --git a/core/src/tbox/tbox b/core/src/tbox/tbox -Subproject 1d777aca24121df60d4219e08c0230e30fb0575 +Subproject d18d6f97242b25cea9da8d16def04022642138c diff --git a/core/xmake.lua b/core/xmake.lua index e819f572b..31be4464c 100644 --- a/core/xmake.lua +++ b/core/xmake.lua @@ -24,6 +24,12 @@ add_cxflags("-Wno-error=deprecated-declarations", "-fno-strict-aliasing", "-Wno- -- add definitions add_defines("_GNU_SOURCE=1", "_FILE_OFFSET_BITS=64", "_LARGEFILE_SOURCE") +-- ensure POSIX/XOPEN features are available on Solaris (for setenv, unsetenv, clock_gettime, etc.) +-- _XOPEN_SOURCE=600 implicitly sets _POSIX_C_SOURCE=200112L +if is_plat("solaris") then + add_defines("_XOPEN_SOURCE=600") +end + -- add vectorexts --[[ if is_arch("x86", "x64", "i386", "x86_64") then diff --git a/core/xmake.sh b/core/xmake.sh index 5a8fcb072..41c09483f 100755 --- a/core/xmake.sh +++ b/core/xmake.sh @@ -12,6 +12,12 @@ set_languages "c99" # add definitions add_defines "_GNU_SOURCE=1" "_FILE_OFFSET_BITS=64" "_LARGEFILE_SOURCE" +# ensure POSIX/XOPEN features are available on Solaris (for setenv, unsetenv, clock_gettime, etc.) +# _XOPEN_SOURCE=600 implicitly sets _POSIX_C_SOURCE=200112L +if is_plat "solaris"; then + add_defines "_XOPEN_SOURCE=600" +fi + # disable some compiler errors if is_plat "macosx"; then add_cxflags "-Wno-error=deprecated-declarations" "-fno-strict-aliasing" "-Wno-error=nullability-completeness" "-Wno-error=parentheses-equality" diff --git a/tests/benchmarks/build_targets/test.lua b/tests/benchmarks/build_targets/test.lua index 8660dbe52..28d239b54 100644 --- a/tests/benchmarks/build_targets/test.lua +++ b/tests/benchmarks/build_targets/test.lua @@ -15,6 +15,11 @@ end function test_build(t) + -- 20% random trigger + if math.random() > 0.2 then + return + end + if xmake.is_embed() then return end diff --git a/tests/benchmarks/config_targets/test.lua b/tests/benchmarks/config_targets/test.lua index 8eacf2dc1..e16bf12d2 100644 --- a/tests/benchmarks/config_targets/test.lua +++ b/tests/benchmarks/config_targets/test.lua @@ -15,6 +15,11 @@ end function test_config(t) + -- 20% random trigger + if math.random() > 0.2 then + return + end + if xmake.is_embed() then return end |
