Changeset 7ec3dd1 in nscp for build/cmake/functions.cmake
- Timestamp:
- 06/16/11 23:00:44 (2 years ago)
- Branches:
- master, 0.4.0, 0.4.1, 0.4.2
- Children:
- e11d494
- Parents:
- 3bdaf18
- File:
-
- 1 edited
-
build/cmake/functions.cmake (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
build/cmake/functions.cmake
r197b263 r7ec3dd1 18 18 ENDFOREACH(_CURRENT_MODULE ${TMP_LIST}) 19 19 ENDMACRO(LOAD_SECTIONS) 20 21 22 MACRO(copy_single_file alias src destDir) 23 GET_FILENAME_COMPONENT(TARGET ${src} NAME) 24 SET(source_file ${CMAKE_CURRENT_SOURCE_DIR}/${src}) 25 IF(${destDir} STREQUAL ".") 26 SET(target_file ${CMAKE_BINARY_DIR}/${TARGET}) 27 ELSE(${destDir} STREQUAL ".") 28 SET(target_file ${CMAKE_BINARY_DIR}/${destDir}/${TARGET}) 29 ENDIF(${destDir} STREQUAL ".") 30 #message(STATUS " - Copying ${source_file} to ${target_file}...") 31 ADD_CUSTOM_COMMAND(OUTPUT ${target_file} 32 DEPENDS ${source_file} 33 COMMAND cmake 34 ARGS -E copy "${source_file}" "${target_file}" 35 OUTPUT ${target_file} 36 COMMENT Copying ${source_file} to ${target_file} 37 ) 38 ADD_CUSTOM_TARGET(${TARGET}_${alias} ALL DEPENDS ${target_file}) 39 SET_TARGET_PROPERTIES(${TARGET}_${alias} PROPERTIES FOLDER "files/${alias}") 40 INSTALL(CODE "FILE(INSTALL DESTINATION \${CMAKE_INSTALL_PREFIX}/${destDir} TYPE EXECUTABLE FILES \"${source_file}\")") 41 ENDMACRO(copy_single_file) 42
Note: See TracChangeset
for help on using the changeset viewer.








