Ticket #4264: combine-libs.2.patch

File combine-libs.2.patch, 10.8 KB (added by Nigel, 16 years ago)

MinGW library name and install target fixes

  • xmlparse.cpp

     
    291291    if (baseFont && !haveSize)
    292292        size = baseFont->face.pointSize();
    293293    else   
    294         size = GetMythMainWindow()->NormalizeFontSize(size);
     294        size = gContext->NormalizeFontSize(size);
    295295   
    296296    // If we don't have to, don't load the font.
    297297    if (!haveFace && baseFont)
  • mythdbcon.h

     
    116116    /// \brief Wrap QSqlQuery::exec(const QString &query) so we can display SQL
    117117    bool exec(const QString &query);
    118118
    119     /// \brief QSqlQuery::prepare() is not thread safe in Qt <= 3.3.2
    120119    bool prepare(const QString &query);
    121120
    122121    /// \brief Wrap QSqlQuery::bindValue so we can convert null QStrings to empty QStrings
    123     void bindValue ( const QString & placeholder, const QVariant & val, QSql::ParamType paramType = QSql::In );
     122    void bindValue ( const QString & placeholder, const QVariant & val,
     123                     QSql::ParamType paramType = QSql::In );
    124124    /// \brief Wrap QSqlQuery::bindValue so we can convert null QStrings to empty QStrings
    125     void bindValue ( int pos, const QVariant & val, QSql::ParamType paramType = QSql::In );
     125    void bindValue ( int pos,
     126                     const QVariant & val, QSql::ParamType paramType = QSql::In );
    126127
    127128    /// \brief Add all the bindings in the passed in bindings
    128129    void bindValues(MSqlBindings &bindings);
  • mythcontext.cpp

     
    221221    Settings *m_settings;          ///< connection stuff, theme, button style
    222222    Settings *m_qtThemeSettings;   ///< everything else theme-related
    223223
    224     QString   m_installprefix;     ///< Compile-time PREFIX, or generated
     224    QString   m_installprefix;     ///< Compile-time RUNPREFIX, or generated
    225225                                   ///< from enviroment ($MYTHTVDIR or $cwd)
    226226    QString   m_installlibdir;     ///< Compile-time LIBDIR, or generated
    227227
     
    314314MythContextPrivate::MythContextPrivate(MythContext *lparent)
    315315    : parent(lparent),
    316316      m_settings(new Settings()), m_qtThemeSettings(new Settings()),
    317       m_installprefix(PREFIX), m_installlibdir(LIBDIR),
     317      m_installprefix(RUNPREFIX), m_installlibdir(LIBDIR),
    318318      m_gui(false), m_backend(false), m_themeloaded(false),
    319319      m_menuthemepathname(QString::null), m_themepathname(QString::null),
    320320      m_backgroundimage(NULL),
     
    368368            m_installlibdir = prefixDir.canonicalPath();
    369369        }
    370370    }
    371     else if (prefixDir.path().contains(".app/Contents/MacOS"))
    372     {
    373         prefixDir.cd("../Resources");
    374         if (QDir(prefixDir.canonicalPath() + "/bin").exists() ||
    375             QDir(prefixDir.canonicalPath() + "/share").exists())
    376             m_installprefix = prefixDir.canonicalPath();
    377         if (QDir(prefixDir.canonicalPath() + "/lib").exists())
    378             m_installlibdir = prefixDir.canonicalPath() + "/lib";
    379     }
    380371
    381372    VERBOSE(VB_IMPORTANT, QString("Using runtime prefix = %1, libdir = %2")
    382373                          .arg(m_installprefix).arg(m_installlibdir));
  • mythdbcon.cpp

     
    134134    // mdz, 2003/08/11
    135135
    136136
    137     if (m_db.hostName().isEmpty())  // Bootstrapping without a database?
     137#if 0
     138    if (m_db.hostName().isEmpty()    // Bootstrapping without a database?
     139        || m_db.isOpenError())       // Database invalid?
     140#endif
     141    if (m_db.hostName().isEmpty())   // Bootstrapping without a database?
    138142    {                                // Pretend we kicked, to reduce errors
    139143        m_lastDBKick = QDateTime::currentDateTime();
    140144        return true;
     
    326330            qi.db = db;
    327331            qi.qsqldb = db->db();
    328332
    329             db->KickDatabase();
     333            //db->KickDatabase();
    330334        }
    331335    }
    332336    else
     
    351355            qi.db = db;
    352356            qi.qsqldb = db->db();
    353357
    354             db->KickDatabase();
     358            //db->KickDatabase();
    355359        }
    356360    }
    357361    else
     
    376380            qi.db = db;
    377381            qi.qsqldb = db->db();
    378382
    379             db->KickDatabase();
     383            //db->KickDatabase();
    380384        }
    381385    }
    382386    else
  • libmyth.pro

     
    11include ( ../../config.mak )
    22include ( ../../settings.pro )
    3  
     3
    44TEMPLATE = lib
    55TARGET = myth-$$LIBVERSION
    6 CONFIG += thread dll
     6CONFIG += thread dll debug
    77target.path = $${LIBDIR}
    88INSTALLS = target
    99
     
    5656
    5757LIBS += -L../libmythsamplerate   -lmythsamplerate-$${LIBVERSION}
    5858LIBS += -L../libmythsoundtouch   -lmythsoundtouch-$${LIBVERSION}
    59 LIBS += -L../libmythui           -lmythui-$${LIBVERSION}
    60 LIBS += -L../libmythupnp         -lmythupnp-$${LIBVERSION}
     59!combine-libmyth: LIBS += -L../libmythui           -lmythui-$${LIBVERSION}
     60!combine-libmyth: LIBS += -L../libmythupnp         -lmythupnp-$${LIBVERSION}
    6161LIBS += -L../libmythfreesurround -lmythfreesurround-$${LIBVERSION}
    6262LIBS += -L../libavcodec          -lmythavcodec-$${LIBVERSION}
    6363LIBS += -L../libavutil           -lmythavutil-$${LIBVERSION}
     
    113113
    114114    # For easier debugging:
    115115    target.path = $${PREFIX}/bin
    116 
     116 
     117  !combine-libmyth {
    117118    LIBS -= -lmythui-$$LIBVERSION  -lmythupnp-$$LIBVERSION
    118119    LIBS += -L. -lmythui-bootstrap -lmythupnp-bootstrap
    119120    POST_TARGETDEPS += libmythui-bootstrap.a libmythupnp-bootstrap.a
     
    128129                       --dllname libmythupnp-$${LIBVERSION}.dll \
    129130                       --output-lib $$implib2.target  -k
    130131    QMAKE_EXTRA_WIN_TARGETS += implib implib2
     132  }
    131133}
    132134
    133135macx {
     
    248250
    249251#The following line was inserted by qt3to4
    250252QT += network xml opengl sql qt3support
     253
     254
     255combine-libmyth {
     256    # ../libmythupnp/libmythupnp.pro
     257
     258    include (../../version.pro)
     259
     260    setting.path = $${PREFIX}/share/mythtv/
     261    setting.files += CDS_scpd.xml CMGR_scpd.xml MSRR_scpd.xml MXML_scpd.xml
     262
     263    INSTALLS += setting
     264
     265    HEADERS3 += httprequest.h upnp.h ssdp.h taskqueue.h 
     266    HEADERS3 += upnpdevice.h upnptasknotify.h upnptasksearch.h threadpool.h upnputil.h
     267    HEADERS3 += httpserver.h upnpcds.h upnpcdsobjects.h bufferedsocketdevice.h upnpmsrr.h
     268    HEADERS3 += eventing.h upnpcmgr.h upnptaskevent.h upnptaskcache.h ssdpcache.h
     269    HEADERS3 += upnpimpl.h multicast.h broadcast.h configuration.h
     270    HEADERS3 += soapclient.h mythxmlclient.h
     271
     272    SOURCES3 += httprequest.cpp upnp.cpp ssdp.cpp taskqueue.cpp upnputil.cpp
     273    SOURCES3 += upnpdevice.cpp upnptasknotify.cpp upnptasksearch.cpp threadpool.cpp
     274    SOURCES3 += httpserver.cpp upnpcds.cpp upnpcdsobjects.cpp bufferedsocketdevice.cpp
     275    SOURCES3 += eventing.cpp upnpcmgr.cpp upnpmsrr.cpp upnptaskevent.cpp ssdpcache.cpp
     276    SOURCES3 += configuration.cpp soapclient.cpp mythxmlclient.cpp
     277
     278    LIBS += $$EXTRA_LIBS
     279
     280    mingw {
     281        HEADERS3 += darwin-sendfile.h
     282        SOURCES3 += darwin-sendfile.c
     283
     284        LIBS += -lws2_32
     285    }
     286
     287    inc3.path = $${PREFIX}/include/mythtv/upnp/
     288
     289    inc3.files  = httprequest.h upnp.h ssdp.h taskqueue.h bufferedsocketdevice.h
     290    inc3.files += upnpdevice.h upnptasknotify.h upnptasksearch.h threadpool.h upnputil.h
     291    inc3.files += httpserver.h httpstatus.h upnpcds.h upnpcdsobjects.h
     292    inc3.files += eventing.h upnpcmgr.h upnptaskevent.h upnptaskcache.h ssdpcache.h
     293    inc3.files += upnpimpl.h multicast.h broadcast.h configuration.h
     294    inc3.files += soapclient.h mythxmlclient.h
     295
     296    INSTALLS += inc3
     297
     298    cygwin:HEADERS3 += darwin-sendfile.h
     299    cygwin:SOURCES3 += darwin-sendfile.c
     300
     301    freebsd:HEADERS3 += darwin-sendfile.h
     302    freebsd:SOURCES3 += darwin-sendfile.c
     303
     304    macx {
     305        HEADERS3 += darwin-sendfile.h
     306        SOURCES3 += darwin-sendfile.c
     307
     308        QMAKE_LFLAGS_SHLIB += -flat_namespace
     309    }
     310
     311
     312
     313
     314    # ../libmythui/libmythui.pro
     315
     316    HEADERS4  = mythmainwindow.h mythpainter.h mythimage.h myththemebase.h
     317    HEADERS4 += mythpainter_qt.h mythmainwindow_internal.h
     318    HEADERS4 += mythscreenstack.h mythscreentype.h mythuitype.h mythuiimage.h
     319    HEADERS4 += mythuitext.h mythuistatetype.h mythgesture.h xmlparsebase.h
     320    HEADERS4 += mythuibutton.h mythlistbutton.h myththemedmenu.h mythdialogbox.h
     321    HEADERS4 += mythuiclock.h mythuitextedit.h mythprogressdialog.h mythuispinbox.h
     322
     323    SOURCES4  = mythmainwindow.cpp mythpainter.cpp mythimage.cpp myththemebase.cpp
     324    SOURCES4 += mythpainter_qt.cpp xmlparsebase.cpp
     325    SOURCES4 += mythscreenstack.cpp mythscreentype.cpp mythgesture.cpp
     326    SOURCES4 += mythuitype.cpp mythuiimage.cpp mythuitext.cpp
     327    SOURCES4 += mythuistatetype.cpp mythlistbutton.cpp mythfontproperties.cpp
     328    SOURCES4 += mythuibutton.cpp myththemedmenu.cpp mythdialogbox.cpp
     329    SOURCES4 += mythuiclock.cpp mythuitextedit.cpp mythprogressdialog.cpp
     330    SOURCES4 += mythuispinbox.cpp
     331
     332    inc4.path = $${PREFIX}/include/mythtv/libmythui/
     333
     334    inc4.files  = mythmainwindow.h mythpainter.h mythimage.h myththemebase.h
     335    inc4.files += mythpainter_qt.h mythuistatetype.h
     336    inc4.files += mythscreenstack.h mythscreentype.h mythuitype.h mythuiimage.h
     337    inc4.files += mythuitext.h mythuibutton.h mythlistbutton.h xmlparsebase.h
     338    inc4.files += myththemedmenu.h mythdialogbox.h mythfontproperties.h
     339    inc4.files += mythuiclock.h mythgesture.h mythuitextedit.h mythprogressdialog.h
     340    inc4.files += mythuispinbox.h
     341
     342    INSTALLS += inc4
     343
     344    using_x11:using_opengl {
     345        DEFINES += USE_OPENGL_PAINTER
     346        SOURCES4 += mythpainter_ogl.cpp
     347        HEADERS4 += mythpainter_ogl.h
     348        inc4.files += mythpainter_ogl.h
     349        LIBS += $$EXTRA_LIBS
     350    }
     351
     352    macx {
     353        QMAKE_CXXFLAGS += -F/System/Library/Frameworks/Carbon.framework/Frameworks
     354        LIBS           += -framework Carbon -framework OpenGL
     355
     356        QMAKE_LFLAGS_SHLIB += -flat_namespace
     357    }
     358
     359    using_joystick_menu {
     360        DEFINES += USE_JOYSTICK_MENU
     361    }
     362
     363    using_lirc {
     364        DEFINES += USE_LIRC
     365    }
     366
     367    cygwin:DEFINES += _WIN32
     368
     369    mingw {
     370        using_opengl {
     371            LIBS += -lopengl32
     372            DEFINES += USE_OPENGL_PAINTER
     373            SOURCES4 += mythpainter_ogl.cpp
     374            HEADERS4 += mythpainter_ogl.h
     375            inc4.files += mythpainter_ogl.h
     376        }
     377    }
     378
     379    HEADERS += $$join(HEADERS3, ' ', '../libmythupnp/')
     380    HEADERS += $$join(HEADERS4, ' ', '../libmythui/')
     381    SOURCES += $$join(SOURCES3, ' ', '../libmythupnp/')
     382    SOURCES += $$join(SOURCES4, ' ', '../libmythui/')
     383}