Closed andeplane closed 3 years ago
just for reference, I already have a branch (https://github.com/rbberger/lammps/commit/f6def26d16863ec004d0b27a79a6fc5c10660e84) with some quick hacks to make it "work". But I need to go over them and solve those issues properly / discuss with Steve or Axel.
@andeplane @rbberger been reviewing old issues today. Three comments:
main.cpp
and linked to liblammps.dll (same for lammps-shell), which in turn has been successfully imported and used into python on Windows using the Python distribution from python.org.Thus MSVC support is still not fully there. Due to lack of time and limited access to corresponding platforms, this will not be done quickly unless a dedicated developer can be found that will do the porting and support the port. I don't expect any updates to this outside of items that we have already planned anyway, so I am closing this now.
Summary
To be able to use LAMMPS as a dll-library on windows, additional keywords like
__declspec(export)
and__declspec(import)
to have these functions available. A few compilation issues with MSVC also need to be taken care of.Type of Issue
Suggestion for an Enhancement
Detailed Description (Enhancement Suggestion)
I discussed this with @rbberger during the LAMMPS workshop. I want to create a Windows build of Atomify where LAMMPS is being used as a library. A typical way to create libraries on Windows is
and use DLLEXPORT in front of the exported library functions. -DCOMPILING_DLL is used during compilation of the library. This part I could do myself, but there are other issues when compiling LAMMPS with MSVC compilers since
@rbberger can add more details on this.