summaryrefslogtreecommitdiff
path: root/cmake/bison.cmake
diff options
context:
space:
mode:
authorVladislav Vaintroub <vvaintroub@mysql.com>2009-11-21 01:56:58 +0100
committerVladislav Vaintroub <vvaintroub@mysql.com>2009-11-21 01:56:58 +0100
commit68c7b41189a9b4505cc5c957608691788cae9538 (patch)
tree044e86cd6fcfd322dc6802ea32e1aa01fdb5df3e /cmake/bison.cmake
parent39641dfd65fd5c8e894a04c744b7a7f0b0e5e655 (diff)
downloadmariadb-git-68c7b41189a9b4505cc5c957608691788cae9538.tar.gz
Write some helpful messages to assist user, when prerequisite software is not found
(ncurses-devel or bison)
Diffstat (limited to 'cmake/bison.cmake')
-rw-r--r--cmake/bison.cmake16
1 files changed, 13 insertions, 3 deletions
diff --git a/cmake/bison.cmake b/cmake/bison.cmake
index b1c2d7393fa..9e01ef3d246 100644
--- a/cmake/bison.cmake
+++ b/cmake/bison.cmake
@@ -37,13 +37,13 @@ MACRO (RUN_BISON input_yy output_cc output_h)
IF(BISON_TOO_OLD)
IF(EXISTS ${output_cc} AND EXISTS ${output_h})
SET(BISON_USABLE FALSE)
- ENDIF()
+ ENDIF()
ENDIF()
IF(BISON_USABLE)
ADD_CUSTOM_COMMAND(
OUTPUT ${output_cc}
${output_h}
- COMMAND bison -y -p MYSQL
+ COMMAND ${BISON_EXECUTABLE} -y -p MYSQL
--output=${output_cc}
--defines=${output_h}
${input_yy}
@@ -58,7 +58,17 @@ MACRO (RUN_BISON input_yy output_cc output_h)
ENDIF()
ELSE()
# Output files are missing, bail out.
- MESSAGE(FATAL_ERROR "Please install bison.")
+ SET(ERRMSG
+ "Bison (GNU parser generator) is required to build MySQL."
+ "Please install bison."
+ )
+ IF(WIN32)
+ SET(ERRMSG ${ERRMSG}
+ "You can download bison from http://gnuwin32.sourceforge.net/packages/bison.htm "
+ "Choose 'Complete package, except sources' installation. We recommend to "
+ "install bison into a directory without spaces, e.g C:\\GnuWin32.")
+ ENDIF()
+ MESSAGE(FATAL_ERROR ${ERRMSG})
ENDIF()
ENDIF()
ENDMACRO()