mirror of
https://invent.kde.org/network/falkon.git
synced 2024-12-20 10:46:35 +01:00
[MinGW] Some fixes for MinGW building
This commit is contained in:
parent
d91e6ef5a7
commit
018d7ec098
2
src/lib/3rdparty/ecwin7.h
vendored
2
src/lib/3rdparty/ecwin7.h
vendored
@ -27,7 +27,9 @@
|
||||
|
||||
// Windows only data definitions
|
||||
#ifdef W7TASKBAR
|
||||
#ifndef __MINGW32__
|
||||
#define NOMINMAX
|
||||
#endif
|
||||
#include <windows.h>
|
||||
#include <initguid.h>
|
||||
#define CMIC_MASK_ASYNCOK SEE_MASK_ASYNCOK
|
||||
|
2
src/lib/3rdparty/qtwin.h
vendored
2
src/lib/3rdparty/qtwin.h
vendored
@ -39,7 +39,9 @@
|
||||
*/
|
||||
#ifdef Q_OS_WIN
|
||||
// Qt5 compile issue: http://comments.gmane.org/gmane.comp.lib.qt.user/4711
|
||||
#ifndef __MINGW32__
|
||||
#define NOMINMAX
|
||||
#endif
|
||||
#ifdef W7API
|
||||
#include <ShlObj.h>
|
||||
#include <shlwapi.h>
|
||||
|
@ -12,13 +12,10 @@ DEFINES *= QUPZILLA_SHAREDLIBRARY
|
||||
include(3rdparty/qtsingleapplication.pri)
|
||||
include(../defines.pri)
|
||||
include(../../translations/translations.pri)
|
||||
include(plugins/qtwebkit/qtwebkit-plugins.pri)
|
||||
|
||||
CONFIG(debug, debug|release): include(../../tests/modeltest/modeltest.pri)
|
||||
|
||||
!mac:contains(DEFINES, USE_QTWEBKIT_2_2) {
|
||||
include(plugins/qtwebkit/qtwebkit-plugins.pri)
|
||||
}
|
||||
|
||||
unix:!contains(DEFINES, "DISABLE_DBUS") QT += dbus
|
||||
|
||||
INCLUDEPATH += 3rdparty\
|
||||
|
@ -149,6 +149,7 @@ bool RegisterQAppAssociation::isVistaOrNewer()
|
||||
void RegisterQAppAssociation::registerAssociation(const QString &assocName, AssociationType type)
|
||||
{
|
||||
if (isVistaOrNewer()) { // Vista and newer
|
||||
#ifndef __MINGW32__
|
||||
IApplicationAssociationRegistration* pAAR;
|
||||
|
||||
HRESULT hr = CoCreateInstance(CLSID_ApplicationAssociationRegistration,
|
||||
@ -187,6 +188,7 @@ void RegisterQAppAssociation::registerAssociation(const QString &assocName, Asso
|
||||
|
||||
pAAR->Release();
|
||||
}
|
||||
#endif // #ifndef __MINGW32__
|
||||
}
|
||||
else { // Older than Vista
|
||||
QSettings regUserRoot(_UserRootKey, QSettings::NativeFormat);
|
||||
@ -246,9 +248,11 @@ void RegisterQAppAssociation::registerAllAssociation()
|
||||
}
|
||||
|
||||
if (!isVistaOrNewer()) {
|
||||
#ifndef __MINGW32__
|
||||
// On Windows Vista or newer for updating icons 'pAAR->SetAppAsDefault()'
|
||||
// calls 'SHChangeNotify()'. Thus, we just need care about older Windows.
|
||||
SHChangeNotify(SHCNE_ASSOCCHANGED, SHCNF_FLUSHNOWAIT, 0 , 0);
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1,23 +1,47 @@
|
||||
HEADERS += $$PWD/qtwebkitplugin.h \
|
||||
$$PWD/notifications/notificationpresenter.h \
|
||||
$$[QT_INSTALL_HEADERS]/QtWebKit/qwebkitplatformplugin.h \
|
||||
# Unix
|
||||
!mac:unix {
|
||||
buildNotifications = true
|
||||
|
||||
|
||||
SOURCES += $$PWD/qtwebkitplugin.cpp \
|
||||
$$PWD/notifications/notificationpresenter.cpp \
|
||||
|
||||
DEFINES *= QT_STATICPLUGIN
|
||||
|
||||
|
||||
!mac:unix:contains(DEFINES, USE_QTWEBKIT_2_3):system(pkg-config --exists hunspell) {
|
||||
buildSpellcheck = true
|
||||
LIBS += $$system(pkg-config --libs hunspell)
|
||||
contains(DEFINES, USE_QTWEBKIT_2_3):system(pkg-config --exists hunspell) {
|
||||
buildSpellcheck = true
|
||||
LIBS += $$system(pkg-config --libs hunspell)
|
||||
}
|
||||
}
|
||||
|
||||
# Mac OS X
|
||||
mac {
|
||||
buildPlugin = false
|
||||
}
|
||||
|
||||
# Windows
|
||||
win32 {
|
||||
# QtWebKit 2.3 and Hunspell is now needed to build on Windows
|
||||
buildSpellcheck = true
|
||||
LIBS += -llibhunspell
|
||||
win32-msvc* {
|
||||
# QtWebKit 2.3 and Hunspell is now needed to build on Windows
|
||||
buildNotifications = true
|
||||
buildSpellcheck = true
|
||||
LIBS += -llibhunspell
|
||||
}
|
||||
else { # mingw
|
||||
buildPlugin = false
|
||||
}
|
||||
}
|
||||
|
||||
!equals(buildPlugin, false) {
|
||||
HEADERS += $$PWD/qtwebkitplugin.h \
|
||||
$$[QT_INSTALL_HEADERS]/QtWebKit/qwebkitplatformplugin.h
|
||||
|
||||
SOURCES += $$PWD/qtwebkitplugin.cpp
|
||||
|
||||
DEFINES *= QT_STATICPLUGIN
|
||||
}
|
||||
else {
|
||||
buildNotifications = false
|
||||
buildSpellcheck = false
|
||||
}
|
||||
|
||||
equals(buildNotifications, true) {
|
||||
HEADERS += $$PWD/notifications/notificationpresenter.h
|
||||
SOURCES += $$PWD/notifications/notificationpresenter.cpp
|
||||
}
|
||||
|
||||
equals(buildSpellcheck, true) {
|
||||
|
Loading…
Reference in New Issue
Block a user