installs binaries to /usr/local/. on Linux
bvanevery opened this issue · 1 comments
The CMake script installs the sample binaries to the /usr/local directory on Linux, not /usr/local/bin as would be expected. Also there is no uninstall provided, so this has the effect of crapping on /usr/local and leaving a mess for the user to clean up manually. Fortunately not a huge mess as everything begins with gl-*. The offending line is probably
install (DIRECTORY data DESTINATION .)
which probably replaces the sane Unix defaults with . the directory itself. This is probably a Windows-ism and probably isn't correct behavior even on Windows, as C:\Program Files\projectname is the typical default CMake installation directory.
It's been awhile since I've done CMake, but probably installation and uninstallation targets are a bit more verbose to specify, with specific targets for binaries, libraries, shared libraries, etc. I doubt there's any one stop shop where you give it a '.' and uninstallation is definitely not automatically generated either.
I am not familiar with Linux install system but if somebody wants to me a pull request, he is welcome to do it. :)
Thanks for reporting,
Christophe