Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-17136

Misleading ./configure error on Ubuntu-based distributions

XMLWordPrintable

    • Sprint 60 (Jan 2020)
    • 0.25

      Steps to reproduce:

      1. Install MySQL client 5.7.28 on an Ubuntu-based system (such as Ubuntu 18.04, Mint 18.3) without SSL dev library
      2. Run ./configure --enable-server --with-mysql

      Result:
      ./configure fails with the following error:

      checking size of void *... 8
      checking for mysql_config... /usr/bin/mysql_config
      checking for main in -lmysqlclient... no
      configure: error: Not found mysqlclient library
      

      Even though mysqlclient library is installed ./configure fails with the misleading error message. The real reason found in config.log:

      configure:8260: checking for mysql_config
      configure:8278: found /usr/bin/mysql_config
      configure:8290: result: /usr/bin/mysql_config
      configure:8317: checking for main in -lmysqlclient
      configure:8336: cc -o conftest -g -O2 -I/usr/include/mysql   -rdynamic  -L/usr/lib/x86_64-linux-gnu -lmysqlclient -lpthread -lz -lm -lrt -lssl -lcrypto -ldl conftest.c -lmysqlclient  -lm -ldl  -lresolv >&5
      /usr/bin/ld: cannot find -lssl
      /usr/bin/ld: cannot find -lcrypto
      collect2: error: ld returned 1 exit status
      

      Expected:
      The script should either give a clear reason for the failure, something like:

      configure: error: cannot find -lssl, -lcrypto
      

      or at least instruct how to debug the problem:

      configure: error: -lmysqlclient not found or failed to link, please see config.log for additional information
      

            atumilovics Andrejs Tumilovics
            Kalimulin Alex Kalimulin
            Team C
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: