[CMake] Please critique my "hello world" CMakeLists.txt and Config.cmake
Chris Stankevitz
chrisstankevitz at gmail.com
Sun Feb 24 17:05:20 EST 2013
On Sun, Feb 24, 2013 at 12:37 PM, Alexander Neundorf
<a.neundorf-work at gmx.net> wrote:
>> github links:
>> https://github.com/chrisstankevitz/hello
>> https://github.com/chrisstankevitz/hello-client
>
> Maybe we'll start with the old way and get to the new way.
Alex,
Thank you again. I updated the projects per your teaching. The only
place I had to guess was here:
INSTALL(
FILES
${CMAKE_CURRENT_BINARY_DIR}/helloConfig.cmake
DESTINATION
${hello_DIRNAME_lib}
)
With respect to this INSTALL directive, I have three questions:
1. Is it needed? [Apparently the answer is yes]
2. Is ${CMAKE_CURRENT_BINARY_DIR}/helloConfig.cmake the appropriate
way for me to reference this file? I got this from kdelibs.git.
3. Is ${hello_DIRNAME_lib} (aka
/usr/local/lib/hello-1.1/helloConfig.cmake) the correct place to
install helloConfig.cmake? kdelibs.git puts it somewhere else
("${CMAKECONFIG_INSTALL_DIR}" which I guessed corresponds to the weird
location /usr/local/hello/).
Thank you again,
Chris
More information about the CMake
mailing list