Skip to content

fix: avoid nauty unistd.h include under MSVC#71

Merged
jrfaeder merged 2 commits into
RuleWorld:masterfrom
wshlavacek:bngsim/windows-nauty
May 12, 2026
Merged

fix: avoid nauty unistd.h include under MSVC#71
jrfaeder merged 2 commits into
RuleWorld:masterfrom
wshlavacek:bngsim/windows-nauty

Conversation

@wshlavacek
Copy link
Copy Markdown

src/nauty24/nauty.h currently hardcodes HAVE_UNISTD_H 1, so MSVC builds still reach #include <unistd.h> even though that header is not available there.

This patch applies the smallest targeted fix by setting HAVE_UNISTD_H to 0 under _MSC_VER only. Non-MSVC builds, including existing MinGW-style Windows builds, keep the current behavior.

Verification:

  • reproduced the pre-patch include path with a small compile probe
  • confirmed a simulated MSVC build no longer reaches unistd.h
  • confirmed a simulated MinGW-style build still follows the existing include path
  • rebuilt NFsim locally with CMake and confirmed NFsim -h still runs

I could not run a real Windows/MSVC build locally.

@jrfaeder jrfaeder merged commit 52df72c into RuleWorld:master May 12, 2026
3 checks passed
@wshlavacek wshlavacek deleted the bngsim/windows-nauty branch May 19, 2026 15:37
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.

2 participants