Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Set-up MariaDB library file location programmatically?
Forum Updated to NodeBB v4.3 + New Features

Set-up MariaDB library file location programmatically?

Scheduled Pinned Locked Moved Solved General and Desktop
85 Posts 7 Posters 34.6k Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • SPlattenS SPlatten

    @jsulm , thank you.

    So already I'm struggling with the answer on: https://stackoverflow.com/questions/6483523/qt-how-to-getcompile-mysql-driver

    I cannot find the driver sources, my Qt path looks like this:

    /Users/simonplatten/qt/5.14.2/Src
    

    There is no plugins folder in there, the only plugins folder is:

    /Users/simonplatten/qt/5.14.2/clang_64/plugins
    

    That doesn't contain a mysql folder. I just did:

    sudo find / -name sqldrivers/mysql
    

    Nothing was found on my system.

    I've tried to follow the instructions on https://doc.qt.io/qt-5/sql-driver.html#qmysql
    I fall at the first hurdle, I don't have the environment variable QTDIR set and I think my installation of MariaDB is complicated by the fact it was installed using Homebrew.

    JonBJ Offline
    JonBJ Offline
    JonB
    wrote on last edited by JonB
    #22

    @SPlatten said in Set-up MariaDB library file location programmatically?:

    That doesn't contain a mysql folder. I just did:
    sudo find / -name sqldrivers/mysql

    Nothing was found on my system.

    I realize this is probably not your issue here, but I think you ought be aware, at least for future searches, that -name abc/def --- with that / --- will always return false, so you'll never find a match.

    On MacOS (I'm Ubuntu) I think you'll find you would have to use -path instead, plus you want a substring match, so you would need e.g.:

    sudo find / -path '*sqldrivers/mysql' -print
    

    P.S.
    Don't forget the -print which you didn't show you used, else find is remarkably silent ;-)

    1 Reply Last reply
    3
    • SPlattenS Offline
      SPlattenS Offline
      SPlatten
      wrote on last edited by
      #23

      @jsulm , thank you, just executed that and found:

      /System/Volumes/Data/Users/simonplatten/Qt/5.15.0/Src/qtbase/src/plugins/sqldrivers/mysql
      /System/Volumes/Data/Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/mysql
      

      Kind Regards,
      Sy

      JonBJ 1 Reply Last reply
      0
      • jsulmJ jsulm

        @SPlatten I'm not a lawyer and not working for QtCompany (that's why I suggested to ask the company).
        You say: you are now developing an app and you want to release it later as closed source. And you want to buy Qt license when you want to release the app. My point was: QtCompany could say that you actually need the commercial license from the beginning as you're developing a closed source application which is going to be distributed. I may be wrong here, but it is worth checking.

        If you're not going to distribute your app then there is no issue.

        J.HilkJ Offline
        J.HilkJ Offline
        J.Hilk
        Moderators
        wrote on last edited by
        #24

        @jsulm said in Set-up MariaDB library file location programmatically?:

        My point was: QtCompany could say that you actually need the commercial license from the beginning as you're developing a closed source application which is going to be distributed. I may be wrong here, but it is worth checking.

        You do, or at least the QtC want you to, I had the issue when I wanted to open source a project that was previously made under QtLicence, slightly different but that exact topic came up.

        It's due to the yearly licensing scam scheme, would be no issue at all if it was a one purchase last for ever kind of deal


        Be aware of the Qt Code of Conduct, when posting : https://forum.qt.io/topic/113070/qt-code-of-conduct


        Q: What's that?
        A: It's blue light.
        Q: What does it do?
        A: It turns blue.

        1 Reply Last reply
        0
        • SPlattenS SPlatten

          @jsulm , thank you, just executed that and found:

          /System/Volumes/Data/Users/simonplatten/Qt/5.15.0/Src/qtbase/src/plugins/sqldrivers/mysql
          /System/Volumes/Data/Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/mysql
          
          JonBJ Offline
          JonBJ Offline
          JonB
          wrote on last edited by
          #25

          @SPlatten said in Set-up MariaDB library file location programmatically?:

          @jsulm , thank you, just executed that and found:

          @jsulm says it's a pleasure, on my behalf ;-)

          1 Reply Last reply
          1
          • SPlattenS Offline
            SPlattenS Offline
            SPlatten
            wrote on last edited by SPlatten
            #26

            I've been trying to follow: https://doc.qt.io/qt-5/sql-driver.html

            Lots of issues, for starters a terminal at:/Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/mysql

            Executing qmake: ~/Qt/5.14.2/clang_64/bin/qmake -version

            Does not return the same I only get:

            QMake version 3.1
            Using Qt version 5.14.2 in /Users/simonplatten/Qt/5.14.2/clang_64/lib
            

            I could do with some help on how to turn the source into a driver.

            I got a little further:

            export QTDIR=/Users/simonplatten/Qt/5.14.2
            export QTDIRBIN=$QTDIR/clang_64/bin
            cd $QTDIR/Src/qtbase/src/plugins/sqldrivers 
            $QTDIRBIN/qmake -- MYSQL_PREFIX=/usr/local
            
            Running configuration tests...
            Checking for DB2 (IBM)... no
            Checking for InterBase... no
            Checking for MySQL... no
            Checking for OCI (Oracle)... no
            Checking for ODBC... no
            Checking for PostgreSQL... no
            Checking for SQLite (version 2)... no
            Checking for TDS (Sybase)... no
            Done running configuration tests.
            
            Configure summary:
            
            Qt Sql Drivers:
              DB2 (IBM) .............................. no
              InterBase .............................. no
              MySql .................................. no
              OCI (Oracle) ........................... no
              ODBC ................................... no
              PostgreSQL ............................. no
              SQLite2 ................................ no
              SQLite ................................. yes
                Using system provided SQLite ......... no
              TDS (Sybase) ........................... no
            
            Qt is now configured for building. Just run 'make'.
            Once everything is built, you must run 'make install'.
            Qt will be installed into '/Users/simonplatten/Qt/5.14.2/clang_64'.
            
            Prior to reconfiguration, make sure you remove any leftovers from
            the previous build.
            

            I then ran "make", waited for it to complete. Some errors at the end:

            Project ERROR: Library 'freetype' is not defined.
            make[1]: *** [sub-minimal-make_first] Error 3
            make: *** [sub-platforms-make_first] Error 2
            

            Then run "make install".

            It would appear this has not built the driver as I still see in the Application Output:

            Warning:QSqlDatabase: QMYSQL driver not loaded
            Warning:QSqlDatabase: available drivers: QSQLITE QODBC QODBC3 QPSQL QPSQL7
            Info: L00000001:onFailure: db, failure: Driver not loaded Driver not loaded
            

            Why does it appear that its all set-up to build sqlite and NOT mysql ?

            Kind Regards,
            Sy

            SPlattenS 1 Reply Last reply
            0
            • SPlattenS SPlatten

              I've been trying to follow: https://doc.qt.io/qt-5/sql-driver.html

              Lots of issues, for starters a terminal at:/Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/mysql

              Executing qmake: ~/Qt/5.14.2/clang_64/bin/qmake -version

              Does not return the same I only get:

              QMake version 3.1
              Using Qt version 5.14.2 in /Users/simonplatten/Qt/5.14.2/clang_64/lib
              

              I could do with some help on how to turn the source into a driver.

              I got a little further:

              export QTDIR=/Users/simonplatten/Qt/5.14.2
              export QTDIRBIN=$QTDIR/clang_64/bin
              cd $QTDIR/Src/qtbase/src/plugins/sqldrivers 
              $QTDIRBIN/qmake -- MYSQL_PREFIX=/usr/local
              
              Running configuration tests...
              Checking for DB2 (IBM)... no
              Checking for InterBase... no
              Checking for MySQL... no
              Checking for OCI (Oracle)... no
              Checking for ODBC... no
              Checking for PostgreSQL... no
              Checking for SQLite (version 2)... no
              Checking for TDS (Sybase)... no
              Done running configuration tests.
              
              Configure summary:
              
              Qt Sql Drivers:
                DB2 (IBM) .............................. no
                InterBase .............................. no
                MySql .................................. no
                OCI (Oracle) ........................... no
                ODBC ................................... no
                PostgreSQL ............................. no
                SQLite2 ................................ no
                SQLite ................................. yes
                  Using system provided SQLite ......... no
                TDS (Sybase) ........................... no
              
              Qt is now configured for building. Just run 'make'.
              Once everything is built, you must run 'make install'.
              Qt will be installed into '/Users/simonplatten/Qt/5.14.2/clang_64'.
              
              Prior to reconfiguration, make sure you remove any leftovers from
              the previous build.
              

              I then ran "make", waited for it to complete. Some errors at the end:

              Project ERROR: Library 'freetype' is not defined.
              make[1]: *** [sub-minimal-make_first] Error 3
              make: *** [sub-platforms-make_first] Error 2
              

              Then run "make install".

              It would appear this has not built the driver as I still see in the Application Output:

              Warning:QSqlDatabase: QMYSQL driver not loaded
              Warning:QSqlDatabase: available drivers: QSQLITE QODBC QODBC3 QPSQL QPSQL7
              Info: L00000001:onFailure: db, failure: Driver not loaded Driver not loaded
              

              Why does it appear that its all set-up to build sqlite and NOT mysql ?

              SPlattenS Offline
              SPlattenS Offline
              SPlatten
              wrote on last edited by
              #27

              Can anyone help with this as I still haven't managed to build the Qt MySQL Plugin?

              Kind Regards,
              Sy

              jsulmJ 1 Reply Last reply
              0
              • SPlattenS SPlatten

                Can anyone help with this as I still haven't managed to build the Qt MySQL Plugin?

                jsulmJ Offline
                jsulmJ Offline
                jsulm
                Lifetime Qt Champion
                wrote on last edited by
                #28

                @SPlatten There is no point to run "make install" if make failed...
                Install libfreetype-dev package and try again.

                Also, if you see "Checking for MySQL... no" in configure output, then why even bother calling make?!
                To see why MySQL is disabled check the configure.log file.

                https://forum.qt.io/topic/113070/qt-code-of-conduct

                1 Reply Last reply
                0
                • SPlattenS Offline
                  SPlattenS Offline
                  SPlatten
                  wrote on last edited by
                  #29

                  I'v been through the steps again:

                  cd $QTDIR/Src/qtbase/src/plugins/sqldrivers 
                  $QTDIRBIN/qmake -- MYSQL_PREFIX=/usr/local
                  

                  The output is the same:

                  Running configuration tests... 
                  Done running configuration tests.
                  
                  Configure summary:
                  
                  Qt Sql Drivers:
                    DB2 (IBM) .............................. no
                    InterBase .............................. no
                    MySql .................................. no
                    OCI (Oracle) ........................... no
                    ODBC ................................... no
                    PostgreSQL ............................. no
                    SQLite2 ................................ no
                    SQLite ................................. yes
                      Using system provided SQLite ......... no
                    TDS (Sybase) ........................... no
                  
                  Qt is now configured for building. Just run 'make'.
                  Once everything is built, you must run 'make install'.
                  Qt will be installed into '/Users/simonplatten/Qt/5.14.2/clang_64'.
                  
                  Prior to reconfiguration, make sure you remove any leftovers from
                  the previous build.
                  

                  Again it looks like its set-up to build SQLite and not MySQL. I then run make and the result is:

                  cd sqlite/ && ( test -e Makefile || /Users/simonplatten/Qt/5.14.2/clang_64/bin/qmake -o Makefile /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/sqlite/sqlite.pro ) && /Applications/Xcode.app/Contents/Developer/usr/bin/make -f Makefile 
                  make[1]: Nothing to be done for `first'.
                  

                  @jsulm , I tried your instruction:

                  install: libfreetype-dev: No such file or directory
                  

                  'config.log' is quite verbose:

                  Command line: MYSQL_PREFIX=/usr/local
                  Global lib dirs: [] [/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/usr/lib]
                  Global inc dirs: [/usr/local/opt/openssl/include] [/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1 /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/11.0.3/include /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/usr/include /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include]
                  loaded result for library config.sqldrivers.libraries.db2
                  Trying source 0 (type inline) of library db2 ...
                    => source failed condition 'config.win32'.
                  Trying source 1 (type inline) of library db2 ...
                  sqlcli.h not found in [] and global paths.
                  sqlcli1.h not found in [] and global paths.
                    => source produced no result.
                  test config.sqldrivers.libraries.db2 FAILED
                  loaded result for library config.sqldrivers.libraries.ibase
                  Trying source 0 (type inline) of library ibase ...
                    => source failed condition 'config.win32'.
                  Trying source 1 (type inline) of library ibase ...
                  ibase.h not found in [] and global paths.
                    => source produced no result.
                  test config.sqldrivers.libraries.ibase FAILED
                  loaded result for library config.sqldrivers.libraries.mysql
                  Trying source 0 (type mysqlConfig) of library mysql ...
                  + /usr/local/bin/mysql_config --version
                  > 10.4.6
                  + /usr/local/bin/mysql_config --libs_r
                  > -L/usr/local/Cellar/mariadb/10.4.6_1/lib  -lmariadb -lz -liconv -lssl -lcrypto
                  + /usr/local/bin/mysql_config --include
                  > -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql/..
                  + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && /Users/simonplatten/Qt/5.14.2/clang_64/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" 'INCLUDEPATH += /usr/local/opt/openssl/include' 'QMAKE_USE += mysql' 'QMAKE_LIBS_MYSQL = -L/usr/local/Cellar/mariadb/10.4.6_1/lib' 'QMAKE_INCDIR_MYSQL = /usr/local/Cellar/mariadb/10.4.6_1/include/mysql /usr/local/Cellar/mariadb/10.4.6_1/include' /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql
                  > Info: creating stash file /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/.qmake.stash
                  + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && MAKEFLAGS= make
                  > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -c -pipe -stdlib=libc++ -O2 -std=gnu++11  -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -w -fPIC  -I. -I/usr/local/opt/openssl/include -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include -I/Users/simonplatten/Qt/5.14.2/clang_64/mkspecs/macx-clang -o main.o main.cpp
                  > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -stdlib=libc++ -headerpad_max_install_names  -arch x86_64 -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -Wl,-rpath,@executable_path/../Frameworks -o mysql main.o   -L/usr/local/Cellar/mariadb/10.4.6_1/lib   
                  > Undefined symbols for architecture x86_64:
                  >   "_mysql_get_client_version", referenced from:
                  >       _main in main.o
                  > ld: symbol(s) not found for architecture x86_64
                  > clang: error: linker command failed with exit code 1 (use -v to see invocation)
                  > make: *** [mysql] Error 1
                   => source failed verification.
                  Trying source 1 (type mysqlConfig) of library mysql ...
                  + /usr/local/bin/mysql_config --version
                  > 10.4.6
                  + /usr/local/bin/mysql_config --libs
                  > -L/usr/local/Cellar/mariadb/10.4.6_1/lib  -lmariadb -lz -liconv -lssl -lcrypto
                  + /usr/local/bin/mysql_config --include
                  > -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql/..
                  + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && /Users/simonplatten/Qt/5.14.2/clang_64/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" 'INCLUDEPATH += /usr/local/opt/openssl/include' 'QMAKE_USE += mysql' 'QMAKE_LIBS_MYSQL = -L/usr/local/Cellar/mariadb/10.4.6_1/lib' 'QMAKE_INCDIR_MYSQL = /usr/local/Cellar/mariadb/10.4.6_1/include/mysql /usr/local/Cellar/mariadb/10.4.6_1/include' /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql
                  + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && MAKEFLAGS= make clean && MAKEFLAGS= make
                  > rm -f main.o
                  > rm -f *~ core *.core
                  > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -c -pipe -stdlib=libc++ -O2 -std=gnu++11  -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -w -fPIC  -I. -I/usr/local/opt/openssl/include -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include -I/Users/simonplatten/Qt/5.14.2/clang_64/mkspecs/macx-clang -o main.o main.cpp
                  > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -stdlib=libc++ -headerpad_max_install_names  -arch x86_64 -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -Wl,-rpath,@executable_path/../Frameworks -o mysql main.o   -L/usr/local/Cellar/mariadb/10.4.6_1/lib   
                  > Undefined symbols for architecture x86_64:
                  >   "_mysql_get_client_version", referenced from:
                  >       _main in main.o
                  > ld: symbol(s) not found for architecture x86_64
                  > clang: error: linker command failed with exit code 1 (use -v to see invocation)
                  > make: *** [mysql] Error 1
                   => source failed verification.
                  Trying source 2 (type mysqlConfig) of library mysql ...
                  + /usr/local/bin/mysql_config --version
                  > 10.4.6
                  + /usr/local/bin/mysql_config --libs_r
                  > -L/usr/local/Cellar/mariadb/10.4.6_1/lib  -lmariadb -lz -liconv -lssl -lcrypto
                  + /usr/local/bin/mysql_config --include
                  > -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql/..
                  + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && /Users/simonplatten/Qt/5.14.2/clang_64/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" 'INCLUDEPATH += /usr/local/opt/openssl/include' 'QMAKE_USE += mysql' 'QMAKE_LIBS_MYSQL = -L/usr/local/Cellar/mariadb/10.4.6_1/lib -lmariadb -lz -liconv -lssl -lcrypto' 'QMAKE_INCDIR_MYSQL = /usr/local/Cellar/mariadb/10.4.6_1/include/mysql /usr/local/Cellar/mariadb/10.4.6_1/include' /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql
                  + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && MAKEFLAGS= make clean && MAKEFLAGS= make
                  > rm -f main.o
                  > rm -f *~ core *.core
                  > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -c -pipe -stdlib=libc++ -O2 -std=gnu++11  -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -w -fPIC  -I. -I/usr/local/opt/openssl/include -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include -I/Users/simonplatten/Qt/5.14.2/clang_64/mkspecs/macx-clang -o main.o main.cpp
                  > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -stdlib=libc++ -headerpad_max_install_names  -arch x86_64 -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -Wl,-rpath,@executable_path/../Frameworks -o mysql main.o   -L/usr/local/Cellar/mariadb/10.4.6_1/lib -lmariadb -lz -liconv -lssl -lcrypto   
                  > ld: library not found for -lssl
                  > clang: error: linker command failed with exit code 1 (use -v to see invocation)
                  > make: *** [mysql] Error 1
                   => source failed verification.
                  Trying source 3 (type mysqlConfig) of library mysql ...
                  + /usr/local/bin/mysql_config --version
                  > 10.4.6
                  + /usr/local/bin/mysql_config --libs
                  > -L/usr/local/Cellar/mariadb/10.4.6_1/lib  -lmariadb -lz -liconv -lssl -lcrypto
                  + /usr/local/bin/mysql_config --include
                  > -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql/..
                  + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && /Users/simonplatten/Qt/5.14.2/clang_64/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" 'INCLUDEPATH += /usr/local/opt/openssl/include' 'QMAKE_USE += mysql' 'QMAKE_LIBS_MYSQL = -L/usr/local/Cellar/mariadb/10.4.6_1/lib -lmariadb -lz -liconv -lssl -lcrypto' 'QMAKE_INCDIR_MYSQL = /usr/local/Cellar/mariadb/10.4.6_1/include/mysql /usr/local/Cellar/mariadb/10.4.6_1/include' /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql
                  + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && MAKEFLAGS= make clean && MAKEFLAGS= make
                  > rm -f main.o
                  > rm -f *~ core *.core
                  > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -c -pipe -stdlib=libc++ -O2 -std=gnu++11  -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -w -fPIC  -I. -I/usr/local/opt/openssl/include -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include -I/Users/simonplatten/Qt/5.14.2/clang_64/mkspecs/macx-clang -o main.o main.cpp
                  > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -stdlib=libc++ -headerpad_max_install_names  -arch x86_64 -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -Wl,-rpath,@executable_path/../Frameworks -o mysql main.o   -L/usr/local/Cellar/mariadb/10.4.6_1/lib -lmariadb -lz -liconv -lssl -lcrypto   
                  > ld: library not found for -lssl
                  > clang: error: linker command failed with exit code 1 (use -v to see invocation)
                  > make: *** [mysql] Error 1
                   => source failed verification.
                  Trying source 4 (type inline) of library mysql ...
                  mysql.h not found in [/usr/local/include] and global paths.
                    => source produced no result.
                  Trying source 5 (type inline) of library mysql ...
                    => source failed condition 'config.win32'.
                  Trying source 6 (type inline) of library mysql ...
                  mysql.h not found in [/usr/local/include] and global paths.
                    => source produced no result.
                  test config.sqldrivers.libraries.mysql FAILED
                  loaded result for library config.sqldrivers.libraries.oci
                  Trying source 0 (type inline) of library oci ...
                    => source failed condition 'config.win32'.
                  Trying source 1 (type inline) of library oci ...
                  oci.h not found in [] and global paths.
                    => source produced no result.
                  test config.sqldrivers.libraries.oci FAILED
                  loaded result for library config.sqldrivers.libraries.odbc
                  Trying source 0 (type inline) of library odbc ...
                    => source failed condition 'config.win32'.
                  Trying source 1 (type inline) of library odbc ...
                  sql.h not found in [] and global paths.
                  sqlext.h not found in [] and global paths.
                    => source produced no result.
                  Trying source 2 (type inline) of library odbc ...
                    => source failed condition '!config.win32 && !config.darwin'.
                  test config.sqldrivers.libraries.odbc FAILED
                  loaded result for library config.sqldrivers.libraries.psql
                  Trying source 0 (type pkgConfig) of library psql ...
                  pkg-config use disabled globally.
                    => source produced no result.
                  Trying source 1 (type psqlConfig) of library psql ...
                  pg_config not found.
                    => source produced no result.
                  Trying source 2 (type psqlEnv) of library psql ...
                    => source failed condition 'config.win32'.
                  Trying source 3 (type psqlEnv) of library psql ...
                  libpq-fe.h not found in [] and global paths.
                    => source produced no result.
                  test config.sqldrivers.libraries.psql FAILED
                  loaded result for library config.sqldrivers.libraries.sqlite2
                  Trying source 0 (type inline) of library sqlite2 ...
                  sqlite.h not found in [] and global paths.
                    => source produced no result.
                  test config.sqldrivers.libraries.sqlite2 FAILED
                  loaded result for library config.sqldrivers.libraries.tds
                  Trying source 0 (type sybaseEnv) of library tds ...
                    => source failed condition 'config.win32'.
                  Trying source 1 (type sybaseEnv) of library tds ...
                  + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/tds && /Users/simonplatten/Qt/5.14.2/clang_64/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" 'INCLUDEPATH += /usr/local/opt/openssl/include' 'QMAKE_USE += tds' 'QMAKE_LIBS_TDS = -lsybdb' /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/tds
                  + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/tds && MAKEFLAGS= make
                  > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -c -pipe -stdlib=libc++ -O2 -std=gnu++11  -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -w -fPIC  -I. -I/usr/local/opt/openssl/include -I/Users/simonplatten/Qt/5.14.2/clang_64/mkspecs/macx-clang -o main.o main.cpp
                  > main.cpp:2:10: fatal error: 'sybfront.h' file not found
                  > #include <sybfront.h>
                  >          ^~~~~~~~~~~~
                  > 1 error generated.
                  > make: *** [main.o] Error 1
                   => source failed verification.
                  test config.sqldrivers.libraries.tds FAILED
                  

                  Kind Regards,
                  Sy

                  jsulmJ 1 Reply Last reply
                  0
                  • SPlattenS SPlatten

                    I'v been through the steps again:

                    cd $QTDIR/Src/qtbase/src/plugins/sqldrivers 
                    $QTDIRBIN/qmake -- MYSQL_PREFIX=/usr/local
                    

                    The output is the same:

                    Running configuration tests... 
                    Done running configuration tests.
                    
                    Configure summary:
                    
                    Qt Sql Drivers:
                      DB2 (IBM) .............................. no
                      InterBase .............................. no
                      MySql .................................. no
                      OCI (Oracle) ........................... no
                      ODBC ................................... no
                      PostgreSQL ............................. no
                      SQLite2 ................................ no
                      SQLite ................................. yes
                        Using system provided SQLite ......... no
                      TDS (Sybase) ........................... no
                    
                    Qt is now configured for building. Just run 'make'.
                    Once everything is built, you must run 'make install'.
                    Qt will be installed into '/Users/simonplatten/Qt/5.14.2/clang_64'.
                    
                    Prior to reconfiguration, make sure you remove any leftovers from
                    the previous build.
                    

                    Again it looks like its set-up to build SQLite and not MySQL. I then run make and the result is:

                    cd sqlite/ && ( test -e Makefile || /Users/simonplatten/Qt/5.14.2/clang_64/bin/qmake -o Makefile /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/sqlite/sqlite.pro ) && /Applications/Xcode.app/Contents/Developer/usr/bin/make -f Makefile 
                    make[1]: Nothing to be done for `first'.
                    

                    @jsulm , I tried your instruction:

                    install: libfreetype-dev: No such file or directory
                    

                    'config.log' is quite verbose:

                    Command line: MYSQL_PREFIX=/usr/local
                    Global lib dirs: [] [/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/usr/lib]
                    Global inc dirs: [/usr/local/opt/openssl/include] [/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1 /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/11.0.3/include /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/usr/include /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include]
                    loaded result for library config.sqldrivers.libraries.db2
                    Trying source 0 (type inline) of library db2 ...
                      => source failed condition 'config.win32'.
                    Trying source 1 (type inline) of library db2 ...
                    sqlcli.h not found in [] and global paths.
                    sqlcli1.h not found in [] and global paths.
                      => source produced no result.
                    test config.sqldrivers.libraries.db2 FAILED
                    loaded result for library config.sqldrivers.libraries.ibase
                    Trying source 0 (type inline) of library ibase ...
                      => source failed condition 'config.win32'.
                    Trying source 1 (type inline) of library ibase ...
                    ibase.h not found in [] and global paths.
                      => source produced no result.
                    test config.sqldrivers.libraries.ibase FAILED
                    loaded result for library config.sqldrivers.libraries.mysql
                    Trying source 0 (type mysqlConfig) of library mysql ...
                    + /usr/local/bin/mysql_config --version
                    > 10.4.6
                    + /usr/local/bin/mysql_config --libs_r
                    > -L/usr/local/Cellar/mariadb/10.4.6_1/lib  -lmariadb -lz -liconv -lssl -lcrypto
                    + /usr/local/bin/mysql_config --include
                    > -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql/..
                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && /Users/simonplatten/Qt/5.14.2/clang_64/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" 'INCLUDEPATH += /usr/local/opt/openssl/include' 'QMAKE_USE += mysql' 'QMAKE_LIBS_MYSQL = -L/usr/local/Cellar/mariadb/10.4.6_1/lib' 'QMAKE_INCDIR_MYSQL = /usr/local/Cellar/mariadb/10.4.6_1/include/mysql /usr/local/Cellar/mariadb/10.4.6_1/include' /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql
                    > Info: creating stash file /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/.qmake.stash
                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && MAKEFLAGS= make
                    > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -c -pipe -stdlib=libc++ -O2 -std=gnu++11  -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -w -fPIC  -I. -I/usr/local/opt/openssl/include -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include -I/Users/simonplatten/Qt/5.14.2/clang_64/mkspecs/macx-clang -o main.o main.cpp
                    > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -stdlib=libc++ -headerpad_max_install_names  -arch x86_64 -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -Wl,-rpath,@executable_path/../Frameworks -o mysql main.o   -L/usr/local/Cellar/mariadb/10.4.6_1/lib   
                    > Undefined symbols for architecture x86_64:
                    >   "_mysql_get_client_version", referenced from:
                    >       _main in main.o
                    > ld: symbol(s) not found for architecture x86_64
                    > clang: error: linker command failed with exit code 1 (use -v to see invocation)
                    > make: *** [mysql] Error 1
                     => source failed verification.
                    Trying source 1 (type mysqlConfig) of library mysql ...
                    + /usr/local/bin/mysql_config --version
                    > 10.4.6
                    + /usr/local/bin/mysql_config --libs
                    > -L/usr/local/Cellar/mariadb/10.4.6_1/lib  -lmariadb -lz -liconv -lssl -lcrypto
                    + /usr/local/bin/mysql_config --include
                    > -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql/..
                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && /Users/simonplatten/Qt/5.14.2/clang_64/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" 'INCLUDEPATH += /usr/local/opt/openssl/include' 'QMAKE_USE += mysql' 'QMAKE_LIBS_MYSQL = -L/usr/local/Cellar/mariadb/10.4.6_1/lib' 'QMAKE_INCDIR_MYSQL = /usr/local/Cellar/mariadb/10.4.6_1/include/mysql /usr/local/Cellar/mariadb/10.4.6_1/include' /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql
                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && MAKEFLAGS= make clean && MAKEFLAGS= make
                    > rm -f main.o
                    > rm -f *~ core *.core
                    > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -c -pipe -stdlib=libc++ -O2 -std=gnu++11  -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -w -fPIC  -I. -I/usr/local/opt/openssl/include -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include -I/Users/simonplatten/Qt/5.14.2/clang_64/mkspecs/macx-clang -o main.o main.cpp
                    > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -stdlib=libc++ -headerpad_max_install_names  -arch x86_64 -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -Wl,-rpath,@executable_path/../Frameworks -o mysql main.o   -L/usr/local/Cellar/mariadb/10.4.6_1/lib   
                    > Undefined symbols for architecture x86_64:
                    >   "_mysql_get_client_version", referenced from:
                    >       _main in main.o
                    > ld: symbol(s) not found for architecture x86_64
                    > clang: error: linker command failed with exit code 1 (use -v to see invocation)
                    > make: *** [mysql] Error 1
                     => source failed verification.
                    Trying source 2 (type mysqlConfig) of library mysql ...
                    + /usr/local/bin/mysql_config --version
                    > 10.4.6
                    + /usr/local/bin/mysql_config --libs_r
                    > -L/usr/local/Cellar/mariadb/10.4.6_1/lib  -lmariadb -lz -liconv -lssl -lcrypto
                    + /usr/local/bin/mysql_config --include
                    > -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql/..
                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && /Users/simonplatten/Qt/5.14.2/clang_64/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" 'INCLUDEPATH += /usr/local/opt/openssl/include' 'QMAKE_USE += mysql' 'QMAKE_LIBS_MYSQL = -L/usr/local/Cellar/mariadb/10.4.6_1/lib -lmariadb -lz -liconv -lssl -lcrypto' 'QMAKE_INCDIR_MYSQL = /usr/local/Cellar/mariadb/10.4.6_1/include/mysql /usr/local/Cellar/mariadb/10.4.6_1/include' /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql
                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && MAKEFLAGS= make clean && MAKEFLAGS= make
                    > rm -f main.o
                    > rm -f *~ core *.core
                    > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -c -pipe -stdlib=libc++ -O2 -std=gnu++11  -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -w -fPIC  -I. -I/usr/local/opt/openssl/include -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include -I/Users/simonplatten/Qt/5.14.2/clang_64/mkspecs/macx-clang -o main.o main.cpp
                    > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -stdlib=libc++ -headerpad_max_install_names  -arch x86_64 -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -Wl,-rpath,@executable_path/../Frameworks -o mysql main.o   -L/usr/local/Cellar/mariadb/10.4.6_1/lib -lmariadb -lz -liconv -lssl -lcrypto   
                    > ld: library not found for -lssl
                    > clang: error: linker command failed with exit code 1 (use -v to see invocation)
                    > make: *** [mysql] Error 1
                     => source failed verification.
                    Trying source 3 (type mysqlConfig) of library mysql ...
                    + /usr/local/bin/mysql_config --version
                    > 10.4.6
                    + /usr/local/bin/mysql_config --libs
                    > -L/usr/local/Cellar/mariadb/10.4.6_1/lib  -lmariadb -lz -liconv -lssl -lcrypto
                    + /usr/local/bin/mysql_config --include
                    > -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql/..
                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && /Users/simonplatten/Qt/5.14.2/clang_64/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" 'INCLUDEPATH += /usr/local/opt/openssl/include' 'QMAKE_USE += mysql' 'QMAKE_LIBS_MYSQL = -L/usr/local/Cellar/mariadb/10.4.6_1/lib -lmariadb -lz -liconv -lssl -lcrypto' 'QMAKE_INCDIR_MYSQL = /usr/local/Cellar/mariadb/10.4.6_1/include/mysql /usr/local/Cellar/mariadb/10.4.6_1/include' /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql
                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && MAKEFLAGS= make clean && MAKEFLAGS= make
                    > rm -f main.o
                    > rm -f *~ core *.core
                    > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -c -pipe -stdlib=libc++ -O2 -std=gnu++11  -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -w -fPIC  -I. -I/usr/local/opt/openssl/include -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include -I/Users/simonplatten/Qt/5.14.2/clang_64/mkspecs/macx-clang -o main.o main.cpp
                    > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -stdlib=libc++ -headerpad_max_install_names  -arch x86_64 -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -Wl,-rpath,@executable_path/../Frameworks -o mysql main.o   -L/usr/local/Cellar/mariadb/10.4.6_1/lib -lmariadb -lz -liconv -lssl -lcrypto   
                    > ld: library not found for -lssl
                    > clang: error: linker command failed with exit code 1 (use -v to see invocation)
                    > make: *** [mysql] Error 1
                     => source failed verification.
                    Trying source 4 (type inline) of library mysql ...
                    mysql.h not found in [/usr/local/include] and global paths.
                      => source produced no result.
                    Trying source 5 (type inline) of library mysql ...
                      => source failed condition 'config.win32'.
                    Trying source 6 (type inline) of library mysql ...
                    mysql.h not found in [/usr/local/include] and global paths.
                      => source produced no result.
                    test config.sqldrivers.libraries.mysql FAILED
                    loaded result for library config.sqldrivers.libraries.oci
                    Trying source 0 (type inline) of library oci ...
                      => source failed condition 'config.win32'.
                    Trying source 1 (type inline) of library oci ...
                    oci.h not found in [] and global paths.
                      => source produced no result.
                    test config.sqldrivers.libraries.oci FAILED
                    loaded result for library config.sqldrivers.libraries.odbc
                    Trying source 0 (type inline) of library odbc ...
                      => source failed condition 'config.win32'.
                    Trying source 1 (type inline) of library odbc ...
                    sql.h not found in [] and global paths.
                    sqlext.h not found in [] and global paths.
                      => source produced no result.
                    Trying source 2 (type inline) of library odbc ...
                      => source failed condition '!config.win32 && !config.darwin'.
                    test config.sqldrivers.libraries.odbc FAILED
                    loaded result for library config.sqldrivers.libraries.psql
                    Trying source 0 (type pkgConfig) of library psql ...
                    pkg-config use disabled globally.
                      => source produced no result.
                    Trying source 1 (type psqlConfig) of library psql ...
                    pg_config not found.
                      => source produced no result.
                    Trying source 2 (type psqlEnv) of library psql ...
                      => source failed condition 'config.win32'.
                    Trying source 3 (type psqlEnv) of library psql ...
                    libpq-fe.h not found in [] and global paths.
                      => source produced no result.
                    test config.sqldrivers.libraries.psql FAILED
                    loaded result for library config.sqldrivers.libraries.sqlite2
                    Trying source 0 (type inline) of library sqlite2 ...
                    sqlite.h not found in [] and global paths.
                      => source produced no result.
                    test config.sqldrivers.libraries.sqlite2 FAILED
                    loaded result for library config.sqldrivers.libraries.tds
                    Trying source 0 (type sybaseEnv) of library tds ...
                      => source failed condition 'config.win32'.
                    Trying source 1 (type sybaseEnv) of library tds ...
                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/tds && /Users/simonplatten/Qt/5.14.2/clang_64/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" 'INCLUDEPATH += /usr/local/opt/openssl/include' 'QMAKE_USE += tds' 'QMAKE_LIBS_TDS = -lsybdb' /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/tds
                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/tds && MAKEFLAGS= make
                    > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -c -pipe -stdlib=libc++ -O2 -std=gnu++11  -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -w -fPIC  -I. -I/usr/local/opt/openssl/include -I/Users/simonplatten/Qt/5.14.2/clang_64/mkspecs/macx-clang -o main.o main.cpp
                    > main.cpp:2:10: fatal error: 'sybfront.h' file not found
                    > #include <sybfront.h>
                    >          ^~~~~~~~~~~~
                    > 1 error generated.
                    > make: *** [main.o] Error 1
                     => source failed verification.
                    test config.sqldrivers.libraries.tds FAILED
                    
                    jsulmJ Offline
                    jsulmJ Offline
                    jsulm
                    Lifetime Qt Champion
                    wrote on last edited by
                    #30

                    @SPlatten said in Set-up MariaDB library file location programmatically?:

                    install: libfreetype-dev: No such file or directory

                    Name on your system can be different, simply search for freetype.

                    Undefined symbols for architecture x86_64:
                    >   "_mysql_get_client_version", referenced from:
                    >       _main in main.o
                    > ld: symbol(s) not found for architecture x86_64
                    

                    /usr/local/Cellar/mariadb/10.4.6_1/lib/* - is this a x86_64 binary?

                    https://forum.qt.io/topic/113070/qt-code-of-conduct

                    1 Reply Last reply
                    1
                    • SPlattenS Offline
                      SPlattenS Offline
                      SPlatten
                      wrote on last edited by
                      #31

                      @jsulm , I searched for freetype on my system:

                      find / -name freetype 
                      

                      and found nothing.

                      The contents of /usr/local/Cellar/mariadb/10.4.6_1/lib:

                      total 1152
                      -rw-r--r--   1 simonplatten  staff  230704 28 Sep  2019 libmariadb.3.dylib
                      lrwxr-xr-x   1 simonplatten  staff      18 17 Jun  2019 libmariadb.dylib -> libmariadb.3.dylib
                      -rw-r--r--   1 simonplatten  staff  336264 17 Jun  2019 libmariadbclient.a
                      lrwxr-xr-x   1 simonplatten  staff      18 17 Jun  2019 libmysqlclient.a -> libmariadbclient.a
                      lrwxr-xr-x   1 simonplatten  staff      18 17 Jun  2019 libmysqlclient.dylib -> libmariadb.3.dylib
                      lrwxr-xr-x   1 simonplatten  staff      18 17 Jun  2019 libmysqlclient_r.a -> libmariadbclient.a
                      lrwxr-xr-x   1 simonplatten  staff      18 17 Jun  2019 libmysqlclient_r.dylib -> libmariadb.3.dylib
                      -r--r--r--   1 simonplatten  staff   12400 17 Jun  2019 libmysqlservices.a
                      drwxr-xr-x   3 simonplatten  staff      96 28 Sep  2019 pkgconfig
                      drwxr-xr-x  49 simonplatten  staff    1568 17 Jun  2019 plugin
                      

                      Kind Regards,
                      Sy

                      jsulmJ 1 Reply Last reply
                      0
                      • SPlattenS SPlatten

                        @jsulm , I searched for freetype on my system:

                        find / -name freetype 
                        

                        and found nothing.

                        The contents of /usr/local/Cellar/mariadb/10.4.6_1/lib:

                        total 1152
                        -rw-r--r--   1 simonplatten  staff  230704 28 Sep  2019 libmariadb.3.dylib
                        lrwxr-xr-x   1 simonplatten  staff      18 17 Jun  2019 libmariadb.dylib -> libmariadb.3.dylib
                        -rw-r--r--   1 simonplatten  staff  336264 17 Jun  2019 libmariadbclient.a
                        lrwxr-xr-x   1 simonplatten  staff      18 17 Jun  2019 libmysqlclient.a -> libmariadbclient.a
                        lrwxr-xr-x   1 simonplatten  staff      18 17 Jun  2019 libmysqlclient.dylib -> libmariadb.3.dylib
                        lrwxr-xr-x   1 simonplatten  staff      18 17 Jun  2019 libmysqlclient_r.a -> libmariadbclient.a
                        lrwxr-xr-x   1 simonplatten  staff      18 17 Jun  2019 libmysqlclient_r.dylib -> libmariadb.3.dylib
                        -r--r--r--   1 simonplatten  staff   12400 17 Jun  2019 libmysqlservices.a
                        drwxr-xr-x   3 simonplatten  staff      96 28 Sep  2019 pkgconfig
                        drwxr-xr-x  49 simonplatten  staff    1568 17 Jun  2019 plugin
                        
                        jsulmJ Offline
                        jsulmJ Offline
                        jsulm
                        Lifetime Qt Champion
                        wrote on last edited by
                        #32

                        @SPlatten said in Set-up MariaDB library file location programmatically?:

                        find / -name freetype

                        I don't mean searching in the filesystem. I mean searching in the package manager.

                        "The contents of /usr/local/Cellar/mariadb/10.4.6_1/lib:" - this does not answer the question.
                        Please do:

                        file /usr/local/Cellar/mariadb/10.4.6_1/lib/libmariadb.3.dylib
                        

                        And post the output.

                        Also it can be that MariaDB can't be used with Qt as the error message says that "_mysql_get_client_version" symbol is not defined, but I'm not sure.

                        https://forum.qt.io/topic/113070/qt-code-of-conduct

                        1 Reply Last reply
                        1
                        • SPlattenS Offline
                          SPlattenS Offline
                          SPlatten
                          wrote on last edited by SPlatten
                          #33

                          @jsulm said in Set-up MariaDB library file location programmatically?:

                          file /usr/local/Cellar/mariadb/10.4.6_1/lib/libmariadb.3.dylib

                          /usr/local/Cellar/mariadb/10.4.6_1/lib/libmariadb.3.dylib: Mach-O 64-bit dynamically linked shared library x86_64
                          

                          I'm sure I've been through this process a few years ago using MariaDB...I just wish I've made some good notes...its a mystery to me MariaDB seems to be exactly the same as MySQL in everyday with the exception of the outside world knowing it as MariaDB, internally the files are still called mySQL, which I'm unsure quite how the author got away with this as Oracle are normally very hot on licensing.

                          Kind Regards,
                          Sy

                          1 Reply Last reply
                          0
                          • SPlattenS Offline
                            SPlattenS Offline
                            SPlatten
                            wrote on last edited by
                            #34

                            Found this post:

                            https://forum.qt.io/topic/90065/how-to-create-the-plugin-of-mariadb-for-qt5/19

                            And have adapted the qmake command to match my system:

                            qmake -- MYSQL_INCDIR=/usr/local/Cellar/mariadb/10.4.6_1/include/mysql "MYSQL_LIBDIR=/usr/local/Cellar/mariadb/10.4.6_1/lib" MYSQL_LIBS="-llibmariadb"
                            

                            I'm not sure if libmariadb is correct, the paths are correct.

                            Kind Regards,
                            Sy

                            jsulmJ 1 Reply Last reply
                            0
                            • SPlattenS SPlatten

                              Found this post:

                              https://forum.qt.io/topic/90065/how-to-create-the-plugin-of-mariadb-for-qt5/19

                              And have adapted the qmake command to match my system:

                              qmake -- MYSQL_INCDIR=/usr/local/Cellar/mariadb/10.4.6_1/include/mysql "MYSQL_LIBDIR=/usr/local/Cellar/mariadb/10.4.6_1/lib" MYSQL_LIBS="-llibmariadb"
                              

                              I'm not sure if libmariadb is correct, the paths are correct.

                              jsulmJ Offline
                              jsulmJ Offline
                              jsulm
                              Lifetime Qt Champion
                              wrote on last edited by
                              #35

                              @SPlatten said in Set-up MariaDB library file location programmatically?:

                              MYSQL_LIBS="-llibmariadb"

                              This should be

                              MYSQL_LIBS="-lmariadb"
                              

                              https://forum.qt.io/topic/113070/qt-code-of-conduct

                              1 Reply Last reply
                              2
                              • SPlattenS Offline
                                SPlattenS Offline
                                SPlatten
                                wrote on last edited by
                                #36

                                @jsulm, Thank you, it still looks like its only set-up for SQLite:

                                simonplatten@Simons-iMac sqldrivers % $QTDIRBIN/qmake -- MYSQL_INCDIR=/usr/local/Cellar/mariadb/10.4.6_1/include/mysql "MYSQL_LIBDIR=/usr/local/Cellar/mariadb/10.4.6_1/lib" MYSQL_LIBS="-lmariadb"
                                
                                Running configuration tests...
                                Done running configuration tests.
                                
                                Configure summary:
                                
                                Qt Sql Drivers:
                                  DB2 (IBM) .............................. no
                                  InterBase .............................. no
                                  MySql .................................. no
                                  OCI (Oracle) ........................... no
                                  ODBC ................................... no
                                  PostgreSQL ............................. no
                                  SQLite2 ................................ no
                                  SQLite ................................. yes
                                    Using system provided SQLite ......... no
                                  TDS (Sybase) ........................... no
                                
                                Qt is now configured for building. Just run 'make'.
                                Once everything is built, you must run 'make install'.
                                Qt will be installed into '/Users/simonplatten/Qt/5.14.2/clang_64'.
                                
                                Prior to reconfiguration, make sure you remove any leftovers from
                                the previous build.
                                

                                Kind Regards,
                                Sy

                                jsulmJ 1 Reply Last reply
                                0
                                • SPlattenS SPlatten

                                  @jsulm, Thank you, it still looks like its only set-up for SQLite:

                                  simonplatten@Simons-iMac sqldrivers % $QTDIRBIN/qmake -- MYSQL_INCDIR=/usr/local/Cellar/mariadb/10.4.6_1/include/mysql "MYSQL_LIBDIR=/usr/local/Cellar/mariadb/10.4.6_1/lib" MYSQL_LIBS="-lmariadb"
                                  
                                  Running configuration tests...
                                  Done running configuration tests.
                                  
                                  Configure summary:
                                  
                                  Qt Sql Drivers:
                                    DB2 (IBM) .............................. no
                                    InterBase .............................. no
                                    MySql .................................. no
                                    OCI (Oracle) ........................... no
                                    ODBC ................................... no
                                    PostgreSQL ............................. no
                                    SQLite2 ................................ no
                                    SQLite ................................. yes
                                      Using system provided SQLite ......... no
                                    TDS (Sybase) ........................... no
                                  
                                  Qt is now configured for building. Just run 'make'.
                                  Once everything is built, you must run 'make install'.
                                  Qt will be installed into '/Users/simonplatten/Qt/5.14.2/clang_64'.
                                  
                                  Prior to reconfiguration, make sure you remove any leftovers from
                                  the previous build.
                                  
                                  jsulmJ Offline
                                  jsulmJ Offline
                                  jsulm
                                  Lifetime Qt Champion
                                  wrote on last edited by
                                  #37

                                  @SPlatten Is there configure.log file? If so check it.

                                  https://forum.qt.io/topic/113070/qt-code-of-conduct

                                  1 Reply Last reply
                                  0
                                  • SPlattenS Offline
                                    SPlattenS Offline
                                    SPlatten
                                    wrote on last edited by
                                    #38

                                    As before I don't see a configure.log, but there is a config.log:

                                    simonplatten@Simons-iMac sqldrivers % cat config.log
                                    Command line: MYSQL_INCDIR=/usr/local/Cellar/mariadb/10.4.6_1/include/mysql MYSQL_LIBDIR=/usr/local/Cellar/mariadb/10.4.6_1/lib MYSQL_LIBS=-lmariadb
                                    Global lib dirs: [] [/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/usr/lib]
                                    Global inc dirs: [/usr/local/opt/openssl/include] [/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1 /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/11.0.3/include /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/usr/include /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include]
                                    loaded result for library config.sqldrivers.libraries.db2
                                    Trying source 0 (type inline) of library db2 ...
                                      => source failed condition 'config.win32'.
                                    Trying source 1 (type inline) of library db2 ...
                                    sqlcli.h not found in [] and global paths.
                                    sqlcli1.h not found in [] and global paths.
                                      => source produced no result.
                                    test config.sqldrivers.libraries.db2 FAILED
                                    loaded result for library config.sqldrivers.libraries.ibase
                                    Trying source 0 (type inline) of library ibase ...
                                      => source failed condition 'config.win32'.
                                    Trying source 1 (type inline) of library ibase ...
                                    ibase.h not found in [] and global paths.
                                      => source produced no result.
                                    test config.sqldrivers.libraries.ibase FAILED
                                    loaded result for library config.sqldrivers.libraries.mysql
                                    Trying source 0 (type mysqlConfig) of library mysql ...
                                    + /usr/local/bin/mysql_config --version
                                    > 10.4.6
                                    + /usr/local/bin/mysql_config --libs_r
                                    > -L/usr/local/Cellar/mariadb/10.4.6_1/lib  -lmariadb -lz -liconv -lssl -lcrypto
                                    + /usr/local/bin/mysql_config --include
                                    > -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql/..
                                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && /Users/simonplatten/Qt/5.14.2/clang_64/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" 'INCLUDEPATH += /usr/local/opt/openssl/include' 'QMAKE_USE += mysql' 'QMAKE_LIBS_MYSQL = -L/usr/local/Cellar/mariadb/10.4.6_1/lib' 'QMAKE_INCDIR_MYSQL = /usr/local/Cellar/mariadb/10.4.6_1/include/mysql /usr/local/Cellar/mariadb/10.4.6_1/include' /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql
                                    > Info: creating stash file /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/.qmake.stash
                                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && MAKEFLAGS= make
                                    > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -c -pipe -stdlib=libc++ -O2 -std=gnu++11  -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -w -fPIC  -I. -I/usr/local/opt/openssl/include -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include -I/Users/simonplatten/Qt/5.14.2/clang_64/mkspecs/macx-clang -o main.o main.cpp
                                    > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -stdlib=libc++ -headerpad_max_install_names  -arch x86_64 -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -Wl,-rpath,@executable_path/../Frameworks -o mysql main.o   -L/usr/local/Cellar/mariadb/10.4.6_1/lib   
                                    > Undefined symbols for architecture x86_64:
                                    >   "_mysql_get_client_version", referenced from:
                                    >       _main in main.o
                                    > ld: symbol(s) not found for architecture x86_64
                                    > clang: error: linker command failed with exit code 1 (use -v to see invocation)
                                    > make: *** [mysql] Error 1
                                     => source failed verification.
                                    Trying source 1 (type mysqlConfig) of library mysql ...
                                    + /usr/local/bin/mysql_config --version
                                    > 10.4.6
                                    + /usr/local/bin/mysql_config --libs
                                    > -L/usr/local/Cellar/mariadb/10.4.6_1/lib  -lmariadb -lz -liconv -lssl -lcrypto
                                    + /usr/local/bin/mysql_config --include
                                    > -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql/..
                                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && /Users/simonplatten/Qt/5.14.2/clang_64/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" 'INCLUDEPATH += /usr/local/opt/openssl/include' 'QMAKE_USE += mysql' 'QMAKE_LIBS_MYSQL = -L/usr/local/Cellar/mariadb/10.4.6_1/lib' 'QMAKE_INCDIR_MYSQL = /usr/local/Cellar/mariadb/10.4.6_1/include/mysql /usr/local/Cellar/mariadb/10.4.6_1/include' /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql
                                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && MAKEFLAGS= make clean && MAKEFLAGS= make
                                    > rm -f main.o
                                    > rm -f *~ core *.core
                                    > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -c -pipe -stdlib=libc++ -O2 -std=gnu++11  -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -w -fPIC  -I. -I/usr/local/opt/openssl/include -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include -I/Users/simonplatten/Qt/5.14.2/clang_64/mkspecs/macx-clang -o main.o main.cpp
                                    > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -stdlib=libc++ -headerpad_max_install_names  -arch x86_64 -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -Wl,-rpath,@executable_path/../Frameworks -o mysql main.o   -L/usr/local/Cellar/mariadb/10.4.6_1/lib   
                                    > Undefined symbols for architecture x86_64:
                                    >   "_mysql_get_client_version", referenced from:
                                    >       _main in main.o
                                    > ld: symbol(s) not found for architecture x86_64
                                    > clang: error: linker command failed with exit code 1 (use -v to see invocation)
                                    > make: *** [mysql] Error 1
                                     => source failed verification.
                                    Trying source 2 (type mysqlConfig) of library mysql ...
                                    + /usr/local/bin/mysql_config --version
                                    > 10.4.6
                                    + /usr/local/bin/mysql_config --libs_r
                                    > -L/usr/local/Cellar/mariadb/10.4.6_1/lib  -lmariadb -lz -liconv -lssl -lcrypto
                                    + /usr/local/bin/mysql_config --include
                                    > -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql/..
                                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && /Users/simonplatten/Qt/5.14.2/clang_64/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" 'INCLUDEPATH += /usr/local/opt/openssl/include' 'QMAKE_USE += mysql' 'QMAKE_LIBS_MYSQL = -L/usr/local/Cellar/mariadb/10.4.6_1/lib -lmariadb -lz -liconv -lssl -lcrypto' 'QMAKE_INCDIR_MYSQL = /usr/local/Cellar/mariadb/10.4.6_1/include/mysql /usr/local/Cellar/mariadb/10.4.6_1/include' /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql
                                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && MAKEFLAGS= make clean && MAKEFLAGS= make
                                    > rm -f main.o
                                    > rm -f *~ core *.core
                                    > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -c -pipe -stdlib=libc++ -O2 -std=gnu++11  -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -w -fPIC  -I. -I/usr/local/opt/openssl/include -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include -I/Users/simonplatten/Qt/5.14.2/clang_64/mkspecs/macx-clang -o main.o main.cpp
                                    > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -stdlib=libc++ -headerpad_max_install_names  -arch x86_64 -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -Wl,-rpath,@executable_path/../Frameworks -o mysql main.o   -L/usr/local/Cellar/mariadb/10.4.6_1/lib -lmariadb -lz -liconv -lssl -lcrypto   
                                    > ld: library not found for -lssl
                                    > clang: error: linker command failed with exit code 1 (use -v to see invocation)
                                    > make: *** [mysql] Error 1
                                     => source failed verification.
                                    Trying source 3 (type mysqlConfig) of library mysql ...
                                    + /usr/local/bin/mysql_config --version
                                    > 10.4.6
                                    + /usr/local/bin/mysql_config --libs
                                    > -L/usr/local/Cellar/mariadb/10.4.6_1/lib  -lmariadb -lz -liconv -lssl -lcrypto
                                    + /usr/local/bin/mysql_config --include
                                    > -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql/..
                                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && /Users/simonplatten/Qt/5.14.2/clang_64/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" 'INCLUDEPATH += /usr/local/opt/openssl/include' 'QMAKE_USE += mysql' 'QMAKE_LIBS_MYSQL = -L/usr/local/Cellar/mariadb/10.4.6_1/lib -lmariadb -lz -liconv -lssl -lcrypto' 'QMAKE_INCDIR_MYSQL = /usr/local/Cellar/mariadb/10.4.6_1/include/mysql /usr/local/Cellar/mariadb/10.4.6_1/include' /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql
                                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/mysql && MAKEFLAGS= make clean && MAKEFLAGS= make
                                    > rm -f main.o
                                    > rm -f *~ core *.core
                                    > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -c -pipe -stdlib=libc++ -O2 -std=gnu++11  -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -w -fPIC  -I. -I/usr/local/opt/openssl/include -I/usr/local/Cellar/mariadb/10.4.6_1/include/mysql -I/usr/local/Cellar/mariadb/10.4.6_1/include -I/Users/simonplatten/Qt/5.14.2/clang_64/mkspecs/macx-clang -o main.o main.cpp
                                    > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -stdlib=libc++ -headerpad_max_install_names  -arch x86_64 -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -Wl,-rpath,@executable_path/../Frameworks -o mysql main.o   -L/usr/local/Cellar/mariadb/10.4.6_1/lib -lmariadb -lz -liconv -lssl -lcrypto   
                                    > ld: library not found for -lssl
                                    > clang: error: linker command failed with exit code 1 (use -v to see invocation)
                                    > make: *** [mysql] Error 1
                                     => source failed verification.
                                    Trying source 4 (type inline) of library mysql ...
                                    mysql.h not found in [/usr/local/include] and global paths.
                                      => source produced no result.
                                    Trying source 5 (type inline) of library mysql ...
                                      => source failed condition 'config.win32'.
                                    Trying source 6 (type inline) of library mysql ...
                                    mysql.h not found in [/usr/local/include] and global paths.
                                      => source produced no result.
                                    test config.sqldrivers.libraries.mysql FAILED
                                    loaded result for library config.sqldrivers.libraries.oci
                                    Trying source 0 (type inline) of library oci ...
                                      => source failed condition 'config.win32'.
                                    Trying source 1 (type inline) of library oci ...
                                    oci.h not found in [] and global paths.
                                      => source produced no result.
                                    test config.sqldrivers.libraries.oci FAILED
                                    loaded result for library config.sqldrivers.libraries.odbc
                                    Trying source 0 (type inline) of library odbc ...
                                      => source failed condition 'config.win32'.
                                    Trying source 1 (type inline) of library odbc ...
                                    sql.h not found in [] and global paths.
                                    sqlext.h not found in [] and global paths.
                                      => source produced no result.
                                    Trying source 2 (type inline) of library odbc ...
                                      => source failed condition '!config.win32 && !config.darwin'.
                                    test config.sqldrivers.libraries.odbc FAILED
                                    loaded result for library config.sqldrivers.libraries.psql
                                    Trying source 0 (type pkgConfig) of library psql ...
                                    pkg-config use disabled globally.
                                      => source produced no result.
                                    Trying source 1 (type psqlConfig) of library psql ...
                                    pg_config not found.
                                      => source produced no result.
                                    Trying source 2 (type psqlEnv) of library psql ...
                                      => source failed condition 'config.win32'.
                                    Trying source 3 (type psqlEnv) of library psql ...
                                    libpq-fe.h not found in [] and global paths.
                                      => source produced no result.
                                    test config.sqldrivers.libraries.psql FAILED
                                    loaded result for library config.sqldrivers.libraries.sqlite2
                                    Trying source 0 (type inline) of library sqlite2 ...
                                    sqlite.h not found in [] and global paths.
                                      => source produced no result.
                                    test config.sqldrivers.libraries.sqlite2 FAILED
                                    loaded result for library config.sqldrivers.libraries.tds
                                    Trying source 0 (type sybaseEnv) of library tds ...
                                      => source failed condition 'config.win32'.
                                    Trying source 1 (type sybaseEnv) of library tds ...
                                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/tds && /Users/simonplatten/Qt/5.14.2/clang_64/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" 'INCLUDEPATH += /usr/local/opt/openssl/include' 'QMAKE_USE += tds' 'QMAKE_LIBS_TDS = -lsybdb' /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/tds
                                    + cd /Users/simonplatten/Qt/5.14.2/Src/qtbase/src/plugins/sqldrivers/config.tests/tds && MAKEFLAGS= make
                                    > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -c -pipe -stdlib=libc++ -O2 -std=gnu++11  -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -w -fPIC  -I. -I/usr/local/opt/openssl/include -I/Users/simonplatten/Qt/5.14.2/clang_64/mkspecs/macx-clang -o main.o main.cpp
                                    > main.cpp:2:10: fatal error: 'sybfront.h' file not found
                                    > #include <sybfront.h>
                                    >          ^~~~~~~~~~~~
                                    > 1 error generated.
                                    > make: *** [main.o] Error 1
                                     => source failed verification.
                                    test config.sqldrivers.libraries.tds FAILED
                                    

                                    Kind Regards,
                                    Sy

                                    1 Reply Last reply
                                    0
                                    • hskoglundH Online
                                      hskoglundH Online
                                      hskoglund
                                      wrote on last edited by
                                      #39

                                      Hi, it seems you're missing openssl, try:
                                      brew install openssl

                                      1 Reply Last reply
                                      1
                                      • SPlattenS Offline
                                        SPlattenS Offline
                                        SPlatten
                                        wrote on last edited by
                                        #40
                                        brew install openssl
                                        Updating Homebrew...
                                        ==> Auto-updated Homebrew!
                                        Updated 1 tap (homebrew/core).
                                        ==> New Formulae
                                        k9s
                                        ==> Updated Formulae
                                        agedu              broot              elvish             gmt                kustomize          pgrouting          serve              swiftgen           vulkan-headers
                                        artifactory        catch2             erlang             grap               libmicrohttpd      pnpm               snapcraft          tnftp
                                        benthos            duplicity          fluent-bit         heimdal            mdcat              quickjs            sphinx-doc         unnethack
                                        bit                dwarfutils         git-town           helmfile           mpg123             rsync              sratoolkit         vttest
                                        
                                        Error: openssl@1.1 1.1.1d is already installed
                                        To upgrade to 1.1.1g, run `brew upgrade openssl@1.1`
                                        simonplatten@Simons-iMac sqldrivers % 
                                        

                                        Kind Regards,
                                        Sy

                                        1 Reply Last reply
                                        0
                                        • hskoglundH Online
                                          hskoglundH Online
                                          hskoglund
                                          wrote on last edited by hskoglund
                                          #41

                                          Hi, I just tried the same, i.e. brew install mariadb and it worked 1st try:

                                          ~/Qt/5.15.0/clang_64/bin/qmake  -- MYSQL_INCDIR=/usr/local/Cellar/mariadb/10.4.13/include/mysql "MYSQL_LIBDIR=/usr/local/Cellar/mariadb/10.4.13/lib" MYSQL_LIBS="-lmariadb"
                                          Info: creating stash file /Users/henry/Downloads/qt-everywhere-src-5.15.0/qtbase/src/plugins/sqldrivers/.qmake.stash
                                          
                                          Running configuration tests...
                                          Checking for DB2 (IBM)... no
                                          Checking for InterBase... no
                                          Checking for MySQL... yes
                                          Checking for OCI (Oracle)... no
                                          Checking for ODBC... no
                                          Checking for PostgreSQL... no
                                          Checking for SQLite (version 2)... no
                                          Checking for TDS (Sybase)... no
                                          Done running configuration tests.
                                          
                                          Configure summary:
                                          
                                          Qt Sql Drivers:
                                            DB2 (IBM) .............................. no
                                            InterBase .............................. no
                                            MySql .................................. yes
                                            OCI (Oracle) ........................... no
                                            ODBC ................................... no
                                            PostgreSQL ............................. no
                                            SQLite2 ................................ no
                                            SQLite ................................. yes
                                              Using system provided SQLite ......... no
                                            TDS (Sybase) ........................... no
                                          
                                          Qt is now configured for building. Just run 'make'.
                                          Once everything is built, you must run 'make install'.
                                          Qt will be installed into '/Users/henry/Qt/5.15.0/clang_64'.
                                          
                                          Prior to reconfiguration, make sure you remove any leftovers from
                                          the previous build.
                                          

                                          and the config.log file: (just the interesting/good part):

                                          ...
                                          ...
                                          Trying source 4 (type inline) of library mysql ...
                                          + cd /Users/henry/Downloads/qt-everywhere-src-5.15.0/qtbase/src/plugins/sqldrivers/config.tests/mysql && /Users/henry/Qt/5.15.0/clang_64/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared warn_off console single_arch" 'INCLUDEPATH += /usr/local/opt/openssl/include' 'QMAKE_USE += mysql' 'QMAKE_LIBS_MYSQL = -L/usr/local/Cellar/mariadb/10.4.13/lib -lmariadb' 'QMAKE_INCDIR_MYSQL = /usr/local/Cellar/mariadb/10.4.13/include/mysql' /Users/henry/Downloads/qt-everywhere-src-5.15.0/qtbase/src/plugins/sqldrivers/config.tests/mysql
                                          + cd /Users/henry/Downloads/qt-everywhere-src-5.15.0/qtbase/src/plugins/sqldrivers/config.tests/mysql && MAKEFLAGS= make clean && MAKEFLAGS= make
                                          > rm -f main.o
                                          > rm -f *~ core *.core
                                          > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -c -pipe -stdlib=libc++ -O2 -std=gnu++11  -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -w -fPIC  -I. -I/usr/local/opt/openssl/include -I/usr/local/Cellar/mariadb/10.4.13/include/mysql -I/Users/henry/Qt/5.15.0/clang_64/mkspecs/macx-clang -o main.o main.cpp
                                          > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -stdlib=libc++ -headerpad_max_install_names  -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -Wl,-rpath,@executable_path/../Frameworks -o mysql main.o   -L/usr/local/Cellar/mariadb/10.4.13/lib -lmariadb   
                                           => source accepted.
                                          test config.sqldrivers.libraries.mysql succeeded
                                          ...
                                          ...
                                          

                                          The only difference I can see, is that I got mariadb version 10.4.13 but you have 10.4.6._1 maybe you can upgrade?

                                          Edit: added the good parts of the log :-)

                                          1 Reply Last reply
                                          2

                                          • Login

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • Users
                                          • Groups
                                          • Search
                                          • Get Qt Extensions
                                          • Unsolved