diff options
author | Sergei Golubchik <serg@mariadb.org> | 2017-08-09 18:23:04 +0200 |
---|---|---|
committer | Sergei Golubchik <serg@mariadb.org> | 2017-08-14 19:45:58 +0200 |
commit | c872b10022180602fbd5b2b0310b6d1e343dff5a (patch) | |
tree | bf899ad9e77c58b4efc4f2b73c3f1a4e0253fab5 /sql-bench | |
parent | c9db190fed4e368201703e3d1031e16abfd61e45 (diff) | |
download | mariadb-git-c872b10022180602fbd5b2b0310b6d1e343dff5a.tar.gz |
don't install same files twice
CMakeLists.txt - merge mistake, apparently
include/CMakeLists.txt - install from CMAKE_CURRENT_BINARY_DIR.
Only install from CMAKE_CURRENT_SOURCE_DIR, if it's different
from CMAKE_CURRENT_BINARY_DIR
mysql-test/CMakeLists.txt - INSTALL_MYSQL_TEST() macro installs
everything, no need to install mtr separately once again
mysql-test/lib/My/SafeProcess/CMakeLists.txt
MYSQL_ADD_EXECUTABLE includes INSTALL
sql-bench/CMakeLists.txt
list files explicitly. don't install garbage, don't process 'foo'
and 'foo.sh' separately, it's only one file to install, not two.
Diffstat (limited to 'sql-bench')
-rw-r--r-- | sql-bench/CMakeLists.txt | 58 |
1 files changed, 32 insertions, 26 deletions
diff --git a/sql-bench/CMakeLists.txt b/sql-bench/CMakeLists.txt index a837746bb98..b5532b2445c 100644 --- a/sql-bench/CMakeLists.txt +++ b/sql-bench/CMakeLists.txt @@ -34,38 +34,44 @@ INSTALL(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/Data/Wisconsin INSTALL(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/limits DESTINATION ${prefix}sql-bench COMPONENT SqlBench) -FILE(GLOB all_files ${CMAKE_CURRENT_SOURCE_DIR}/*) +SET(all_files README bench-count-distinct.sh bench-init.pl.sh + compare-results.sh copy-db.sh crash-me.sh example.bat + graph-compare-results.sh innotest1.sh innotest1a.sh innotest1b.sh + innotest2.sh innotest2a.sh innotest2b.sh myisam.cnf pwd.bat + run-all-tests.sh server-cfg.sh test-ATIS.sh test-alter-table.sh + test-big-tables.sh test-connect.sh test-create.sh test-insert.sh + test-select.sh test-table-elimination.sh test-transactions.sh + test-wisconsin.sh uname.bat + ) FOREACH(file ${all_files}) - IF(NOT IS_DIRECTORY ${file} AND NOT ${file} MATCHES "Make|as3ap|/example$" ) - GET_FILENAME_COMPONENT(ext ${file} EXT) - GET_FILENAME_COMPONENT(name ${file} NAME) - SET(target ${name}) - IF(ext MATCHES ".sh$") - # Those are perl files actually - STRING(REPLACE ".sh" "" target ${target} ) - IF(WIN32) - IF(NOT ext MATCHES ".pl") - SET(target "${target}.pl") - ENDIF() + GET_FILENAME_COMPONENT(ext ${file} EXT) + GET_FILENAME_COMPONENT(name ${file} NAME) + SET(target ${name}) + IF(ext MATCHES ".sh$") + # Those are perl files actually + STRING(REPLACE ".sh" "" target ${target} ) + IF(WIN32) + IF(NOT ext MATCHES ".pl") + SET(target "${target}.pl") ENDIF() ENDIF() - SET(target "${CMAKE_CURRENT_BINARY_DIR}/${target}") - CONFIGURE_FILE(${file} ${target} COPYONLY) - IF (UNIX AND NOT ${name} MATCHES "README") - EXECUTE_PROCESS(COMMAND chmod +x ${target}) - ENDIF() - IF (ext MATCHES ".bat") - IF(WIN32) - INSTALL(PROGRAMS ${target} - DESTINATION ${prefix}sql-bench COMPONENT SqlBench) - ENDIF() - ELSEIF(name MATCHES "README") - INSTALL(FILES ${target} - DESTINATION ${prefix}sql-bench COMPONENT SqlBench) - ELSE() + ENDIF() + SET(target "${CMAKE_CURRENT_BINARY_DIR}/${target}") + CONFIGURE_FILE(${file} ${target} COPYONLY) + IF (UNIX AND NOT ${name} MATCHES "README") + EXECUTE_PROCESS(COMMAND chmod +x ${target}) + ENDIF() + IF (ext MATCHES ".bat") + IF(WIN32) INSTALL(PROGRAMS ${target} DESTINATION ${prefix}sql-bench COMPONENT SqlBench) ENDIF() + ELSEIF(name MATCHES "README") + INSTALL(FILES ${target} + DESTINATION ${prefix}sql-bench COMPONENT SqlBench) + ELSE() + INSTALL(PROGRAMS ${target} + DESTINATION ${prefix}sql-bench COMPONENT SqlBench) ENDIF() ENDFOREACH() |