diff options
author | Thierry Bastian <thierry.bastian@nokia.com> | 2010-06-07 15:57:56 (GMT) |
---|---|---|
committer | Thierry Bastian <thierry.bastian@nokia.com> | 2010-06-07 16:18:22 (GMT) |
commit | bbf78c9b422c4c7eda7e7fce067578c75d3bc9b3 (patch) | |
tree | 2ddd960cecc78c60620faae4443d8c30eccc1428 | |
parent | 679611c26c5b7ecf63b4ed490803073a96ce9d92 (diff) | |
download | Qt-bbf78c9b422c4c7eda7e7fce067578c75d3bc9b3.zip Qt-bbf78c9b422c4c7eda7e7fce067578c75d3bc9b3.tar.gz Qt-bbf78c9b422c4c7eda7e7fce067578c75d3bc9b3.tar.bz2 |
Allow to build Qt in static with mingw
Some functions were marked with Q_DECL_IMPORT where they should just be
Q_CORE_EXPORT. The reason is that this macro is expanded to nothing in
case of static builds whereas Q_DECL_IMPORT isn't (it is a dllimport).
That leads the linker to try to import it and it shouldn't.
Task-number: QTBUG-10791
Reviewed-by: gabi
-rw-r--r-- | src/declarative/qml/parser/qdeclarativejslexer.cpp | 2 | ||||
-rw-r--r-- | src/gui/kernel/qapplication.cpp | 2 | ||||
-rw-r--r-- | src/gui/kernel/qwhatsthis.cpp | 2 | ||||
-rw-r--r-- | src/script/api/qscriptengine.cpp | 4 | ||||
-rw-r--r-- | src/script/parser/qscriptlexer.cpp | 2 | ||||
-rw-r--r-- | src/xmlpatterns/data/qdecimal_p.h | 2 |
6 files changed, 6 insertions, 8 deletions
diff --git a/src/declarative/qml/parser/qdeclarativejslexer.cpp b/src/declarative/qml/parser/qdeclarativejslexer.cpp index 975ad4c..fcaaece 100644 --- a/src/declarative/qml/parser/qdeclarativejslexer.cpp +++ b/src/declarative/qml/parser/qdeclarativejslexer.cpp @@ -57,7 +57,7 @@ #include <string.h> QT_BEGIN_NAMESPACE -Q_DECL_IMPORT extern double qstrtod(const char *s00, char const **se, bool *ok); +Q_CORE_EXPORT double qstrtod(const char *s00, char const **se, bool *ok); QT_END_NAMESPACE QT_QML_BEGIN_NAMESPACE diff --git a/src/gui/kernel/qapplication.cpp b/src/gui/kernel/qapplication.cpp index c9a3e8b..02d732b 100644 --- a/src/gui/kernel/qapplication.cpp +++ b/src/gui/kernel/qapplication.cpp @@ -146,7 +146,7 @@ static void initResources() QT_BEGIN_NAMESPACE -Q_DECL_IMPORT extern void qt_call_post_routines(); +Q_CORE_EXPORT void qt_call_post_routines(); int QApplicationPrivate::app_compile_version = 0x040000; //we don't know exactly, but it's at least 4.0.0 diff --git a/src/gui/kernel/qwhatsthis.cpp b/src/gui/kernel/qwhatsthis.cpp index 6181b62..ff4641e 100644 --- a/src/gui/kernel/qwhatsthis.cpp +++ b/src/gui/kernel/qwhatsthis.cpp @@ -143,7 +143,7 @@ QT_BEGIN_NAMESPACE \sa QToolTip */ -Q_DECL_IMPORT extern void qDeleteInEventHandler(QObject *o); +Q_CORE_EXPORT void qDeleteInEventHandler(QObject *o); class QWhatsThat : public QWidget { diff --git a/src/script/api/qscriptengine.cpp b/src/script/api/qscriptengine.cpp index 86915bb..f02ea52 100644 --- a/src/script/api/qscriptengine.cpp +++ b/src/script/api/qscriptengine.cpp @@ -1525,7 +1525,7 @@ void QScriptEnginePrivate::detachAllRegisteredScriptStrings() #ifndef QT_NO_REGEXP -Q_DECL_IMPORT extern QString qt_regexp_toCanonical(const QString &, QRegExp::PatternSyntax); +Q_CORE_EXPORT QString qt_regexp_toCanonical(const QString &, QRegExp::PatternSyntax); JSC::JSValue QScriptEnginePrivate::newRegExp(JSC::ExecState *exec, const QRegExp ®exp) { @@ -2020,8 +2020,6 @@ QScriptValue QScriptEngine::newFunction(QScriptEngine::FunctionSignature fun, #ifndef QT_NO_REGEXP -Q_DECL_IMPORT extern QString qt_regexp_toCanonical(const QString &, QRegExp::PatternSyntax); - /*! Creates a QtScript object of class RegExp with the given \a regexp. diff --git a/src/script/parser/qscriptlexer.cpp b/src/script/parser/qscriptlexer.cpp index ca64776..3ddc3aa 100644 --- a/src/script/parser/qscriptlexer.cpp +++ b/src/script/parser/qscriptlexer.cpp @@ -31,7 +31,7 @@ QT_BEGIN_NAMESPACE -Q_DECL_IMPORT extern double qstrtod(const char *s00, char const **se, bool *ok); +Q_CORE_EXPORT double qstrtod(const char *s00, char const **se, bool *ok); #define shiftWindowsLineBreak() \ do { \ diff --git a/src/xmlpatterns/data/qdecimal_p.h b/src/xmlpatterns/data/qdecimal_p.h index d17b647..2a5e0b3 100644 --- a/src/xmlpatterns/data/qdecimal_p.h +++ b/src/xmlpatterns/data/qdecimal_p.h @@ -61,7 +61,7 @@ QT_BEGIN_NAMESPACE /** * Defined in QtCore's qlocale.cpp. */ -Q_DECL_IMPORT extern char *qdtoa(double d, int mode, int ndigits, int *decpt, int *sign, char **rve, char **resultp); +Q_CORE_EXPORT char *qdtoa(double d, int mode, int ndigits, int *decpt, int *sign, char **rve, char **resultp); namespace QPatternist { |