Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-8962

TokuDB tries to build on OS X, even when disabled in compile flag

Details

    • 10.1.9-3

    Description

      I compile MariaDB from a shell script that I have written that runs CMake from the command line. I do not use a repository like Homebrew. When compiling 10.1.8 on my OS X 10.11 MacBook Pro, I ran into a couple of issues. The first was easy to sort out and involved patching a CMakesList.txt file so mroonga will compile with clang.

      The other issue was a bit more perplexing. I disable TokuDB in my builds with “-DWITHOUT_TOKUDB_STORAGE_ENGINE=ON”. This does not work 10.1.8 and my builds kept failing during make when the script tried to build TokuDB. I also tried using “-DWITH_TOKUDB_STORAGE_ENGINE=OFF” and “-DWITHOUT_TOKUDB=1” in my script, but make still wanted to build TokuDB. Interestingly, if I used the CMake GUI and un-ticked TokuDB, make was successful.

      Eventually, I compared the CMakeList.txt for TokuDB in 10.1.8 to the one in 10.0.21. I replaced this section from the 10.1.8 TokuDB CMakeList.txt file…

      IF(NOT TOKUDB_OK OR PLUGIN_TOKUDB STREQUAL "NO")
        RETURN()
      ENDIF()

      with this from the 10.0.21 TokuDB CMakeList.txt file:

      IF(NOT TOKUDB_OK OR WITHOUT_TOKUDB OR WITHOUT_TOKUDB_STORAGE_ENGINE)
        RETURN()
      ENDIF()

      Now my code builds without TokuDB.

      It looks like the 10.1.8 change to the TokuDB CMakeList.txt broke the ability to compile on OS X. Or has the syntax changed for disabling TokuDB?

      Attachments

        Activity

          richardhd Richard Dunn added a comment -

          Note, I also tried -DPLUGIN_tokudb=NO and that does not work either.

          richardhd Richard Dunn added a comment - Note, I also tried -DPLUGIN_tokudb=NO and that does not work either.
          richardhd Richard Dunn added a comment -

          Okay, it's case-sensitive – -DPLUGIN_TOKUDB=NO does work.

          Having said that, if the default setting is 'DYNAMIC', I would think that TokuDB would be disabled if OS X is detected.

          richardhd Richard Dunn added a comment - Okay, it's case-sensitive – -DPLUGIN_TOKUDB=NO does work. Having said that, if the default setting is 'DYNAMIC', I would think that TokuDB would be disabled if OS X is detected.

          I agree, the whole check looks weird. According to the KB page and final comments in MDEV-6248, DYNAMIC is supposed to mean "compile dynamically, if possible, otherwise not at all".

          Apparently that's not what happens now.

          Our OS X builder successfully skips TokuDB, but that's because it runs cmake 2.8.8, so the very first check fails. However, a newer cmake passes the test and later issues the warning:

          CMake Warning at storage/tokudb/CMakeLists.txt:17 (MESSAGE):
            TokuDB is enabled, but jemalloc is not.  This configuration is not
            supported

          Why not to disable TokuDB at this point, unless it's forced by cmake options?

          elenst Elena Stepanova added a comment - I agree, the whole check looks weird. According to the KB page and final comments in MDEV-6248 , DYNAMIC is supposed to mean "compile dynamically, if possible, otherwise not at all". Apparently that's not what happens now. Our OS X builder successfully skips TokuDB, but that's because it runs cmake 2.8.8, so the very first check fails. However, a newer cmake passes the test and later issues the warning: CMake Warning at storage/tokudb/CMakeLists.txt:17 (MESSAGE): TokuDB is enabled, but jemalloc is not. This configuration is not supported Why not to disable TokuDB at this point, unless it's forced by cmake options?

          People

            serg Sergei Golubchik
            richardhd Richard Dunn
            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.