From e4e016d0a83da8c5a6050129c2ad0648c575046c Mon Sep 17 00:00:00 2001 From: Jonathan Roelofs Date: Fri, 13 Nov 2015 00:32:54 +0000 Subject: [PATCH] [scan-build] Create share directory similar to scan-view's git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@252981 91177308-0d34-0410-b5e6-96231b3b80d8 --- tools/scan-build/CMakeLists.txt | 18 +++++++++--------- tools/scan-build/Makefile | 2 +- tools/scan-build/{ => share}/scanview.css | 0 tools/scan-build/{ => share}/sorttable.js | 0 4 files changed, 10 insertions(+), 10 deletions(-) rename tools/scan-build/{ => share}/scanview.css (100%) rename tools/scan-build/{ => share}/sorttable.js (100%) diff --git a/tools/scan-build/CMakeLists.txt b/tools/scan-build/CMakeLists.txt index 7c2df32e0d..3564c89732 100644 --- a/tools/scan-build/CMakeLists.txt +++ b/tools/scan-build/CMakeLists.txt @@ -21,7 +21,7 @@ endif() set(ManPages scan-build.1) -set(ResourceFiles +set(ShareFiles scanview.css sorttable.js) @@ -63,16 +63,16 @@ if(CLANG_INSTALL_SCANBUILD) install(PROGRAMS ${ManPage} DESTINATION share/man/man1) endforeach() - foreach(ResourceFile ${ResourceFiles}) - add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/bin/${ResourceFile} + foreach(ShareFile ${ShareFiles}) + add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/share/scan-view/${ShareFile} COMMAND ${CMAKE_COMMAND} -E make_directory - ${CMAKE_BINARY_DIR}/bin + ${CMAKE_BINARY_DIR}/share/scan-view COMMAND ${CMAKE_COMMAND} -E copy - ${CMAKE_CURRENT_SOURCE_DIR}/${ResourceFile} - ${CMAKE_BINARY_DIR}/bin/ - DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/${ResourceFile}) - list(APPEND Depends ${CMAKE_BINARY_DIR}/bin/${ResourceFile}) - install(FILES ${ResourceFile} DESTINATION bin) + ${CMAKE_CURRENT_SOURCE_DIR}/share/${ShareFile} + ${CMAKE_BINARY_DIR}/share/scan-view/ + DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/share/${ShareFile}) + list(APPEND Depends ${CMAKE_BINARY_DIR}/share/scan-view/${ShareFile}) + install(FILES ${ShareFile} DESTINATION share/scan-view) endforeach() add_custom_target(scan-build ALL DEPENDS ${Depends}) diff --git a/tools/scan-build/Makefile b/tools/scan-build/Makefile index a6a2c10ce0..a9e072aa3c 100644 --- a/tools/scan-build/Makefile +++ b/tools/scan-build/Makefile @@ -47,7 +47,7 @@ $(ShareDir)/man/man1/%: % Makefile $(ShareDir)/man/man1/.dir $(Echo) "Copying $(notdir $<) to the 'share' directory..." $(Verb)cp $< $@ -$(ShareDir)/scan-build/%: % Makefile $(ShareDir)/scan-build/.dir +$(ShareDir)/scan-build/%: share/% Makefile $(ShareDir)/scan-build/.dir $(Echo) "Copying $(notdir $<) to the 'share' directory..." $(Verb)cp $< $@ diff --git a/tools/scan-build/scanview.css b/tools/scan-build/share/scanview.css similarity index 100% rename from tools/scan-build/scanview.css rename to tools/scan-build/share/scanview.css diff --git a/tools/scan-build/sorttable.js b/tools/scan-build/share/sorttable.js similarity index 100% rename from tools/scan-build/sorttable.js rename to tools/scan-build/share/sorttable.js -- 2.40.0