netcdf-c icon indicating copy to clipboard operation
netcdf-c copied to clipboard

CI: Setup a CMake job for MSYS2/MinGW

Open MehdiChinoune opened this issue 9 months ago • 11 comments

MehdiChinoune avatar May 04 '24 05:05 MehdiChinoune

This keeps dying on me because apparently m4 is not being installed.

DennisHeimbigner avatar May 05 '24 03:05 DennisHeimbigner

This PR requires #2914 to be applied first.

MehdiChinoune avatar May 05 '24 04:05 MehdiChinoune

Applied 2914 and it still dies because it cannot find m4.

DennisHeimbigner avatar May 05 '24 19:05 DennisHeimbigner

Applied 2914 and it still dies because it cannot find m4.

It requires some more changes that i will apply one #2914 got merged.

MehdiChinoune avatar May 05 '24 19:05 MehdiChinoune

@DennisHeimbigner I have pushed changes for the build to succeeds, but tests needs more changes to succeed.

MehdiChinoune avatar May 05 '24 19:05 MehdiChinoune

You repeatedly change if(MSVC) to if(WIN32). Does that work for cygwin?

DennisHeimbigner avatar May 06 '24 15:05 DennisHeimbigner

You repeatedly change if(MSVC) to if(WIN32). Does that work for cygwin?

No, WIN32 is not defined by CMake on CygWin.

MehdiChinoune avatar May 06 '24 16:05 MehdiChinoune

@DennisHeimbigner I'm not seeing an issue on my end from the tests, but I don't have a Cygwin environment to run. It works in MSYS2 with Visual Studio, if you run this manually on your Cygwin environment, does it fail?

WardF avatar May 07 '24 17:05 WardF

DWesl/netcdf-c#2 is a copy of this workflow adapted for Cygwin, which shows a single test failure (a massive improvement over the last time I tried CMake on Cygwin). I don't recognize the reason for the nc_test4_tst_filter failure from the details provided, so I'd have to dig into that locally, but I suspect that failure is unrelated to the changes in this PR.

DWesl avatar May 09 '24 18:05 DWesl

Can you give a short characterization of the differences between you cygwin .yml and the existing cygwin .yml?

DennisHeimbigner avatar May 10 '24 02:05 DennisHeimbigner

Can you give a short characterization of the differences between your cygwin.yml and the existing cygwin.yml?

I added a section to build the software and run tests using CMake. This section differs from the Autotools job in the software installed (the CMake job adds gcc-g++, cmake, ninja, and make) and tool used to configure, build, and run the tests.

The CMake section differs from the CMake section here in the action used to install packages (Cygwin instead of MSYS/MinGW) and the build generator used (Unix Makefiles instead of MSYS). I also specified more full paths to utilities. Should I make a PR to add that to this PR or create a new PR?

DWesl avatar May 10 '24 10:05 DWesl

Thanks!

WardF avatar May 15 '24 00:05 WardF