mirror of
https://github.com/MariaDB/server.git
synced 2025-01-17 20:42:30 +01:00
#92 add compiler and cmake checks from mariadb
This commit is contained in:
parent
9e67557d89
commit
3152434eeb
1 changed files with 16 additions and 0 deletions
|
@ -1,3 +1,19 @@
|
|||
# ft-index only supports x86-64 and cmake-2.8.9+
|
||||
IF(CMAKE_SYSTEM_PROCESSOR STREQUAL "x86_64" AND
|
||||
NOT CMAKE_VERSION VERSION_LESS "2.8.9" AND
|
||||
NOT WITHOUT_TOKUDB AND NOT WITHOUT_TOKUDB_STORAGE_ENGINE)
|
||||
CHECK_CXX_SOURCE_COMPILES(
|
||||
"
|
||||
struct a {int b; int c; };
|
||||
struct a d = { .b=1, .c=2 };
|
||||
int main() { return 0; }
|
||||
" TOKUDB_OK)
|
||||
ENDIF()
|
||||
|
||||
IF(NOT TOKUDB_OK)
|
||||
RETURN()
|
||||
ENDIF()
|
||||
|
||||
IF(DEFINED ENV{TOKUDB_VERSION})
|
||||
SET(TOKUDB_VERSION $ENV{TOKUDB_VERSION})
|
||||
ADD_DEFINITIONS("-DTOKUDB_VERSION=\"${TOKUDB_VERSION}\"")
|
||||
|
|
Loading…
Reference in a new issue