usnistgov / REFPROP-manager

A manager class for holding many copies of REFPROP in memory
9 stars 8 forks source link

REFPROP-manager.hpp glitch in Windows #7

Closed bibiloi1 closed 4 years ago

bibiloi1 commented 4 years ago

REFPROP-manager,hpp has a glitch when building under Windows (Windows 10 with CMake 3.18 and using Visual Studio 2019 as generator) Line 88 reads: auto load_method = AbstractSharedLibraryWrapper::load_method::LOAD_LIBRARY_PRISTINE;

but LOAD_LIBRARY_PRISTINE throws in windows.h. Under windows use LOAD_LIBRARY instead. Best regards, Felix Oltean Gas & Oil Know-How SRL, Medias, Romania

ianhbell commented 4 years ago

I moved the issue to the appropriate repository.

ianhbell commented 4 years ago

Yes, windows and linux are different. Most of the testing has been done in linux, but it works in windows too, you just can't use that option, I should probably update the README to make this point more clear.

ianhbell commented 4 years ago

This time I really moved it to the correct repository.

ianhbell commented 4 years ago

I think we can probably close this one with my fix. Please let me know. But really, it would be better to allow you to specify that as argument to REFPROPInstance. I'll see about a good way to make that change.

bibiloi1 commented 4 years ago

Sure, we can close the issue. I think a good way to fix it would be to change the option from LOAD_LIBRARY_PRISTINE to LOAD_LIBRARY behind the scene for Windows because Windows just does not implement LOAD_LIBRARY_PRISTINE. It's up to you as developer.

ianhbell commented 4 years ago

Did you check my commit :) ? That's precisely what I did, except I did the load from file.

bibiloi1 commented 4 years ago

Great! Sorry, I didn't check the commit first. I'm really submerged into fitting this libraries in a tiny industrial computer

ianhbell commented 4 years ago

Please open an issue here if you run into trouble. I'd like to resolve any issues that come up.