diff options
author | Vladislav Vaintroub <wlad@mariadb.com> | 2019-12-12 00:05:55 +0100 |
---|---|---|
committer | Vladislav Vaintroub <wlad@mariadb.com> | 2019-12-12 00:05:55 +0100 |
commit | a3a8360d577b44131577c5d40336c632d35487ae (patch) | |
tree | 2bd6faac3b277ce246c4065ce64990240666f014 /sql/CMakeLists.txt | |
parent | 8d2f6d3ca5f9a4c07cced6204c7a36028fd9a544 (diff) | |
download | mariadb-git-a3a8360d577b44131577c5d40336c632d35487ae.tar.gz |
CMake,Windows - cleanup data directory prior to bootstrap for nitial_database target
Diffstat (limited to 'sql/CMakeLists.txt')
-rw-r--r-- | sql/CMakeLists.txt | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sql/CMakeLists.txt b/sql/CMakeLists.txt index 6362ed2c561..3f6b3e694d1 100644 --- a/sql/CMakeLists.txt +++ b/sql/CMakeLists.txt @@ -401,9 +401,11 @@ IF(WIN32 AND MYSQLD_EXECUTABLE) MAKE_DIRECTORY(${CMAKE_CURRENT_BINARY_DIR}/data) ADD_CUSTOM_COMMAND( OUTPUT initdb.dep - COMMAND ${CMAKE_COMMAND} + COMMAND ${CMAKE_COMMAND} -E remove_directory data + COMMAND ${CMAKE_COMMAND} -E make_directory data + COMMAND ${CMAKE_COMMAND} -E chdir data ${CMAKE_COMMAND} ${CONFIG_PARAM} -P ${CMAKE_CURRENT_BINARY_DIR}/create_initial_db.cmake - WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/data + WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/ DEPENDS mysqld ) ADD_CUSTOM_TARGET(initial_database |