summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@nokia.com>2012-06-19 09:40:17 +0200
committerSimon Hausmann <simon.hausmann@nokia.com>2012-06-25 13:36:36 +0200
commite7923d9de38974f0c6fb7646c898a6ea618261e8 (patch)
treed6b934d02933180e90804f04110913c7f6eddb69
parente5489852e18fb2c03bf3339f0ed1ecfb5ea66f25 (diff)
downloadqtwebkit-e7923d9de38974f0c6fb7646c898a6ea618261e8.tar.gz
Fix broken QtWebKit5.lib linking https://bugs.webkit.org/show_bug.cgi?id=88321
Patch by Joel Dillon <joel.dillon@codethink.co.uk> Jocelyn Turcotte <jocelyn.turcotte@nokia.com> on 2012-06-19 Reviewed by NOBODY (OOPS!). Source/JavaScriptCore: Also update the Wx build to use the new define. * API/JSBase.h: * runtime/JSExportMacros.h: * wscript: Source/WebCore: * platform/PlatformExportMacros.h: Source/WTF: Instead of letting a module's headers know which other modules depend on them, have depending modules define explicitely that they want its symbols exported too. JavaScriptCore should then be compiled with both BUILDING_JavaScriptCore and STATICALLY_LINKED_WITH_WTF. * wtf/ExportMacros.h: Tools: On windows the import/export definition is part of the symbol's signature. Define STATICALLY_LINKED_WITH_$$library for each dependend module that is being linked statically to make sure that they can be linked together later on. Also do not compile Assertions.cpp in DumpRenderTree anymore since all the used symbols are exported and it would cause a duplicate symbols error. * DumpRenderTree/qt/DumpRenderTree.pro: * qmake/mkspecs/features/default_post.prf:
-rw-r--r--Source/JavaScriptCore/API/JSBase.h2
-rw-r--r--Source/JavaScriptCore/ChangeLog13
-rw-r--r--Source/JavaScriptCore/runtime/JSExportMacros.h4
-rw-r--r--Source/JavaScriptCore/wscript2
-rw-r--r--Source/WTF/ChangeLog15
-rw-r--r--Source/WTF/wtf/ExportMacros.h6
-rw-r--r--Source/WebCore/ChangeLog9
-rw-r--r--Source/WebCore/platform/PlatformExportMacros.h6
-rw-r--r--Tools/ChangeLog18
-rw-r--r--Tools/DumpRenderTree/qt/DumpRenderTree.pro1
-rw-r--r--Tools/qmake/mkspecs/features/default_post.prf6
11 files changed, 72 insertions, 10 deletions
diff --git a/Source/JavaScriptCore/API/JSBase.h b/Source/JavaScriptCore/API/JSBase.h
index fed54fe23..f46a41755 100644
--- a/Source/JavaScriptCore/API/JSBase.h
+++ b/Source/JavaScriptCore/API/JSBase.h
@@ -71,7 +71,7 @@ typedef struct OpaqueJSValue* JSObjectRef;
#elif defined(__GNUC__) && !defined(__CC_ARM) && !defined(__ARMCC__)
#define JS_EXPORT __attribute__((visibility("default")))
#elif defined(WIN32) || defined(_WIN32) || defined(_WIN32_WCE) || defined(__CC_ARM) || defined(__ARMCC__)
-#if defined(BUILDING_JavaScriptCore) || defined(BUILDING_WTF)
+#if defined(BUILDING_JavaScriptCore) || defined(STATICALLY_LINKED_WITH_JavaScriptCore)
#define JS_EXPORT __declspec(dllexport)
#else
#define JS_EXPORT __declspec(dllimport)
diff --git a/Source/JavaScriptCore/ChangeLog b/Source/JavaScriptCore/ChangeLog
index 153f7fd1d..9304ce075 100644
--- a/Source/JavaScriptCore/ChangeLog
+++ b/Source/JavaScriptCore/ChangeLog
@@ -1,3 +1,16 @@
+2012-06-19 Joel Dillon <joel.dillon@codethink.co.uk> Jocelyn Turcotte <jocelyn.turcotte@nokia.com>
+
+ [Qt][Win] Fix broken QtWebKit5.lib linking
+ https://bugs.webkit.org/show_bug.cgi?id=88321
+
+ Reviewed by NOBODY (OOPS!).
+
+ Also update the Wx build to use the new define.
+
+ * API/JSBase.h:
+ * runtime/JSExportMacros.h:
+ * wscript:
+
2012-06-13 Patrick Gansterer <paroga@webkit.org>
[WIN] Remove dependency on pthread from MachineStackMarker
diff --git a/Source/JavaScriptCore/runtime/JSExportMacros.h b/Source/JavaScriptCore/runtime/JSExportMacros.h
index 884805f86..19e2c286f 100644
--- a/Source/JavaScriptCore/runtime/JSExportMacros.h
+++ b/Source/JavaScriptCore/runtime/JSExportMacros.h
@@ -36,7 +36,7 @@
// See note in wtf/Platform.h for more info on EXPORT_MACROS.
#if USE(EXPORT_MACROS)
-#if defined(BUILDING_JavaScriptCore)
+#if defined(BUILDING_JavaScriptCore) || defined(STATICALLY_LINKED_WITH_JavaScriptCore)
#define JS_EXPORT_PRIVATE WTF_EXPORT
#else
#define JS_EXPORT_PRIVATE WTF_IMPORT
@@ -50,7 +50,7 @@
#if !PLATFORM(CHROMIUM) && OS(WINDOWS) && !defined(BUILDING_WX__) && !COMPILER(GCC)
-#if defined(BUILDING_JavaScriptCore)
+#if defined(BUILDING_JavaScriptCore) || defined(STATICALLY_LINKED_WITH_JavaScriptCore)
#define JS_EXPORTDATA __declspec(dllexport)
#else
#define JS_EXPORTDATA __declspec(dllimport)
diff --git a/Source/JavaScriptCore/wscript b/Source/JavaScriptCore/wscript
index 4afb4d26a..58696d9c5 100644
--- a/Source/JavaScriptCore/wscript
+++ b/Source/JavaScriptCore/wscript
@@ -66,7 +66,7 @@ def build(bld):
features = 'cc cxx cshlib',
includes = '. .. assembler ../WTF ' + ' '.join(includes),
source = sources,
- defines = ['BUILDING_JavaScriptCore'],
+ defines = ['BUILDING_JavaScriptCore', 'STATICALLY_LINKED_WITH_WTF'],
target = 'jscore',
uselib = 'WX ICU ' + get_config(),
uselib_local = '',
diff --git a/Source/WTF/ChangeLog b/Source/WTF/ChangeLog
index 8a3746769..a7f149bed 100644
--- a/Source/WTF/ChangeLog
+++ b/Source/WTF/ChangeLog
@@ -1,3 +1,18 @@
+2012-06-19 Joel Dillon <joel.dillon@codethink.co.uk> Jocelyn Turcotte <jocelyn.turcotte@nokia.com>
+
+ [Qt][Win] Fix broken QtWebKit5.lib linking
+ https://bugs.webkit.org/show_bug.cgi?id=88321
+
+ Reviewed by NOBODY (OOPS!).
+
+ Instead of letting a module's headers know which other modules depend on them,
+ have depending modules define explicitely that they want its symbols exported too.
+
+ JavaScriptCore should then be compiled with both BUILDING_JavaScriptCore and
+ STATICALLY_LINKED_WITH_WTF.
+
+ * wtf/ExportMacros.h:
+
2012-06-25 Kent Tamura <tkent@chromium.org>
Change the serialization format of form control state to make the code simple
diff --git a/Source/WTF/wtf/ExportMacros.h b/Source/WTF/wtf/ExportMacros.h
index efa0c8f81..d50d6d117 100644
--- a/Source/WTF/wtf/ExportMacros.h
+++ b/Source/WTF/wtf/ExportMacros.h
@@ -72,7 +72,7 @@
// FIXME: When all ports are using the export macros, we should replace
// WTF_EXPORTDATA with WTF_EXPORT_PRIVATE macros.
-#if defined(BUILDING_WTF) || defined(BUILDING_JavaScriptCore)
+#if defined(BUILDING_WTF) || defined(STATICALLY_LINKED_WITH_WTF)
#define WTF_EXPORTDATA WTF_EXPORT
#else
#define WTF_EXPORTDATA WTF_IMPORT
@@ -81,7 +81,7 @@
#else // !USE(EXPORT_MACROS)
#if !PLATFORM(CHROMIUM) && OS(WINDOWS) && !COMPILER(GCC)
-#if defined(BUILDING_WTF) || defined(BUILDING_JavaScriptCore)
+#if defined(BUILDING_WTF) || defined(STATICALLY_LINKED_WITH_WTF)
#define WTF_EXPORTDATA __declspec(dllexport)
#else
#define WTF_EXPORTDATA __declspec(dllimport)
@@ -98,7 +98,7 @@
#endif // USE(EXPORT_MACROS)
-#if defined(BUILDING_WTF) || defined(BUILDING_JavaScriptCore)
+#if defined(BUILDING_WTF) || defined(STATICALLY_LINKED_WITH_WTF)
#define WTF_EXPORT_PRIVATE WTF_EXPORT
#else
#define WTF_EXPORT_PRIVATE WTF_IMPORT
diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog
index c09c1f4ea..b4a2c4cfc 100644
--- a/Source/WebCore/ChangeLog
+++ b/Source/WebCore/ChangeLog
@@ -1,3 +1,12 @@
+2012-06-19 Joel Dillon <joel.dillon@codethink.co.uk> Jocelyn Turcotte <jocelyn.turcotte@nokia.com>
+
+ [Qt][Win] Fix broken QtWebKit5.lib linking
+ https://bugs.webkit.org/show_bug.cgi?id=88321
+
+ Reviewed by NOBODY (OOPS!).
+
+ * platform/PlatformExportMacros.h:
+
2012-06-25 Simon Hausmann <simon.hausmann@nokia.com>
[Qt] Fix Win32 debug build
diff --git a/Source/WebCore/platform/PlatformExportMacros.h b/Source/WebCore/platform/PlatformExportMacros.h
index 6c70813ad..ae3e30a3a 100644
--- a/Source/WebCore/platform/PlatformExportMacros.h
+++ b/Source/WebCore/platform/PlatformExportMacros.h
@@ -35,7 +35,8 @@
// See note in wtf/Platform.h for more info on EXPORT_MACROS.
#if USE(EXPORT_MACROS)
-#if defined(BUILDING_WebCore) || defined(BUILDING_WebKit)
+#if defined(BUILDING_WebCore) || defined(BUILDING_WebKit) || \
+ defined(STATICALLY_LINKED_WITH_WebCore) || defined(STATICALLY_LINKED_WITH_WebKit)
#define WEBKIT_EXPORTDATA WTF_EXPORT
#else
#define WEBKIT_EXPORTDATA WTF_IMPORT
@@ -45,7 +46,8 @@
#if !PLATFORM(CHROMIUM) && OS(WINDOWS) && !defined(BUILDING_WX__) && !COMPILER(GCC)
-#if defined(BUILDING_WebCore) || defined(BUILDING_WebKit)
+#if defined(BUILDING_WebCore) || defined(BUILDING_WebKit) || \
+ defined(STATICALLY_LINKED_WITH_WebCore) || defined(STATICALLY_LINKED_WITH_WebKit)
#define WEBKIT_EXPORTDATA __declspec(dllexport)
#else
#define WEBKIT_EXPORTDATA __declspec(dllimport)
diff --git a/Tools/ChangeLog b/Tools/ChangeLog
index b563f8e91..834d46e46 100644
--- a/Tools/ChangeLog
+++ b/Tools/ChangeLog
@@ -1,3 +1,21 @@
+2012-06-19 Joel Dillon <joel.dillon@codethink.co.uk> Jocelyn Turcotte <jocelyn.turcotte@nokia.com>
+
+ [Qt][Win] Fix broken QtWebKit5.lib linking
+ https://bugs.webkit.org/show_bug.cgi?id=88321
+
+ Reviewed by NOBODY (OOPS!).
+
+ On windows the import/export definition is part of the symbol's signature.
+ Define STATICALLY_LINKED_WITH_$$library for each dependend module
+ that is being linked statically to make sure that they can be linked together
+ later on.
+
+ Also do not compile Assertions.cpp in DumpRenderTree anymore since all the
+ used symbols are exported and it would cause a duplicate symbols error.
+
+ * DumpRenderTree/qt/DumpRenderTree.pro:
+ * qmake/mkspecs/features/default_post.prf:
+
2012-06-25 Simon Hausmann <simon.hausmann@nokia.com>
[Qt] Fix Win32 debug build
diff --git a/Tools/DumpRenderTree/qt/DumpRenderTree.pro b/Tools/DumpRenderTree/qt/DumpRenderTree.pro
index 53a8c01f8..327dc3a79 100644
--- a/Tools/DumpRenderTree/qt/DumpRenderTree.pro
+++ b/Tools/DumpRenderTree/qt/DumpRenderTree.pro
@@ -37,7 +37,6 @@ HEADERS += \
testplugin.h
SOURCES += \
- $${ROOT_WEBKIT_DIR}/Source/WTF/wtf/Assertions.cpp \
$$PWD/../WorkQueue.cpp \
DumpRenderTreeQt.cpp \
EventSenderQt.cpp \
diff --git a/Tools/qmake/mkspecs/features/default_post.prf b/Tools/qmake/mkspecs/features/default_post.prf
index 78c93d7c0..2efbd7298 100644
--- a/Tools/qmake/mkspecs/features/default_post.prf
+++ b/Tools/qmake/mkspecs/features/default_post.prf
@@ -212,6 +212,12 @@ for(library, WEBKIT) {
LIBS += $$dependent_libs
}
+ # Anything not linking dynamically to QtWebKit should make sure to have their export
+ # macros syncrhonized with the code that it will linked with statically.
+ !contains(QT, webkit) {
+ DEFINES += STATICALLY_LINKED_WITH_$$library
+ }
+
LIBS = $$existing_libs $$LIBS
}