Windows: qualify Configuration, Crypto and System
- Allowlist Configuration, Crypto and System for the Windows target. - System: link winmm for the Win32 audio backend; include windows.h before mmsystem.h. - Tests: add a whole-file // @requires-posix gate (CMake path and the VBS build.cpp) and mark the POSIX-only System suites; skip helper-based cases on Windows; make setenv/unsetenv and getpid portable. - The POSIX process helper is no longer built on Windows. Cross-built with x86_64-w64-mingw32 GCC 16.2: all modules and VoidTests.exe link. Linux System+Testing suite still passes (477 tests, 474 passed). Refs #65
This commit is contained in:
1 parent
c085822686
commit
bd5488b15b
16 files changed
+196
-31
No files matched your search
@@ -7,7 +7,20 @@
|
||||
#include <fstream>
|
||||
#include <stdexcept>
|
||||
#include <string>
|
||||
#ifdef _WIN32
|
||||
#include <process.h>
|
||||
#else
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
namespace
|
||||
{
|
||||
#ifdef _WIN32
|
||||
[[nodiscard]] int current_pid() noexcept { return ::_getpid(); }
|
||||
#else
|
||||
[[nodiscard]] int current_pid() noexcept { return ::getpid(); }
|
||||
#endif
|
||||
} // namespace
|
||||
|
||||
namespace
|
||||
{
|
||||
@@ -15,7 +28,7 @@ namespace
|
||||
{
|
||||
const auto directory =
|
||||
std::filesystem::temp_directory_path() /
|
||||
("void-corpus-" + std::to_string(::getpid()));
|
||||
("void-corpus-" + std::to_string(current_pid()));
|
||||
std::filesystem::remove_all(directory);
|
||||
std::filesystem::create_directories(directory);
|
||||
return directory;
|
||||
|
||||
Reference in new issue
Block a user