diff options
author | Alexander Neundorf <neundorf@kde.org> | 2007-01-26 18:46:13 +0000 |
---|---|---|
committer | Alexander Neundorf <neundorf@kde.org> | 2007-01-26 18:46:13 +0000 |
commit | 32675443733a47680db1299485bb46b20b8c5a8e (patch) | |
tree | 894cdcda49bc7de82106ef51e5161eedd86102da | |
parent | 246a4a97d889ae998ebdccd205b55c8cd3a29fea (diff) | |
download | extra-cmake-modules-32675443733a47680db1299485bb46b20b8c5a8e.tar.gz extra-cmake-modules-32675443733a47680db1299485bb46b20b8c5a8e.tar.bz2 |
use install(CODE ...) instead of file(WRITE ... ) followed by install(SCRIPT ...)
so this is:
-less cmake code
-now with qoutes so it should also work with path containing spaces
-doesn't create an additionally small cmake file for every kde4_install_handbook() call,
so it should run a bit faster
Alex
CCMAIL: winter@kde.org
svn path=/trunk/KDE/kdelibs/; revision=627478
-rw-r--r-- | modules/KDE4Macros.cmake | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/modules/KDE4Macros.cmake b/modules/KDE4Macros.cmake index 05e78566..bd98234b 100644 --- a/modules/KDE4Macros.cmake +++ b/modules/KDE4Macros.cmake @@ -224,9 +224,8 @@ macro (KDE4_INSTALL_HANDBOOK) install(FILES ${CMAKE_CURRENT_BINARY_DIR}/index.cache.bz2 ${_books} ${_images} DESTINATION ${HTML_INSTALL_DIR}/en/${dirname}) # TODO symlinks on non-unix platforms if (UNIX) - # write a cmake script file which creates the symlink - file(WRITE ${CMAKE_CURRENT_BINARY_DIR}/make_doc_symlink.cmake "exec_program(${CMAKE_COMMAND} ARGS -E create_symlink ${HTML_INSTALL_DIR}/en/common ${HTML_INSTALL_DIR}/en/${dirname}/common )\n") - install(SCRIPT ${CMAKE_CURRENT_BINARY_DIR}/make_doc_symlink.cmake) + # execute some cmake code on make install which creates the symlink + install(CODE "execute_process(COMMAND ${CMAKE_COMMAND} -E create_symlink \"${HTML_INSTALL_DIR}/en/common\" \"${HTML_INSTALL_DIR}/en/${dirname}/common\" )" ) endif (UNIX) endmacro (KDE4_INSTALL_HANDBOOK ) |