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

build failure with RocksDB, incompatible pointer to integer conversion

    XMLWordPrintable

Details

    Description

      MariaDB server does not build on FreeBSD 13.2 when RocksDB is enabled.
      Build failed on this error:

      /usr/bin/c++ -DBZIP2 -DHAVE_CONFIG_H -DHAVE_SCHED_GETCPU=1 -DHAVE_TIMER_DELETE -DLZ4 -DOS_FREEBSD -DROCKSDB_JEMALLOC -DROCKSDB_LIB_IO_POSIX -DROCKSDB_MALLOC_USABLE_SIZE -DROCKSDB_PLATFORM_POSIX -DROCKSDB_SCHED_GETCPU_PRESENT -DROCKSDB_SUPPORT_THREAD_LOCAL -DZLIB -DZSTD -I/wrkdirs/usr/ports/databases/mariadb106-server/work/mariadb-10.6.12/wsrep-lib/include -I/wrkdirs/usr/ports/databases/mariadb106-server/work/mariadb-10.6.12/wsrep-lib/wsrep-API/v26 -I/wrkdirs/usr/ports/databases/mariadb106-server/work/mariadb-10.6.12/include -I/wrkdirs/usr/ports/databases/mariadb106-server/work/mariadb-10.6.12/sql -I/wrkdirs/usr/ports/databases/mariadb106-server/work/mariadb-10.6.12/storage/rocksdb -I/wrkdirs/usr/ports/databases/mariadb106-server/work/mariadb-10.6.12/storage/rocksdb/rocksdb -I/wrkdirs/usr/ports/databases/mariadb106-server/work/mariadb-10.6.12/storage/rocksdb/rocksdb/include -I/wrkdirs/usr/ports/databases/mariadb106-server/work/mariadb-10.6.12/storage/rocksdb/rocksdb/util -isystem /wrkdirs/usr/ports/databases/mariadb106-server/work/mariadb-10.6.12/storage/rocksdb/rocksdb/third-party/gtest-1.7.0/fused-src -O2 -pipe -fstack-protector-strong -isystem /usr/local/include -fno-strict-aliasing  -isystem /usr/local/include -fstack-protector --param=ssp-buffer-size=4 -Wno-range-loop-construct -O2 -pipe -fstack-protector-strong -isystem /usr/local/include -fno-strict-aliasing  -isystem /usr/local/include  -DNDEBUG -D_FORTIFY_SOURCE=2 -DDBUG_OFF   -isystem /usr/local/include -fPIC -std=gnu++11 -MD -MT storage/rocksdb/CMakeFiles/rocksdb_aux_lib.dir/rdb_cf_options.cc.o -MF storage/rocksdb/CMakeFiles/rocksdb_aux_lib.dir/rdb_cf_options.cc.o.d -o storage/rocksdb/CMakeFiles/rocksdb_aux_lib.dir/rdb_cf_options.cc.o -c /wrkdirs/usr/ports/databases/mariadb106-server/work/mariadb-10.6.12/storage/rocksdb/rdb_cf_options.cc
      In file included from /wrkdirs/usr/ports/databases/mariadb106-server/work/mariadb-10.6.12/storage/rocksdb/rdb_cf_options.cc:36:
      In file included from /wrkdirs/usr/ports/databases/mariadb106-server/work/mariadb-10.6.12/storage/rocksdb/./ha_rocksdb.h:53:
      In file included from /wrkdirs/usr/ports/databases/mariadb106-server/work/mariadb-10.6.12/storage/rocksdb/./rdb_buff.h:47:
      In file included from /wrkdirs/usr/ports/databases/mariadb106-server/work/mariadb-10.6.12/storage/rocksdb/./rdb_global.h:30:
      /wrkdirs/usr/ports/databases/mariadb106-server/work/mariadb-10.6.12/storage/rocksdb/./ut0counter.h:64:10: error: incompatible pointer to integer conversion assigning to 'size_t' (aka 'unsigned long') from 'pthread_t' (aka 'pthread *')
                              cpu = get_curr_thread_id();
                                    ^~~~~~~~~~~~~~~~~~~~
      /wrkdirs/usr/ports/databases/mariadb106-server/work/mariadb-10.6.12/storage/rocksdb/./ut0counter.h:34:30: note: expanded from macro 'get_curr_thread_id'
      #define get_curr_thread_id() pthread_self()
                                   ^~~~~~~~~~~~~~
      1 error generated.
      ninja: build stopped: subcommand failed.
      *** Error code 1
       
      Stop.
      make: stopped in /usr/ports/databases/mariadb106-server
      =>> Cleaning up wrkdir
      ===>  Cleaning for mariadb106-server-10.6.12
      build of databases/mariadb106-server | mariadb106-server-10.6.12 ended at Tue Apr 25 00:30:22 CEST 2023
      build time: 00:21:48
      !!! build failure encountered !!!
      

      Build is OK if RocksDB is disabled.

      Also reported to FreeBSD's bugzilla https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=271060

      Attachments

        Activity

          People

            serg Sergei Golubchik
            Lachman Miroslav Lachman
            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.