msgpack/msgpack-c — pull request #125 by jpetso (2014-09-09 20:30:38+00:00)
Title: Install version.h even if doing an out-of-source build.

I tried the following commands:

git clone https://github.com/msgpack/msgpack-c.git
mkdir -p build/msgpack-c/Desktop-Debug/ && cd build/msgpack-c/Desktop-Debug/
cmake ../../../msgpack-c/
make
sudo checkinstall

When trying to include msgpack.hpp, it gave me an error about msgpack/version.h missing. I checked in the installed include directory (/usr/local/include) and while version.h.in was there, version.h was indeed missing.

Not sure how other people install their msgpack-c builds, but I don't really see how it would work - instead of copying specific files, it just takes the whole src/msgpack directory from the source tree and copies it over as a whole. Naturally, that leaves out the version.h which was generated in ${CMAKE_CURRENT_BINARY_DIR}.

This patch adds ${CMAKE_CURRENT_BINARY_DIR}/src/msgpack to the list of installed include directories, which means now there are two. If doing a build in the source tree, this should not matter because the directories are the same and so the same files are being listed/installed.