Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix windows build #1

Merged
merged 6 commits into from
Feb 10, 2021
Merged

Fix windows build #1

merged 6 commits into from
Feb 10, 2021

Conversation

mcflugen
Copy link
Owner

@mcflugen mcflugen commented Feb 10, 2021

This pull request tries to fix CDM to build on Windows (see csdms/help-desk#96).

  • unistd.h and utsname.h are not available on Windows. cmake now checks to see if these header files are available and, if not, excludes code that uses them.
  • random, setstate, and initstate are not available on Windows. I've changed wind.cc to use the more standard rand and srand.
  • finite is not available. As a fix, I've changed finite to isfinite.

This still needs to be tested and the Linux and Mac builds checked to make sure the above changes didn't break them.

@mcflugen mcflugen merged commit 9bee0fd into mcflugen/use-cmake Feb 10, 2021
@mcflugen mcflugen deleted the fix-windows-build branch February 10, 2021 07:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant