Date: Mon, 11 Sep 2017 14:30:26 +0000 (UTC) From: Jan Beich <jbeich@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r449649 - in head/www: webkit-gtk2 webkit-gtk2/files webkit-gtk3 webkit-gtk3/files Message-ID: <201709111430.v8BEUQ9R067768@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: jbeich Date: Mon Sep 11 14:30:25 2017 New Revision: 449649 URL: https://svnweb.freebsd.org/changeset/ports/449649 Log: www/webkit-gtk*: unbreak with ICU 59.1 Source/JavaScriptCore/API/JSStringRef.cpp:40:12: error: no matching function for call to 'create' return OpaqueJSString::create(chars, numChars).leakRef(); ^~~~~~~~~~~~~~~~~~~~~~ ./Source/JavaScriptCore/API/OpaqueJSString.h:44:39: note: candidate function not viable: no known conversion from 'const JSChar *' (aka 'const unsigned short *') to 'const LChar *' (aka 'const unsigned char *') for 1st argument static PassRefPtr<OpaqueJSString> create(const LChar* characters, unsigned length) ^ ./Source/JavaScriptCore/API/OpaqueJSString.h:49:39: note: candidate function not viable: no known conversion from 'const JSChar *' (aka 'const unsigned short *') to 'const UChar *' (aka 'const char16_t *') for 1st argument static PassRefPtr<OpaqueJSString> create(const UChar* characters, unsigned length) ^ ./Source/JavaScriptCore/API/OpaqueJSString.h:39:39: note: candidate function not viable: requires 0 arguments, but 2 were provided static PassRefPtr<OpaqueJSString> create() ^ ./Source/JavaScriptCore/API/OpaqueJSString.h:54:57: note: candidate function not viable: requires 1 argument, but 2 were provided JS_EXPORT_PRIVATE static PassRefPtr<OpaqueJSString> create(const String&); ^ Source/JavaScriptCore/API/JSStringRef.cpp:65:35: error: no matching function for call to 'createWithoutCopying' return OpaqueJSString::create(StringImpl::createWithoutCopying(chars, numChars)).leakRef(); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ./Source/WTF/wtf/text/StringImpl.h:393:54: note: candidate function not viable: no known conversion from 'const JSChar *' (aka 'const unsigned short *') to 'const UChar *' (aka 'const char16_t *') for 1st argument WTF_EXPORT_STRING_API static PassRef<StringImpl> createWithoutCopying(const UChar* characters, unsigned length); ^ ./Source/WTF/wtf/text/StringImpl.h:394:54: note: candidate function not viable: no known conversion from 'const JSChar *' (aka 'const unsigned short *') to 'const LChar *' (aka 'const unsigned char *') for 1st argument WTF_EXPORT_STRING_API static PassRef<StringImpl> createWithoutCopying(const LChar* characters, unsigned length); ^ Source/JavaScriptCore/API/JSStringRef.cpp:86:12: error: cannot initialize return object of type 'const JSChar *' (aka 'const unsigned short *') with an rvalue of type 'const UChar *' (aka 'const char16_t *') return string->characters(); ^~~~~~~~~~~~~~~~~~~~ PR: 218788 Obtained from: upstream (rebased) Added: head/www/webkit-gtk2/files/patch-icu59 (contents, props changed) head/www/webkit-gtk3/files/patch-icu59 (contents, props changed) Modified: head/www/webkit-gtk2/Makefile (contents, props changed) head/www/webkit-gtk3/Makefile (contents, props changed) Modified: head/www/webkit-gtk2/Makefile ============================================================================== --- head/www/webkit-gtk2/Makefile Mon Sep 11 14:30:17 2017 (r449648) +++ head/www/webkit-gtk2/Makefile Mon Sep 11 14:30:25 2017 (r449649) @@ -3,7 +3,7 @@ PORTNAME= webkit PORTVERSION= 2.4.11 -PORTREVISION= 11 +PORTREVISION= 12 CATEGORIES= www MASTER_SITES= http://webkitgtk.org/releases/ PKGNAMESUFFIX= -gtk2 Added: head/www/webkit-gtk2/files/patch-icu59 ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/www/webkit-gtk2/files/patch-icu59 Mon Sep 11 14:30:25 2017 (r449649) @@ -0,0 +1,64 @@ +------------------------------------------------------------------------ +r216187 | annulen@yandex.ru | 2017-05-05 00:33:41 +0900 (Fri, 05 May 2017) | 28 lines + +Fix compilation with ICU 59.1 +https://bugs.webkit.org/show_bug.cgi?id=171612 + +Reviewed by Mark Lam. + +ICU 59.1 has broken source compatibility. Now it defines UChar as +char16_t, which does not allow automatic type conversion from unsigned +short in C++ code. + +--- Source/JavaScriptCore/API/JSStringRef.cpp.orig 2016-04-10 06:48:36 UTC ++++ Source/JavaScriptCore/API/JSStringRef.cpp +@@ -37,7 +37,7 @@ using namespace WTF::Unicode; + JSStringRef JSStringCreateWithCharacters(const JSChar* chars, size_t numChars) + { + initializeThreading(); +- return OpaqueJSString::create(chars, numChars).leakRef(); ++ return OpaqueJSString::create(reinterpret_cast<const UChar*>(chars), numChars).leakRef(); + } + + JSStringRef JSStringCreateWithUTF8CString(const char* string) +@@ -62,7 +62,7 @@ JSStringRef JSStringCreateWithUTF8CString(const char* + JSStringRef JSStringCreateWithCharactersNoCopy(const JSChar* chars, size_t numChars) + { + initializeThreading(); +- return OpaqueJSString::create(StringImpl::createWithoutCopying(chars, numChars)).leakRef(); ++ return OpaqueJSString::create(StringImpl::createWithoutCopying(reinterpret_cast<const UChar*>(chars), numChars)).leakRef(); + } + + JSStringRef JSStringRetain(JSStringRef string) +@@ -83,7 +83,7 @@ size_t JSStringGetLength(JSStringRef string) + + const JSChar* JSStringGetCharactersPtr(JSStringRef string) + { +- return string->characters(); ++ return reinterpret_cast<const JSChar*>(string->characters()); + } + + size_t JSStringGetMaximumUTF8CStringSize(JSStringRef string) +--- Source/JavaScriptCore/runtime/DateConversion.cpp.orig 2013-08-03 16:10:38 UTC ++++ Source/JavaScriptCore/runtime/DateConversion.cpp +@@ -107,7 +107,8 @@ String formatDateTime(const GregorianDateTime& t, Date + #if OS(WINDOWS) + TIME_ZONE_INFORMATION timeZoneInformation; + GetTimeZoneInformation(&timeZoneInformation); +- const WCHAR* timeZoneName = t.isDST() ? timeZoneInformation.DaylightName : timeZoneInformation.StandardName; ++ const WCHAR* winTimeZoneName = t.isDST() ? timeZoneInformation.DaylightName : timeZoneInformation.StandardName; ++ String timeZoneName(reinterpret_cast<const UChar*>(winTimeZoneName)); + #else + struct tm gtm = t; + char timeZoneName[70]; +--- Source/WebKit2/Shared/API/c/WKString.cpp.orig 2016-04-10 06:48:37 UTC ++++ Source/WebKit2/Shared/API/c/WKString.cpp +@@ -55,7 +55,7 @@ size_t WKStringGetLength(WKStringRef stringRef) + size_t WKStringGetCharacters(WKStringRef stringRef, WKChar* buffer, size_t bufferLength) + { + COMPILE_ASSERT(sizeof(WKChar) == sizeof(UChar), WKStringGetCharacters_sizeof_WKChar_matches_UChar); +- return (toImpl(stringRef)->getCharacters(static_cast<UChar*>(buffer), bufferLength)); ++ return (toImpl(stringRef)->getCharacters(reinterpret_cast<UChar*>(buffer), bufferLength)); + } + + size_t WKStringGetMaximumUTF8CStringSize(WKStringRef stringRef) Modified: head/www/webkit-gtk3/Makefile ============================================================================== --- head/www/webkit-gtk3/Makefile Mon Sep 11 14:30:17 2017 (r449648) +++ head/www/webkit-gtk3/Makefile Mon Sep 11 14:30:25 2017 (r449649) @@ -3,7 +3,7 @@ PORTNAME= webkit PORTVERSION= 2.4.11 -PORTREVISION= 10 +PORTREVISION= 11 CATEGORIES= www MASTER_SITES= http://webkitgtk.org/releases/ PKGNAMESUFFIX= -gtk3 Added: head/www/webkit-gtk3/files/patch-icu59 ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/www/webkit-gtk3/files/patch-icu59 Mon Sep 11 14:30:25 2017 (r449649) @@ -0,0 +1,64 @@ +------------------------------------------------------------------------ +r216187 | annulen@yandex.ru | 2017-05-05 00:33:41 +0900 (Fri, 05 May 2017) | 28 lines + +Fix compilation with ICU 59.1 +https://bugs.webkit.org/show_bug.cgi?id=171612 + +Reviewed by Mark Lam. + +ICU 59.1 has broken source compatibility. Now it defines UChar as +char16_t, which does not allow automatic type conversion from unsigned +short in C++ code. + +--- Source/JavaScriptCore/API/JSStringRef.cpp.orig 2016-04-10 06:48:36 UTC ++++ Source/JavaScriptCore/API/JSStringRef.cpp +@@ -37,7 +37,7 @@ using namespace WTF::Unicode; + JSStringRef JSStringCreateWithCharacters(const JSChar* chars, size_t numChars) + { + initializeThreading(); +- return OpaqueJSString::create(chars, numChars).leakRef(); ++ return OpaqueJSString::create(reinterpret_cast<const UChar*>(chars), numChars).leakRef(); + } + + JSStringRef JSStringCreateWithUTF8CString(const char* string) +@@ -62,7 +62,7 @@ JSStringRef JSStringCreateWithUTF8CString(const char* + JSStringRef JSStringCreateWithCharactersNoCopy(const JSChar* chars, size_t numChars) + { + initializeThreading(); +- return OpaqueJSString::create(StringImpl::createWithoutCopying(chars, numChars)).leakRef(); ++ return OpaqueJSString::create(StringImpl::createWithoutCopying(reinterpret_cast<const UChar*>(chars), numChars)).leakRef(); + } + + JSStringRef JSStringRetain(JSStringRef string) +@@ -83,7 +83,7 @@ size_t JSStringGetLength(JSStringRef string) + + const JSChar* JSStringGetCharactersPtr(JSStringRef string) + { +- return string->characters(); ++ return reinterpret_cast<const JSChar*>(string->characters()); + } + + size_t JSStringGetMaximumUTF8CStringSize(JSStringRef string) +--- Source/JavaScriptCore/runtime/DateConversion.cpp.orig 2013-08-03 16:10:38 UTC ++++ Source/JavaScriptCore/runtime/DateConversion.cpp +@@ -107,7 +107,8 @@ String formatDateTime(const GregorianDateTime& t, Date + #if OS(WINDOWS) + TIME_ZONE_INFORMATION timeZoneInformation; + GetTimeZoneInformation(&timeZoneInformation); +- const WCHAR* timeZoneName = t.isDST() ? timeZoneInformation.DaylightName : timeZoneInformation.StandardName; ++ const WCHAR* winTimeZoneName = t.isDST() ? timeZoneInformation.DaylightName : timeZoneInformation.StandardName; ++ String timeZoneName(reinterpret_cast<const UChar*>(winTimeZoneName)); + #else + struct tm gtm = t; + char timeZoneName[70]; +--- Source/WebKit2/Shared/API/c/WKString.cpp.orig 2016-04-10 06:48:37 UTC ++++ Source/WebKit2/Shared/API/c/WKString.cpp +@@ -55,7 +55,7 @@ size_t WKStringGetLength(WKStringRef stringRef) + size_t WKStringGetCharacters(WKStringRef stringRef, WKChar* buffer, size_t bufferLength) + { + COMPILE_ASSERT(sizeof(WKChar) == sizeof(UChar), WKStringGetCharacters_sizeof_WKChar_matches_UChar); +- return (toImpl(stringRef)->getCharacters(static_cast<UChar*>(buffer), bufferLength)); ++ return (toImpl(stringRef)->getCharacters(reinterpret_cast<UChar*>(buffer), bufferLength)); + } + + size_t WKStringGetMaximumUTF8CStringSize(WKStringRef stringRef)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201709111430.v8BEUQ9R067768>