Commit 4058115c authored by Vladislav Vaintroub's avatar Vladislav Vaintroub

LPBUG#779758 - fix missing alpha/beta etc in MSI and ZIP package names.

parent a0973ba2
......@@ -25,7 +25,7 @@ MACRO(GET_MYSQL_VERSION)
STRING(REGEX MATCH "[0-9]+\\.[0-9]+\\.[0-9]+" VERSION_STRING "${str}")
IF(NOT VERSION_STRING)
FILE(STRINGS configure.in str REGEX "AC_INIT\\(")
STRING(REGEX MATCH "[0-9]+\\.[0-9]+\\.[0-9]+[-][a-zA-Z0-9]+" VERSION_STRING "${str}")
STRING(REGEX MATCH "[0-9]+\\.[0-9]+\\.[0-9]+[-][a-zA-Z0-9-]+" VERSION_STRING "${str}")
IF(NOT VERSION_STRING)
STRING(REGEX MATCH "[0-9]+\\.[0-9]+\\.[0-9]+" VERSION_STRING "${str}")
ENDIF()
......@@ -34,6 +34,16 @@ MACRO(GET_MYSQL_VERSION)
ENDIF()
ENDIF()
SET(VERSION_EXTRA) #alpha beta gamma delta epsilon, etc
FOREACH(suffix alpha beta gamma)
IF(VERSION_STRING MATCHES "${suffix}")
SET(VERSION_EXTRA "-${suffix}")
ENDIF()
ENDFOREACH()
STRING(REGEX MATCH "[0-9]+\\.[0-9]+\\.[0-9]+[-][a-zA-Z0-9]+" VERSION_STRING "${str}")
IF(NOT VERSION_STRING)
MESSAGE(FATAL_ERROR
"VERSION_STRING cannot be parsed, please specify -DVERSION_STRING=major.minor.patch-extra"
......@@ -91,9 +101,9 @@ IF(NOT CPACK_PACKAGE_FILE_NAME)
ENDIF()
IF(NOT CPACK_SOURCE_PACKAGE_FILE_NAME)
SET(CPACK_SOURCE_PACKAGE_FILE_NAME "mariadb-${VERSION}")
SET(CPACK_SOURCE_PACKAGE_FILE_NAME "mariadb-${VERSION_STRING}${VERSION_EXTRA}")
ENDIF()
SET(CPACK_PACKAGE_CONTACT "MariaDB team <build@mysql.com>")
SET(CPACK_PACKAGE_CONTACT "MariaDB team <info@montyprogram.com>")
SET(CPACK_PACKAGE_VENDOR "Monty Program AB")
SET(CPACK_SOURCE_GENERATOR "TGZ")
INCLUDE(cpack_source_ignore_files)
......
......@@ -123,7 +123,7 @@ IF(NOT VERSION)
SET(PRODUCT_TAG)
ENDIF()
SET(package_name "mariadb${PRODUCT_TAG}-${MYSQL_NO_DASH_VERSION}-${SYSTEM_NAME_AND_PROCESSOR}")
SET(package_name "mariadb${PRODUCT_TAG}-${MYSQL_NO_DASH_VERSION}${VERSION_EXTRA}-${SYSTEM_NAME_AND_PROCESSOR}")
# Sometimes package suffix is added (something like "-icc-glibc23")
IF(PACKAGE_SUFFIX)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment