hello_imgui icon indicating copy to clipboard operation
hello_imgui copied to clipboard

[Linux] Add option to make installation follow file system conventions; not all in one place.

Open dreirund opened this issue 1 year ago • 1 comments

Ahoj,

I want to make a package of this for Arch Linux (to use it as a (build time) dependency for other projects, that not each project has to follow the "dirty" habit of pulling in the source on it's own).

I see that -DCMAKE_INSTALL_PREFIX=/usr installs the executables directly unter /usr, and the assets under /usr/assets and so on. Not suitable for packaging.

Can you make an option to install in a way following Linux filesystem conventions?:

  • Executables into [prefix]/bin/
  • Assets into [prefix]/share/hello_imgui/
  • Libraries into [prefix]/lib/ or [prefix]/lib/hello_imgui/
  • Include files into [prefix]/include/ or [prefix]/include/hello_imgui/
  • CMake files into [prefix]/share/cmake/hello_imgui/
  • Documentation into [prefix]/share/doc/hello_imgui/
  • Example executables maybe also into [prefix]/share/doc/hello_imgui/examples/ or so
  • Man pages into [prefix]/share/man/man[#]/

etc.

Like HDRView did introduce in this commit, following a note in this issue.

Regards!

dreirund avatar Jan 12 '25 11:01 dreirund

Hello,

I'll study this a bit later. This requires careful consideration, so it might take a while.

pthom avatar Jan 29 '25 16:01 pthom