spirit-code / spirit

Atomistic Spin Simulation Framework
http://spirit-code.github.io
MIT License
117 stars 52 forks source link

make install: missing ovf directory #567

Closed ddkn closed 4 years ago

ddkn commented 4 years ago

Hello,

I am trying to install spirit onto Debian/Buster with CUDA 10.2, either v2.0.1 or 8e51bcd. However, I am having an issue with make install, such that I get the error (I have attached the whole output as a file just in case):

... CMake Error at core/thirdparty/ovf/cmake_install.cmake:45 (file): file INSTALL cannot find "/home/lab/tmp/spirit/core/thirdparty/ovf/include/ovf". Call Stack (most recent call first): core/cmake_install.cmake:194 (include) cmake_install.cmake:58 (include)

This is run with the vanilla

mkdir build 
cd build 
cmake ../ 
make -j4

just default options, it builds fine with no errors. If I create a directory $SPIRIT/core/thirdparty/ovf/include/ovf it installs just fine (minus a issue with qt plugins, patch to come in next post).

Is there supposed to be any "ovf" directory, and does it have any contents? Should I patch to fix this or just create the directory as I have done?

Thanks!

make.install.log

ddkn commented 4 years ago

This seems to be a duplicate and can be solved with the #565 pull request.

GPMueller commented 4 years ago

Thanks for your feedback! Please note that so far, Spirit has not been meant to be "installed" with make install. The logic was that one may need multiple different versions of Spirit for different projects/simulations, so for us a /usr/local/bin/spirit (or similar) was not useful.

Did you try it with the pull request and it worked OK? If you have any other feedback regarding the make install process, please let us know.

ddkn commented 4 years ago

Ah I see what you mean on multiple versions. I figured if users wanted to install Spirit in arbitrary directories on a per-need basis they would use the -DCMAKE_INSTALL_PREFIX option for cmake. As I was trying to put it in /opt/spirit-openmp to test. On different package managers apt, pkgng or OpenBSD's 'pkg_*`, you can have different versions with different options (some call them flavours).

Our group expressed interest in getting Spirit running, as we are also doing MuMax simulations, with about 5 users. I am unsure if the pip version has openmp or threads (doubtful for cuda). So having a generic install that takes advantage of multicore is a minimum.

It would be nice to have an install for a lab machine(s), where a generic setup is useful. Then specific lab users could compile their own with patches as needed. As someone who is maintaining a server it is more convenient to have a few installs that everyone shares versus having duplicate installs everywhere.

At the moment I am not having success running the GUI (I will make an issue for that), so the install issue can wait until then.

PS. I just tried the improved-cmake and the install problems I had went away! Thanks!

GPMueller commented 4 years ago

The pip version has only the default settings, i.e. nothing that is OFF in the CMake (no OpenMP or CUDA).

I'm not sure what would be best in your use-case, but if you want to provide centralized installations and you don't need to have header files or shared libraries installed, it could be sufficient to just copy the executable to the corresponding /opt/... directory instead of using spirit's make install (assuming Qt is installed system-wide). Even on the improved-cmake branch, I suppose the installation is probably not up to standards of system package management.

If you have suggestions how the installation step could be improved, such as excluding some unnecessary files, please feel free to let us know :)

ddkn commented 4 years ago

Good to know. It might be worth documenting the features from a pip install for users. Possibly on the pypi.org website. I only inferred that from the build instructions.

I will let you know about install suggestions, once I get a system where we can use Spirit. Thanks!

At the moment the make install of improved-cmake seems sufficient for now.