Uploaded image for project: 'MariaDB Connector/C'
  1. MariaDB Connector/C
  2. CONC-498

mysql.h missing #include "mysql_version.h"

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Major
    • Resolution: Fixed
    • 3.1.9
    • 3.1.10
    • None
    • None

    Description

      comparison of mysql_version.h includes

      $ grep -r  'mysql_version\.h'      /usr/local/m*/include/
      /usr/local/mariadb-10.5.6/include/mysql/server/mysql.h:#include "mysql_version.h"
      /usr/local/mariadb-10.5.6/include/mysql/server/private/unireg.h:#include <mysql_version.h>                      /* FRM_VER */
      /usr/local/mariadb-10.5.6/include/mysql/server/private/sql_const.h:#include <mysql_version.h>
      /usr/local/mysql-5.6.49-linux-glibc2.12-x86_64/include/mysql.h:#include "mysql_version.h"
      /usr/local/mysql-5.7.31-linux-glibc2.12-x86_64/include/mysql/plugin.h:#include "mysql_version.h" /* MYSQL_VERSION_ID */
      /usr/local/mysql-5.7.31-linux-glibc2.12-x86_64/include/mysql.h:#include "mysql_version.h"
      /usr/local/mysql-5.7.31-linux-glibc2.12-x86_64/include/plugin.h:#include "mysql_version.h" /* MYSQL_VERSION_ID */
      /usr/local/mysql-8.0.21-linux-glibc2.12-x86_64/include/mysql.h:#include "mysql_version.h"  // IWYU pragma: keep
      

      Without it defines ike MYSQL_UNIX_ADDR aren't exposed tot he client as per the php-7.3 compile error:

      php-7.3 version=mariadb-10.5.6; ../php-src/configure --enable-debug --with-mysqli=/usr/local/$version/bin/mysql_config --with-pdo-mysql=/usr/local/$version

       
      /home/dan/repos/php-src/ext/mysqli/mysqli.c: In function ‘zm_info_mysqli’:
      /home/dan/repos/php-src/ext/mysqli/mysqli.c:972:47: error: ‘MYSQL_UNIX_ADDR’ undeclared (first use in this function); did you mean ‘PDO_MYSQL_UNIX_ADDR’?
        972 |  php_info_print_table_row(2, "MYSQLI_SOCKET", MYSQL_UNIX_ADDR);
            |                                               ^~~~~~~~~~~~~~~
            |                                               PDO_MYSQL_UNIX_ADDR
      /home/dan/repos/php-src/ext/mysqli/mysqli.c:972:47: note: each undeclared identifier is reported only once for each function it appears in
      

      Attachments

        Issue Links

          Activity

            People

              georg Georg Richter
              danblack Daniel Black
              Votes:
              0 Vote for this issue
              Watchers:
              1 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.