Skip to content

WIP: Windows/macos CI and support#41

Draft
dutow wants to merge 4 commits into
Percona-Lab:masterfrom
dutow:moreci
Draft

WIP: Windows/macos CI and support#41
dutow wants to merge 4 commits into
Percona-Lab:masterfrom
dutow:moreci

Conversation

@dutow

@dutow dutow commented Jul 3, 2026

Copy link
Copy Markdown
Collaborator

macOS probably already works so this only adds a CI, but windows definitely wouldn't complete.

This is still work in progress, the goal is to get MSVC builds working in this PR including a basic CI test.

For now I only added unit tests, figuring out how we can run integration tests on these platforms is another question.

dutow added 4 commits July 3, 2026 09:56
Replace htonl-based to_be32/to_be64 with portable shift-based implementations
using std::endian from <bit>, eliminating the POSIX-only dependency on
<arpa/inet.h>. This unblocks Windows/macOS support for kmipcore.
Introduce a single last_socket_error()/socket_error_string() pair
(errno/strerror on POSIX, WSAGetLastError/FormatMessageA on Windows)
used by all socket error reporting, and gate poll/fcntl/setsockopt
usage behind #ifdef _WIN32 with WSAPoll/ioctlsocket/SOCKET equivalents.
Move is_ip_address to OpenSSL's a2i_IPADDRESS parser so no socket
headers are needed just to detect IP-literal hosts.
MSVC encodes struct-vs-class in mangled names. kmip_formatter.hpp forward-declared Element as class while kmip_basics.hpp defines it as struct, so TUs disagreed on the mangling of every symbol involving Element (C4099 warnings, LNK2019 on Windows). Itanium ABI ignores the class-key, which is why Linux and macOS linked fine.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant