Uploaded image for project: 'MariaDB ColumnStore'
  1. MariaDB ColumnStore
  2. MCOL-3981

doesn't build with old (2.8.x) cmake

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Major
    • Resolution: Fixed
    • None
    • 1.5.1
    • None
    • None
    • 2020-7

    Description

      Old cmake (that is used on some buildbot builders) doesn't understand DEFINES_FILE in the BISON_TARGET. As a workaround, specify --defines= explicitly in COMPILE_FLAGS. On the other hand, newer cmake that supports DEFINES_FILE needs it for proper dependency tracking. So, as a fix, use both, yes, it's redundant.

      diff --git a/dbcon/ddlpackage/CMakeLists.txt b/dbcon/ddlpackage/CMakeLists.txt
      index c18bf6ab..7ce5207f 100644
      --- a/dbcon/ddlpackage/CMakeLists.txt
      +++ b/dbcon/ddlpackage/CMakeLists.txt
      @@ -1,7 +1,9 @@
       INCLUDE_DIRECTORIES( ${ENGINE_COMMON_INCLUDES} )
       
       FIND_PACKAGE(BISON REQUIRED)
      -BISON_TARGET(ddl_gram ddl.y ${CMAKE_CURRENT_BINARY_DIR}/ddl-gram.cpp DEFINES_FILE ${CMAKE_CURRENT_BINARY_DIR}/ddl-gram.h COMPILE_FLAGS "-l -d -p ddl")
      +BISON_TARGET(ddl_gram ddl.y ${CMAKE_CURRENT_BINARY_DIR}/ddl-gram.cpp
      +  DEFINES_FILE ${CMAKE_CURRENT_BINARY_DIR}/ddl-gram.h
      +  COMPILE_FLAGS "-l -p ddl --defines=${CMAKE_CURRENT_BINARY_DIR}/ddl-gram.h")
       
       FIND_PACKAGE(FLEX REQUIRED)
       FLEX_TARGET(ddl_scan ddl.l ${CMAKE_CURRENT_BINARY_DIR}/ddl-scan.cpp COMPILE_FLAGS "-i -L -Pddl")
      diff --git a/dbcon/dmlpackage/CMakeLists.txt b/dbcon/dmlpackage/CMakeLists.txt
      index 8982de1a..da3129ac 100644
      --- a/dbcon/dmlpackage/CMakeLists.txt
      +++ b/dbcon/dmlpackage/CMakeLists.txt
      @@ -2,7 +2,9 @@
       INCLUDE_DIRECTORIES( ${ENGINE_COMMON_INCLUDES} )
       
       FIND_PACKAGE(BISON REQUIRED)
      -BISON_TARGET(dml_gram dml.y ${CMAKE_CURRENT_BINARY_DIR}/dml-gram.cpp DEFINES_FILE ${CMAKE_CURRENT_BINARY_DIR}/dml-gram.h COMPILE_FLAGS "-l -d -p dml")
      +BISON_TARGET(dml_gram dml.y ${CMAKE_CURRENT_BINARY_DIR}/dml-gram.cpp
      +  DEFINES_FILE ${CMAKE_CURRENT_BINARY_DIR}/dml-gram.h
      +  COMPILE_FLAGS "-l -p dml --defines=${CMAKE_CURRENT_BINARY_DIR}/dml-gram.h")
       
       FIND_PACKAGE(FLEX REQUIRED)
       FLEX_TARGET(dml_scan dml.l ${CMAKE_CURRENT_BINARY_DIR}/dml-scan.cpp COMPILE_FLAGS "-i -L -Pdml")
      

      Attachments

        Issue Links

          Activity

            People

              dleeyh Daniel Lee (Inactive)
              serg Sergei Golubchik
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.