Some changes for basic support of MinGW - #76
Conversation
|
Since there are many constructions like #ifdef __WIN32__
ptr = GetProcAddress(backend->library_handle, fn_name);
#else
ptr = dlsym(backend->library_handle, fn_name);
#endifto get rid of the |
82bf674 to
5ff8031
Compare
|
Thanks for the feedback. I also rebased on the branch that triggers the CI on pull requests. (And already found a regression that should be fixed now.) I'm still at a loss as to where the |
|
I'll take a look on this asap. That sounds strange
|
Loading symbols from shared libraries requires different mechanisms on Windows (compared to Linux or macOS). Add helper functions that encapsulate these differences for some tasks that are done repeatedly. That concentrated of platform-specific code in less places and makes maintenance easier.
Avoid duplicate definition of xerbla_ in Fortran and C if CBLAS=ON. Define "RowMajorStrg" in one of the objects linked into that library.
|
Rebased on your current release candidate. It still doesn't work. But at least it is building again. |
|
This should be done with FlexiBLAS 3.5.0 |
|
Thank you for adding support for MinGW. I finally came around to testing this in the MINGW64 environment of MSYS2. Please, let me know if you have an idea what I might be doing wrong or if you need further information. If you'd like, I could also look into adding a workflow for testing FlexiBLAS with MSYS2 packages in the GitHub CI. Would you be interested in that? |
|
These tests will also fail if you compile the reference LAPACK with An MSYS2 on github CI would be great. :-) |
These changes are still a hot mess. They compile on MINGW64 with the compilers from MSYS2.
But all tests are failing with errors like the following:
If I understand the error messages correctly, it is trying to load import libraries (with file extension
.dll.a) which fails (unsurprisingly). Instead, it should be trying to load the dynamic load libraries (with file extension.dllwhich are installed in thebinfolder on Windows).I haven't looked yet into why that is happening. Any feedback would be very welcome.
Instead of adding a dependency on a dlopen wrapper library, I thought it might be better to use native Windows functions to load symbols from the libraries on runtime. (Might have a performance advantage. But since it doesn't run yet, I can't tell whether that is the case.)
There are also still a couple of FIXME comments where the implementation isn't complete yet. I figured that it might still make sense to share what I have so far.