Changeset 792


Ignore:
Timestamp:
Oct 11, 2010, 10:14:03 PM (15 years ago)
Author:
Dmitry A. Kuminov
Message:

plugins: Enabled the MySQL Qt plugin.

Location:
trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/README.OS2

    r789 r792  
    7272    available at:
    7373
    74       http://rpm.netlabs.org/experimental/00/i386/i386/openssl-devel-1.0.0a-1.i386.rpm
    75       http://rpm.netlabs.org/experimental/00/i386/i386/openssl-1.0.0a-1.i386.rpm
    76 
    77       or
    78 
    7974      http://bauxite.sakura.ne.jp/tmp/os2/openssl-1.0.0a-os2knix-20100706-runtime.zip
    8075      http://bauxite.sakura.ne.jp/tmp/os2/openssl-1.0.0a-os2knix-20100706-dev.zip
    8176
     77  - MySQL 5.1 or later for the MySQL Qt plugin. The MySQL libraries are
     78    available at:
     79
     80      http://download.smedley.info/mysql-5.1.51-os2-20101001.zip
     81
     82    Note that you will also need the above OpenSSL libraries and pthread.lib to
     83    be able to use this MySQL build.
    8284
    8385
     
    159161    variables to tell the Qt configure script its location:
    160162
    161       set CUPS_INCLUDEPATH=X:\<path_to_CUPS>\include
    162       set CUPS_LIBS=-LX:\<path_to_CUPS>\lib -llibcups.a -L<path_to_pthread> -lpthread.lib
     163      set CUPS_INCLUDEPATH=<path_to_CUPS>\include
     164      set CUPS_LIBS=-L<path_to_CUPS>\lib -llibcups.a -L<path_to_pthread> -lpthread.lib
    163165
    164166  - Unzip the OpenSSL libraries to some directory and set the following
    165167    environment variables to tell the Qt configure script its location:
    166168
    167       set OPENSSL_INCLUDEPATH=X:\<path_to_OpenSSL>\include
     169      set OPENSSL_INCLUDEPATH=<path_to_OpenSSL>\include
    168170      set OPENSSL_LIBS=
    169171
     
    172174    runtime:
    173175
    174       set BEGINLIBPATH=X:\<path_to_OpenSSL>\dll;%BEGINLIBPATH%
     176      set BEGINLIBPATH=<path_to_OpenSSL>\dll;%BEGINLIBPATH%
     177
     178  - Unzip the MySQL archive to some directory and set the following environment
     179    variables to tell the Qt configure script the library location:
     180
     181      set MYSQL_INCLUDEPATH=<path_to_MySQL>\include'
     182      set MYSQL_LIBS=-L<path_to_MySQL>\lib -lmysqlclient_r -L<path_to_OpenSSL>\lib -llibssl -llibcrypto -L<path_to_pthread> -lpthread
    175183
    176184
  • trunk/configure.cmd

    r789 r792  
    228228    G.CFG_QCONFIG = "full"
    229229    G.CFG_DEBUG = "auto"
    230     G.CFG_MYSQL_CONFIG = ""
    231230    G.CFG_DEBUG_RELEASE = "no"
    232231    G.CFG_SHARED = "yes"
     
    358357    G.QMAKE_EXEPACK_POST_FLAGS = ""
    359358
    360     /* flags for SQL drivers */
    361     G.QT_CFLAGS_PSQL = ""
    362     G.QT_LFLAGS_PSQL = ""
    363     G.QT_CFLAGS_MYSQL = ""
    364     G.QT_LFLAGS_MYSQL = ""
    365     G.QT_LFLAGS_MYSQL_R = ""
    366     G.QT_CFLAGS_SQLITE = ""
    367     G.QT_LFLAGS_SQLITE = ""
    368 
    369359    /* check SQL drivers, mouse drivers and decorations available in
    370360     * this package */
     
    916906        call Done 2
    917907
     908    call SayLog
     909
    918910    /*--------------------------------------------------------------------------
    919911     tests that need qmake
     
    927919        drv = word(G.CFG_SQL_AVAILABLE, i)
    928920        select
     921            when (drv == "mysql") then do
     922                if (G.CFG_SQL_mysql \== "no") then do
     923                    /* detect MySQL libraries */
     924                    G.MYSQL_INCLUDEPATH = GetEnv('MYSQL_INCLUDEPATH')
     925                    G.MYSQL_LIBS = GetEnv('MYSQL_LIBS')
     926                    if (G.MYSQL_INCLUDEPATH \== '' & G.MYSQL_LIBS \== '')  then do
     927                        call SayVerbose 'MySQL include path : 'G.MYSQL_INCLUDEPATH
     928                        call SayVerbose 'MySQL libraries    : 'G.MYSQL_LIBS
     929                        call SayVerbose
     930                        /* qt sources for some reason include mysql headers directly, so
     931                         * add a prefix here to fix that */
     932                        G.MYSQL_INCLUDEPATH = G.MYSQL_INCLUDEPATH'/mysql'
     933                        if (G.CFG_SQL_mysql == "auto") then
     934                            G.CFG_SQL_mysql = "plugin"
     935                    end
     936                    else do
     937                        call SayVerbose,
     938'Warning: MySQL libraries are not specified, MySQL plugin is disabled.'G.EOL||,
     939'Use MYSQL_INCLUDEPATH and MYSQL_LIBS environment variables to specify'G.EOL||,
     940'the location of the libraries.'G.EOL||G.EOL
     941                        G.CFG_SQL_mysql = 'no'
     942                    end
     943                end
     944            end
    929945            when (drv == "sqlite") then do
    930946                if (G.CFG_SQL_sqlite \== "no") then do
    931947                    if (G.CFG_SQLITE == "system") then do
    932948                        /* @todo external sqlite3 library isn't yet supported */
    933                         call SayLog,
     949                        call SayVerbose,
    934950"Warning: Linking against the external sqlite3 library isn't yet supported,"G.EOL||,
    935951"the sqlite SQL driver is disabled"G.EOL||G.EOL
     
    942958                        end
    943959                        else do
     960                            call SayVerbose,
    944961"Warning: 3rdparty sources for the sqlite3 library are not found,"G.EOL||,
    945962"the sqlite SQL driver is disabled"G.EOL||G.EOL
     
    17211738'QMAKE_LIBDIR_QT = $$QT_BUILD_TREE\lib'G.EOL||G.EOL
    17221739
    1723     if (G.QT_CFLAGS_PSQL \== "") then
    1724         call lineout qmake_cache_new, 'QT_CFLAGS_PSQL  = 'G.QT_CFLAGS_PSQL
    1725     if (G.QT_LFLAGS_PSQL \== "") then
    1726         call lineout qmake_cache_new, 'QT_LFLAGS_PSQL  = 'G.QT_LFLAGS_PSQL
    1727     if (G.QT_CFLAGS_MYSQL \== "") then
    1728         call lineout qmake_cache_new, 'QT_CFLAGS_MYSQL = 'G.QT_CFLAGS_MYSQL
    1729     if (G.QT_LFLAGS_MYSQL \== "") then
    1730         call lineout qmake_cache_new, 'QT_LFLAGS_MYSQL = 'G.QT_LFLAGS_MYSQL
    1731     if (G.QT_CFLAGS_SQLITE \== "") then
    1732         call lineout qmake_cache_new, 'QT_CFLAGS_SQLITE = 'G.QT_CFLAGS_SQLITE
    1733     if (G.QT_LFLAGS_SQLITE \== "") then
    1734         call lineout qmake_cache_new, 'QT_LFLAGS_SQLITE = 'G.QT_LFLAGS_SQLITE
     1740    if (G.MYSQL_INCLUDEPATH \== "") then
     1741        call lineout qmake_cache_new, 'MYSQL_INCLUDEPATH = 'G.MYSQL_INCLUDEPATH
     1742    if (G.MYSQL_LIBS \== "") then
     1743        call lineout qmake_cache_new, 'MYSQL_LIBS = 'G.MYSQL_LIBS
    17351744
    17361745    if (G.QT_EDITION \== "QT_EDITION_OPENSOURCE") then
  • trunk/src/plugins/sqldrivers/mysql/mysql.pro

    r2 r792  
    11TARGET   = qsqlmysql
     2os2:TARGET_SHORT = qmysql
    23
    34HEADERS         = ../../../sql/drivers/mysql/qsql_mysql.h
     
    2122}
    2223
     24os2 {
     25    INCLUDEPATH *= $$MYSQL_INCLUDEPATH
     26    LIBS        *= $$MYSQL_LIBS   
     27}
     28
    2329include(../qsqldriverbase.pri)
Note: See TracChangeset for help on using the changeset viewer.