diff options
author | Ignacio Galarza <iggy@mysql.com> | 2009-07-31 15:22:02 -0400 |
---|---|---|
committer | Ignacio Galarza <iggy@mysql.com> | 2009-07-31 15:22:02 -0400 |
commit | 6df2af22ceda4a59fc43a661f6ecfac362e9783a (patch) | |
tree | 1ec946eb73a7116ce88cd568b44517de785490e0 /CMakeLists.txt | |
parent | ba9042167469f9dfd620aeebbce4d034caac26a1 (diff) | |
download | mariadb-git-6df2af22ceda4a59fc43a661f6ecfac362e9783a.tar.gz |
Bug#17270 - mysql client tool could not find ../share/charsets folder and fails.
- Define and pass compile time path variables as pre-processor definitions to
mimic the makefile build.
- Set new CMake version and policy requirements explicitly.
- Changed DATADIR to MYSQL_DATADIR to avoid conflicting definition in
Platform SDK header ObjIdl.h which also defines DATADIR.
Diffstat (limited to 'CMakeLists.txt')
-rwxr-xr-x | CMakeLists.txt | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 9f53a9fb146..5705a2dfe57 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -14,6 +14,9 @@ # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA CMAKE_MINIMUM_REQUIRED(VERSION 2.6 FATAL_ERROR) +IF(COMMAND cmake_policy) + cmake_policy(SET CMP0005 NEW) +ENDIF(COMMAND cmake_policy) PROJECT(MySql) @@ -26,6 +29,13 @@ CONFIGURE_FILE(${CMAKE_SOURCE_DIR}/include/mysql_version.h.in # Set standard options ADD_DEFINITIONS(-DCMAKE_BUILD) ADD_DEFINITIONS(-DHAVE_YASSL) +ADD_DEFINITIONS(-DCMAKE_CONFIGD) +ADD_DEFINITIONS(-DDEFAULT_MYSQL_HOME="c:/Program Files/MySQL/MySQL Server ${MYSQL_BASE_VERSION}/") +ADD_DEFINITIONS(-DDEFAULT_BASEDIR="c:/Program Files/MySQL/") +ADD_DEFINITIONS(-DMYSQL_DATADIR="c:/Program Files/MySQL/MySQL Server ${MYSQL_BASE_VERSION}/data") +ADD_DEFINITIONS(-DDEFAULT_CHARSET_HOME="c:/Program Files/MySQL/MySQL Server ${MYSQL_BASE_VERSION}/") +ADD_DEFINITIONS(-DPACKAGE=mysql) +ADD_DEFINITIONS(-DSHAREDIR="share") # Set debug options SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DFORCE_INIT_OF_VARS") |