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

CMAKE_INSTALL_PREFIX is ignored in 10.5 recently

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Major
    • Resolution: Cannot Reproduce
    • 10.5.3
    • 10.5.3
    • Compiling
    • Ubuntu 16.04

    Description

      I noted that recently CMAKE_INSTALL_PREFIX setting seem to be ignored in 10.5 branch from GitHub:

      openxs@ao756:~/git/server$ git branch
        10.0
      ...
        10.4
      * 10.5
        5.5
        bb-10.2-compatibility
        bb-10.2-marko
      openxs@ao756:~/git/server$ git log -1
      commit 1b81e9659377973e2044a1e3f0001a259bbd7199
      Author: Kentoku SHIBA <kentokushiba@gmail.com>
      Date:   Wed Apr 22 04:44:28 2020 +0900
       
          MDEV-21884 MariaDB with Spider crashes on a query
       
          Fix a test result.
      

      I build as usual (out of source in build subdirectory):

      cmake .. -DCMAKE_BUILD_TYPE=RelWithDebInfo -DWITH_SSL=system -DWITH_ZLIB=bundled -DMYSQL_MAINTAINER_MODE=OFF -DENABLED_LOCAL_INFILE=1 -DWITH_JEMALLOC=system -DWITH_INNODB_DISALLOW_WRITES=ON -DCMAKE_INSTALL_PREFIX=/home/openxs/dbs/maria10.5
      

      and setting seem to be there:

      openxs@ao756:~/git/server/build$ grep -rn CMAKE_INSTALL_PREFIX * | grep maria10
      zlib/cmake_install.cmake:5:  set(CMAKE_INSTALL_PREFIX "/home/openxs/dbs/maria10.5")
       
      openxs@ao756:~/git/server/build$ time make -j 2
      ...
      [ 99%] Linking CXX executable explain_filename-t
      [ 99%] Linking CXX executable mariadb-backup
      [ 99%] Built target explain_filename-t
      [ 99%] Linking CXX executable mariadbd
      Creating mariabackup link
      [100%] Built target mariadb-backup
      Creating mysqld link
      [100%] Built target mariadbd
       
      real    4m8.257s
      user    2m10.360s
      sys     0m32.984s
       
      openxs@ao756:~/git/server/build$ make install
      ...
      [100%] Built target wsrep_check_version
      [100%] Built target my_safe_process
      Linking CXX executable CMakeFiles/CMakeRelink.dir/mariadb-backup
      Linking CXX shared module CMakeFiles/CMakeRelink.dir/ha_rocksdb.so
      Linking CXX executable CMakeFiles/CMakeRelink.dir/sst_dump
      Linking CXX executable CMakeFiles/CMakeRelink.dir/mariadb-ldb
      Linking CXX executable CMakeFiles/CMakeRelink.dir/mariadb
      Linking CXX executable CMakeFiles/CMakeRelink.dir/mariadbd
      Install the project...
      -- Install configuration: "RelWithDebInfo"
      CMake Error at cmake_install.cmake:43 (file):
        file cannot create directory: /usr/local/mysql/..  Maybe need
        administrative privileges.
       
       
      Makefile:115: recipe for target 'install' failed
      make: *** [install] Error 1
      

      But as you can see above it tries to install to the default path, /usr/local/mysql/.

      It was not the case just few days ago, so must be a result of some recent enough change in the code. 10.4 branch was built and installed without problems yesterday.

      Attachments

        Activity

          People

            Unassigned Unassigned
            valerii Valerii Kravchuk
            Votes:
            1 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.