summaryrefslogtreecommitdiff
path: root/www/webkit-gtk
diff options
context:
space:
mode:
authorjoerg <joerg@pkgsrc.org>2013-05-09 14:04:42 +0000
committerjoerg <joerg@pkgsrc.org>2013-05-09 14:04:42 +0000
commit05c462139cce4ffd6f9d987fe8c803c7bea64843 (patch)
treebc14532c6d4dfef48cf0feae6ff059ba743ca822 /www/webkit-gtk
parent60a6e35a1391e52f01d1666d99b5a6d7a44b20de (diff)
downloadpkgsrc-05c462139cce4ffd6f9d987fe8c803c7bea64843.tar.gz
Allow building with libc++. Add some missing includes.
Diffstat (limited to 'www/webkit-gtk')
-rw-r--r--www/webkit-gtk/Makefile.common7
-rw-r--r--www/webkit-gtk/distinfo14
-rw-r--r--www/webkit-gtk/patches/patch-Source_ThirdParty_gtest_include_gtest_internal_gtest-port.h30
-rw-r--r--www/webkit-gtk/patches/patch-Source_WTF_wtf_Atomics.h45
-rw-r--r--www/webkit-gtk/patches/patch-Source_WTF_wtf_RefCountedLeakCounter.h17
-rw-r--r--www/webkit-gtk/patches/patch-Source_WTF_wtf_ThreadSafeRefCounted.h22
-rw-r--r--www/webkit-gtk/patches/patch-Source_WebCore_Modules_webaudio_AudioContext.h13
-rw-r--r--www/webkit-gtk/patches/patch-Source_WebCore_Modules_webaudio_AudioNode.h15
-rw-r--r--www/webkit-gtk/patches/patch-Source_WebCore_platform_gtk_FileSystemGtk.cpp13
-rw-r--r--www/webkit-gtk/patches/patch-Source_WebCore_platform_network_DNSResolveQueue.h13
-rw-r--r--www/webkit-gtk/patches/patch-Source_WebKit2_WebProcess_WebCoreSupport_WebPlatformStrategies.cpp13
-rw-r--r--www/webkit-gtk/patches/patch-Tools_DumpRenderTree_gtk_DumpRenderTree.cpp12
-rw-r--r--www/webkit-gtk/patches/patch-Tools_DumpRenderTree_gtk_ImageDiff.cpp21
13 files changed, 229 insertions, 6 deletions
diff --git a/www/webkit-gtk/Makefile.common b/www/webkit-gtk/Makefile.common
index a85fb0ae1f1..b4b70dc09cc 100644
--- a/www/webkit-gtk/Makefile.common
+++ b/www/webkit-gtk/Makefile.common
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.common,v 1.23 2013/04/10 11:16:39 drochner Exp $
+# $NetBSD: Makefile.common,v 1.24 2013/05/09 14:04:42 joerg Exp $
# used by www/webkit-gtk/Makefile
# used by www/webkit-gtk3/Makefile
@@ -51,6 +51,11 @@ CONFIGURE_ENV+= PYTHON=${PYTHONBIN}
CXXFLAGS.SunOS+= -fpermissive
+.include "../../mk/compiler.mk"
+.if !empty(PKGSRC_COMPILER:Mclang)
+CXXFLAGS+= -std=c++11 -Wno-c++11-narrowing
+.endif
+
BUILDLINK_API_DEPENDS.glib2+= glib2>=2.32.1
.include "../../devel/glib2/buildlink3.mk"
.include "../../devel/zlib/buildlink3.mk"
diff --git a/www/webkit-gtk/distinfo b/www/webkit-gtk/distinfo
index 5827cd03f98..a9a1d5bc8f9 100644
--- a/www/webkit-gtk/distinfo
+++ b/www/webkit-gtk/distinfo
@@ -1,15 +1,25 @@
-$NetBSD: distinfo,v 1.61 2013/04/10 11:16:39 drochner Exp $
+$NetBSD: distinfo,v 1.62 2013/05/09 14:04:42 joerg Exp $
SHA1 (webkitgtk-1.10.2.tar.xz) = 733ca23157eb8dd072d57becf325799c00bde630
RMD160 (webkitgtk-1.10.2.tar.xz) = 91e6b8bcd4bb8234271dd6c6ebdba63dd1c0840e
Size (webkitgtk-1.10.2.tar.xz) = 8633640 bytes
SHA1 (patch-Source_JavaScriptCore_heap_MachineStackMarker.cpp) = c5e1efdac5f6e2a4c035b6a3ce808d0e7a076703
SHA1 (patch-Source_JavaScriptCore_wtf_Threading.h) = f166335d829aba9051c1aaf1b950ec655deef372
-SHA1 (patch-Source_ThirdParty_gtest_include_gtest_internal_gtest-port.h) = 462e62d9078ef90df8cdeccbb64b0d2ccde5f11e
+SHA1 (patch-Source_ThirdParty_gtest_include_gtest_internal_gtest-port.h) = ce9766427bebd4aac0b8c7fc2c12cc0ed75150d5
+SHA1 (patch-Source_WTF_wtf_Atomics.h) = 3cc890798e7e956b75c2a181eca4a4d05cb545fc
SHA1 (patch-Source_WTF_wtf_MathExtras.h) = f922736410d49e7d7d1a459bffd3dffd0364e85a
+SHA1 (patch-Source_WTF_wtf_RefCountedLeakCounter.h) = 3cdf53f9735675bff83b48a81db59c3512f306e3
+SHA1 (patch-Source_WTF_wtf_ThreadSafeRefCounted.h) = c068f8b248b8864eeaa582fa096eca279f06890e
+SHA1 (patch-Source_WebCore_Modules_webaudio_AudioContext.h) = 121b67efd25af6982f02a19d0b9e1e26be89e782
+SHA1 (patch-Source_WebCore_Modules_webaudio_AudioNode.h) = 1d22889087504d8fd42f38f72bde777850a4e767
SHA1 (patch-Source_WebCore_bindings_js_JSInspectorFrontendHostCustom.cpp) = b331ad70a9c6a133c854b65452bad4ae3558e2e6
SHA1 (patch-Source_WebCore_editing_Editor.h) = 43562577dd6432a86fd8ee0a1e7bb0db31f07d2d
+SHA1 (patch-Source_WebCore_platform_gtk_FileSystemGtk.cpp) = 76e6e3e662edcfb7e327f2e475709a105d146e50
+SHA1 (patch-Source_WebCore_platform_network_DNSResolveQueue.h) = ba2960eeda95189a85744112b2533e66599eb4b7
SHA1 (patch-Source_WebCore_platform_sql_SQLiteDatabase.cpp) = 0f33b188b242166584d5725060c5c430a819be61
+SHA1 (patch-Source_WebKit2_WebProcess_WebCoreSupport_WebPlatformStrategies.cpp) = 92f4016fe65fc6162b7f6dfcdc4c6ea2f5204b02
+SHA1 (patch-Tools_DumpRenderTree_gtk_DumpRenderTree.cpp) = 816cecbcb8ddf4af65265f5e76745b93f1055904
+SHA1 (patch-Tools_DumpRenderTree_gtk_ImageDiff.cpp) = 36013247ccbc2df274762acb49304511c06cb0f7
SHA1 (patch-ai) = 8df303ffde5c4398e56601c524e9ab4aff52096c
SHA1 (patch-aj) = 930d1b5d73028b2f2e5abb33c15f72befadc64ce
SHA1 (patch-ak) = 64ad843164f1c12968e933080e0966a9019abfdf
diff --git a/www/webkit-gtk/patches/patch-Source_ThirdParty_gtest_include_gtest_internal_gtest-port.h b/www/webkit-gtk/patches/patch-Source_ThirdParty_gtest_include_gtest_internal_gtest-port.h
index 526dbdb7368..031bf7e0031 100644
--- a/www/webkit-gtk/patches/patch-Source_ThirdParty_gtest_include_gtest_internal_gtest-port.h
+++ b/www/webkit-gtk/patches/patch-Source_ThirdParty_gtest_include_gtest_internal_gtest-port.h
@@ -1,8 +1,16 @@
-$NetBSD: patch-Source_ThirdParty_gtest_include_gtest_internal_gtest-port.h,v 1.1 2012/11/22 18:20:49 marino Exp $
+$NetBSD: patch-Source_ThirdParty_gtest_include_gtest_internal_gtest-port.h,v 1.2 2013/05/09 14:04:42 joerg Exp $
---- Source/ThirdParty/gtest/include/gtest/internal/gtest-port.h.orig 2012-04-22 23:26:47.000000000 +0000
+--- Source/ThirdParty/gtest/include/gtest/internal/gtest-port.h.orig 2012-05-12 19:43:43.000000000 +0000
+++ Source/ThirdParty/gtest/include/gtest/internal/gtest-port.h
-@@ -173,6 +173,7 @@
+@@ -35,6 +35,7 @@
+
+ #ifndef GTEST_INCLUDE_GTEST_INTERNAL_GTEST_PORT_H_
+ #define GTEST_INCLUDE_GTEST_INTERNAL_GTEST_PORT_H_
++#include <ciso646>
+
+ // The user can define the following macros in the build script to
+ // control Google Test's behavior. If the user doesn't define a macro
+@@ -173,6 +174,7 @@
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
@@ -10,3 +18,19 @@ $NetBSD: patch-Source_ThirdParty_gtest_include_gtest_internal_gtest-port.h,v 1.1
#ifndef _WIN32_WCE
#include <sys/stat.h>
#endif // !_WIN32_WCE
+@@ -443,7 +445,14 @@
+ // GCC 4.0+ implements tr1/tuple in the <tr1/tuple> header. This does
+ // not conform to the TR1 spec, which requires the header to be <tuple>.
+
+-#if !GTEST_HAS_RTTI && GTEST_GCC_VER_ < 40302
++#if defined(_LIBCPP_VERSION)
++#include <tuple>
++namespace std {
++ namespace tr1 {
++ using ::std::tuple;
++ }
++}
++#elif !GTEST_HAS_RTTI && GTEST_GCC_VER_ < 40302
+ // Until version 4.3.2, gcc has a bug that causes <tr1/functional>,
+ // which is #included by <tr1/tuple>, to not compile when RTTI is
+ // disabled. _TR1_FUNCTIONAL is the header guard for
diff --git a/www/webkit-gtk/patches/patch-Source_WTF_wtf_Atomics.h b/www/webkit-gtk/patches/patch-Source_WTF_wtf_Atomics.h
new file mode 100644
index 00000000000..bd55b914183
--- /dev/null
+++ b/www/webkit-gtk/patches/patch-Source_WTF_wtf_Atomics.h
@@ -0,0 +1,45 @@
+$NetBSD: patch-Source_WTF_wtf_Atomics.h,v 1.1 2013/05/09 14:04:42 joerg Exp $
+
+--- Source/WTF/wtf/Atomics.h.orig 2012-11-23 20:12:16.000000000 +0000
++++ Source/WTF/wtf/Atomics.h
+@@ -72,7 +72,10 @@
+ #elif OS(ANDROID)
+ #include <sys/atomics.h>
+ #elif COMPILER(GCC)
+-#if ((__GNUC__ > 4) || ((__GNUC__ == 4) && (__GNUC_MINOR__ >= 2))) && !defined(__LSB_VERSION__)
++#include <ciso646>
++#if defined(_LIBCPP_VERSION) || __cplusplus >= 201103L
++#include <atomic>
++#elif ((__GNUC__ > 4) || ((__GNUC__ == 4) && (__GNUC_MINOR__ >= 2))) && !defined(__LSB_VERSION__)
+ #include <ext/atomicity.h>
+ #else
+ #include <bits/atomicity.h>
+@@ -112,6 +115,11 @@ inline int atomicDecrement(int volatile*
+ inline int atomicIncrement(int volatile* addend) { return __atomic_inc(addend) + 1; }
+ inline int atomicDecrement(int volatile* addend) { return __atomic_dec(addend) - 1; }
+
++#elif defined(_LIBCPP_VERSION) || __cplusplus >= 201103L
++#define WTF_USE_LOCKFREE_THREADSAFEREFCOUNTED 1
++inline int atomicIncrement(std::atomic<int> * addend) { return *addend++; }
++inline int atomicDecrement(std::atomic<int> * addend) { return *addend--; }
++
+ #elif COMPILER(GCC) && !CPU(SPARC64) // sizeof(_Atomic_word) != sizeof(int) on sparc64 gcc
+ #define WTF_USE_LOCKFREE_THREADSAFEREFCOUNTED 1
+
+@@ -227,9 +235,16 @@ inline void memoryBarrierBeforeUnlock()
+
+ #endif
+
++#if defined(_LIBCPP_VERSION) || __cplusplus >= 201103L
++typedef std::atomic<int> atomic_int;
++#else
++typedef int volatile atomic_int;
++#endif
++
+ } // namespace WTF
+
+ #if USE(LOCKFREE_THREADSAFEREFCOUNTED)
++using WTF::atomic_int;
+ using WTF::atomicDecrement;
+ using WTF::atomicIncrement;
+ #endif
diff --git a/www/webkit-gtk/patches/patch-Source_WTF_wtf_RefCountedLeakCounter.h b/www/webkit-gtk/patches/patch-Source_WTF_wtf_RefCountedLeakCounter.h
new file mode 100644
index 00000000000..1a6c8183cb1
--- /dev/null
+++ b/www/webkit-gtk/patches/patch-Source_WTF_wtf_RefCountedLeakCounter.h
@@ -0,0 +1,17 @@
+$NetBSD: patch-Source_WTF_wtf_RefCountedLeakCounter.h,v 1.1 2013/05/09 14:04:42 joerg Exp $
+
+--- Source/WTF/wtf/RefCountedLeakCounter.h.orig 2013-05-08 07:48:32.000000000 +0000
++++ Source/WTF/wtf/RefCountedLeakCounter.h
+@@ -38,11 +38,7 @@ namespace WTF {
+
+ #ifndef NDEBUG
+ private:
+-#if COMPILER(MINGW) || COMPILER(MSVC7_OR_LOWER) || OS(WINCE)
+- int m_count;
+-#else
+- volatile int m_count;
+-#endif
++ atomic_int m_count;
+ const char* m_description;
+ #endif
+ };
diff --git a/www/webkit-gtk/patches/patch-Source_WTF_wtf_ThreadSafeRefCounted.h b/www/webkit-gtk/patches/patch-Source_WTF_wtf_ThreadSafeRefCounted.h
new file mode 100644
index 00000000000..c56a6577a47
--- /dev/null
+++ b/www/webkit-gtk/patches/patch-Source_WTF_wtf_ThreadSafeRefCounted.h
@@ -0,0 +1,22 @@
+$NetBSD: patch-Source_WTF_wtf_ThreadSafeRefCounted.h,v 1.1 2013/05/09 14:04:42 joerg Exp $
+
+--- Source/WTF/wtf/ThreadSafeRefCounted.h.orig 2013-05-08 07:46:55.000000000 +0000
++++ Source/WTF/wtf/ThreadSafeRefCounted.h
+@@ -96,7 +96,7 @@ public:
+ #if !USE(LOCKFREE_THREADSAFEREFCOUNTED)
+ MutexLocker locker(m_mutex);
+ #endif
+- return static_cast<int const volatile &>(m_refCount);
++ return m_refCount;
+ }
+
+ protected:
+@@ -123,7 +123,7 @@ protected:
+ }
+
+ private:
+- int m_refCount;
++ atomic_int m_refCount;
+ #if !USE(LOCKFREE_THREADSAFEREFCOUNTED)
+ mutable Mutex m_mutex;
+ #endif
diff --git a/www/webkit-gtk/patches/patch-Source_WebCore_Modules_webaudio_AudioContext.h b/www/webkit-gtk/patches/patch-Source_WebCore_Modules_webaudio_AudioContext.h
new file mode 100644
index 00000000000..9517bfcc937
--- /dev/null
+++ b/www/webkit-gtk/patches/patch-Source_WebCore_Modules_webaudio_AudioContext.h
@@ -0,0 +1,13 @@
+$NetBSD: patch-Source_WebCore_Modules_webaudio_AudioContext.h,v 1.1 2013/05/09 14:04:42 joerg Exp $
+
+--- Source/WebCore/Modules/webaudio/AudioContext.h.orig 2013-05-08 08:53:03.000000000 +0000
++++ Source/WebCore/Modules/webaudio/AudioContext.h
+@@ -333,7 +333,7 @@ private:
+ enum { MaxNumberOfChannels = 32 };
+
+ // Number of AudioBufferSourceNodes that are active (playing).
+- int m_activeSourceCount;
++ atomic_int m_activeSourceCount;
+ };
+
+ } // WebCore
diff --git a/www/webkit-gtk/patches/patch-Source_WebCore_Modules_webaudio_AudioNode.h b/www/webkit-gtk/patches/patch-Source_WebCore_Modules_webaudio_AudioNode.h
new file mode 100644
index 00000000000..515a94769ac
--- /dev/null
+++ b/www/webkit-gtk/patches/patch-Source_WebCore_Modules_webaudio_AudioNode.h
@@ -0,0 +1,15 @@
+$NetBSD: patch-Source_WebCore_Modules_webaudio_AudioNode.h,v 1.1 2013/05/09 14:04:42 joerg Exp $
+
+--- Source/WebCore/Modules/webaudio/AudioNode.h.orig 2013-05-08 08:53:26.000000000 +0000
++++ Source/WebCore/Modules/webaudio/AudioNode.h
+@@ -178,8 +178,8 @@ private:
+ double m_lastNonSilentTime;
+
+ // Ref-counting
+- volatile int m_normalRefCount;
+- volatile int m_connectionRefCount;
++ atomic_int m_normalRefCount;
++ atomic_int m_connectionRefCount;
+
+ bool m_isMarkedForDeletion;
+ bool m_isDisabled;
diff --git a/www/webkit-gtk/patches/patch-Source_WebCore_platform_gtk_FileSystemGtk.cpp b/www/webkit-gtk/patches/patch-Source_WebCore_platform_gtk_FileSystemGtk.cpp
new file mode 100644
index 00000000000..5e571d8dce3
--- /dev/null
+++ b/www/webkit-gtk/patches/patch-Source_WebCore_platform_gtk_FileSystemGtk.cpp
@@ -0,0 +1,13 @@
+$NetBSD: patch-Source_WebCore_platform_gtk_FileSystemGtk.cpp,v 1.1 2013/05/09 14:04:42 joerg Exp $
+
+--- Source/WebCore/platform/gtk/FileSystemGtk.cpp.orig 2012-11-23 20:12:17.000000000 +0000
++++ Source/WebCore/platform/gtk/FileSystemGtk.cpp
+@@ -222,7 +222,7 @@ CString sharedResourcesPath()
+ GOwnPtr<gchar> runtimeDir(g_win32_get_package_installation_directory_of_module(hmodule));
+ GOwnPtr<gchar> dataPath(g_build_filename(runtimeDir.get(), "share", "webkitgtk-"WEBKITGTK_API_VERSION_STRING, NULL));
+ #else
+- GOwnPtr<gchar> dataPath(g_build_filename(DATA_DIR, "webkitgtk-"WEBKITGTK_API_VERSION_STRING, NULL));
++ GOwnPtr<gchar> dataPath(g_build_filename(DATA_DIR, "webkitgtk-" WEBKITGTK_API_VERSION_STRING, NULL));
+ #endif
+
+ cachedPath = dataPath.get();
diff --git a/www/webkit-gtk/patches/patch-Source_WebCore_platform_network_DNSResolveQueue.h b/www/webkit-gtk/patches/patch-Source_WebCore_platform_network_DNSResolveQueue.h
new file mode 100644
index 00000000000..fa43adfae24
--- /dev/null
+++ b/www/webkit-gtk/patches/patch-Source_WebCore_platform_network_DNSResolveQueue.h
@@ -0,0 +1,13 @@
+$NetBSD: patch-Source_WebCore_platform_network_DNSResolveQueue.h,v 1.1 2013/05/09 14:04:42 joerg Exp $
+
+--- Source/WebCore/platform/network/DNSResolveQueue.h.orig 2013-05-08 08:52:14.000000000 +0000
++++ Source/WebCore/platform/network/DNSResolveQueue.h
+@@ -56,7 +56,7 @@ private:
+ void fired();
+
+ HashSet<String> m_names;
+- int m_requestsInFlight;
++ atomic_int m_requestsInFlight;
+ };
+
+ }
diff --git a/www/webkit-gtk/patches/patch-Source_WebKit2_WebProcess_WebCoreSupport_WebPlatformStrategies.cpp b/www/webkit-gtk/patches/patch-Source_WebKit2_WebProcess_WebCoreSupport_WebPlatformStrategies.cpp
new file mode 100644
index 00000000000..802f0e39eff
--- /dev/null
+++ b/www/webkit-gtk/patches/patch-Source_WebKit2_WebProcess_WebCoreSupport_WebPlatformStrategies.cpp
@@ -0,0 +1,13 @@
+$NetBSD: patch-Source_WebKit2_WebProcess_WebCoreSupport_WebPlatformStrategies.cpp,v 1.1 2013/05/09 14:04:42 joerg Exp $
+
+--- Source/WebKit2/WebProcess/WebCoreSupport/WebPlatformStrategies.cpp.orig 2013-05-08 08:54:13.000000000 +0000
++++ Source/WebKit2/WebProcess/WebCoreSupport/WebPlatformStrategies.cpp
+@@ -118,7 +118,7 @@ void handleDidGetPlugins(uint64_t reques
+
+ static uint64_t generateRequestID()
+ {
+- static int uniqueID;
++ static atomic_int uniqueID;
+ return atomicIncrement(&uniqueID);
+ }
+
diff --git a/www/webkit-gtk/patches/patch-Tools_DumpRenderTree_gtk_DumpRenderTree.cpp b/www/webkit-gtk/patches/patch-Tools_DumpRenderTree_gtk_DumpRenderTree.cpp
new file mode 100644
index 00000000000..2ab575dbab5
--- /dev/null
+++ b/www/webkit-gtk/patches/patch-Tools_DumpRenderTree_gtk_DumpRenderTree.cpp
@@ -0,0 +1,12 @@
+$NetBSD: patch-Tools_DumpRenderTree_gtk_DumpRenderTree.cpp,v 1.1 2013/05/09 14:04:42 joerg Exp $
+
+--- Tools/DumpRenderTree/gtk/DumpRenderTree.cpp.orig 2012-11-23 20:12:19.000000000 +0000
++++ Tools/DumpRenderTree/gtk/DumpRenderTree.cpp
+@@ -46,6 +46,7 @@
+ #include "WorkQueueItem.h"
+ #include <JavaScriptCore/JavaScript.h>
+ #include <cassert>
++#include <clocale>
+ #include <cstdlib>
+ #include <cstring>
+ #include <getopt.h>
diff --git a/www/webkit-gtk/patches/patch-Tools_DumpRenderTree_gtk_ImageDiff.cpp b/www/webkit-gtk/patches/patch-Tools_DumpRenderTree_gtk_ImageDiff.cpp
new file mode 100644
index 00000000000..57b4fe232a1
--- /dev/null
+++ b/www/webkit-gtk/patches/patch-Tools_DumpRenderTree_gtk_ImageDiff.cpp
@@ -0,0 +1,21 @@
+$NetBSD: patch-Tools_DumpRenderTree_gtk_ImageDiff.cpp,v 1.1 2013/05/09 14:04:42 joerg Exp $
+
+--- Tools/DumpRenderTree/gtk/ImageDiff.cpp.orig 2013-05-02 21:03:34.000000000 +0000
++++ Tools/DumpRenderTree/gtk/ImageDiff.cpp
+@@ -30,6 +30,7 @@
+ #include <algorithm>
+ #include <cmath>
+ #include <cstdio>
++#include <cstdlib>
+ #include <cstring>
+ #include <gdk/gdk.h>
+
+@@ -157,7 +158,7 @@ void printImage(GdkPixbuf* image)
+ return; // Don't bail out, as we can still use the percentage output.
+ }
+
+- printf("Content-Length: %"G_GSIZE_FORMAT"\n", bufferSize);
++ printf("Content-Length: %" G_GSIZE_FORMAT "\n", bufferSize);
+ fwrite(buffer, 1, bufferSize, stdout);
+ }
+