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

WITHOUT_SERVER cannot compile mariadb-binlog

Details

    Description

      Our team is getting the following error when trying to compile and install MariaDB Server version 10.6.18 from source with -DWITH_WSREP=ON:

      171.3 [ 90%] Building CXX object client/CMakeFiles/mariadb-binlog.dir/mysqlbinlog.cc.o

      171.3 In file included from /mariadb-10.6.18/sql/log_event_old.cc:35,

      171.3 from /mariadb-10.6.18/client/mysqlbinlog.cc:3251:

      171.3 /mariadb-10.6.18/sql/wsrep_mysqld.h:37:10: fatal error: wsrep/provider.hpp: No such file or directory

      171.3 37 | #include "wsrep/provider.hpp"

      171.3 | ^~~~~~~~~~~~~~~~~~~~

      171.3 compilation terminated.

      171.3 gmake[2]: *** [client/CMakeFiles/mariadb-binlog.dir/build.make:76: client/CMakeFiles/mariadb-binlog.dir/mysqlbinlog.cc.o] Error 1

      171.3 gmake[1]: *** [CMakeFiles/Makefile2:4016: client/CMakeFiles/mariadb-binlog.dir/all] Error 2

      171.3 gmake: *** [Makefile:166: all] Error 2

      Our compilation scripts work with 10.6.17 and previous versions.

      I had a look at the release notes for 10.6.18 but didn't spot anything that I believe could be related to this issue.

      I'm attaching a Dockerfile (based on our compilation script) that reproduces the error. To run the script do:

      DOCKER_BUILDGIT=1 docker build --progress=plain --build-arg VERSION=10.6.18 .

      Attachments

        Issue Links

          Activity

            danblack Daniel Black added a comment -

            cmake/wsrep.cmake WITHOUT_SERVER means the WSREP_ON= isn't available and more importantly for the compile INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/wsrep-lib/include) didn't set the include path for the provider.hpp header.

            danblack Daniel Black added a comment - cmake/wsrep.cmake WITHOUT_SERVER means the WSREP_ON= isn't available and more importantly for the compile INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/wsrep-lib/include) didn't set the include path for the provider.hpp header.
            danblack Daniel Black added a comment - sysprg , janlindstrom , can you please review https://github.com/MariaDB/server/pull/3311
            danblack Daniel Black added a comment - - edited

            dlresende, thanks for the bug report. Removing "-DWITH_WSREP=ON" from the cmake command line will enable it to build completely. Do you think there is anything missing by removing this? (mariadb-upgrade and mariadb-backup seem the likely ones to behave a little different).

            danblack Daniel Black added a comment - - edited dlresende , thanks for the bug report. Removing "-DWITH_WSREP=ON" from the cmake command line will enable it to build completely. Do you think there is anything missing by removing this? (mariadb-upgrade and mariadb-backup seem the likely ones to behave a little different).
            dlresende Diego Lemos added a comment - - edited

            danblack thanks for following up on this issue.
            I do not have a lot of context on MariaDB myself so I'm not sure whether we can do without -DWITH_WSREP=ON.
            Our use case is that we need bundle the client so that our users can connect to their databases. If they have a server with -DWITH_WSREP=ON but our client has not been compiled with the same options, I don't know whether that makes a difference or not... If it doesn't, its probably safe for us to turn it off.

            dlresende Diego Lemos added a comment - - edited danblack thanks for following up on this issue. I do not have a lot of context on MariaDB myself so I'm not sure whether we can do without -DWITH_WSREP=ON . Our use case is that we need bundle the client so that our users can connect to their databases. If they have a server with -DWITH_WSREP=ON but our client has not been compiled with the same options, I don't know whether that makes a difference or not... If it doesn't, its probably safe for us to turn it off.
            danblack Daniel Black added a comment -

            dlresende

            Thanks for the explanation. You are probably right, turning it off has implications. You could patch the build with the pull request https://patch-diff.githubusercontent.com/raw/MariaDB/server/pull/3311.patch

            major fixes include:

            • mariadb-backup - big bug fix around performing backups (work around per MDEVs)
            • mariadb-dump - incompatibility we were obliges to introduce to avoid a security path

            sysprg, janlindstrom, additionally because WSREP is still an option under WITHOUT_SERVER can you also review https://github.com/MariaDB/server/pull/3316 which makes it still a cmake OPTION under these conditions.

            danblack Daniel Black added a comment - dlresende Thanks for the explanation. You are probably right, turning it off has implications. You could patch the build with the pull request https://patch-diff.githubusercontent.com/raw/MariaDB/server/pull/3311.patch major fixes include: mariadb-backup - big bug fix around performing backups (work around per MDEVs) mariadb-dump - incompatibility we were obliges to introduce to avoid a security path sysprg , janlindstrom , additionally because WSREP is still an option under WITHOUT_SERVER can you also review https://github.com/MariaDB/server/pull/3316 which makes it still a cmake OPTION under these conditions.
            dlresende Diego Lemos added a comment -

            danblack thanks for all the context and the speedy patch. It's greatly appreciated.

            dlresende Diego Lemos added a comment - danblack thanks for all the context and the speedy patch. It's greatly appreciated.

            People

              danblack Daniel Black
              dlresende Diego Lemos
              Votes:
              0 Vote for this issue
              Watchers:
              2 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.