Bug#902100: webkit2gtk: Please update patch fix-ftbfs-m68k.patch
Geert Uytterhoeven
geert at linux-m68k.org
Fri Jun 22 09:44:08 BST 2018
Hi Adrian,
On Fri, Jun 22, 2018 at 10:21 AM John Paul Adrian Glaubitz
<glaubitz at physik.fu-berlin.de> wrote:
> Source: webkit2gtk
> Version: 2.20.3-1
> Severity: normal
> Tags: patch
> User: debian-68k at lists.debian.org
> Usertags: m68k
>
> Hello!
>
> The patch fix-ftbfs-m68k.patch needs to be updated to fix the FTBFS
> of webkit2gtk on m68k. I have done that, could you apply the attached
> patch for the next upload?
Thanks for your patch!
> --- webkit2gtk-2.20.3.orig/Source/WTF/wtf/Platform.h
> +++ webkit2gtk-2.20.3/Source/WTF/wtf/Platform.h
> @@ -59,6 +59,11 @@
> /* ==== CPU() - the target CPU architecture ==== */
> /* CPU(KNOWN) becomes true if we explicitly support a target CPU. */
>
> +/* CPU(M68K) - m68k */
> +#if defined(__m68k__)
> +#define WTF_CPU_BIG_ENDIAN 1
#define WTF_CPU_KNOWN 1
The others do that, too, but nothing seems to rely on that.
> +#endif
> --- webkit2gtk-2.20.3.orig/Source/WebCore/css/CSSProperty.cpp
> +++ webkit2gtk-2.20.3/Source/WebCore/css/CSSProperty.cpp
> @@ -33,7 +33,11 @@ struct SameSizeAsCSSProperty {
> void* value;
> };
>
> +#if defined(__m68k__)
> +COMPILE_ASSERT(sizeof(CSSProperty) <= sizeof(SameSizeAsCSSProperty), CSSProperty_should_stay_small);
> +#else
> COMPILE_ASSERT(sizeof(CSSProperty) == sizeof(SameSizeAsCSSProperty), CSSProperty_should_stay_small);
> +#endif
These two structures are not equivalent!
If anything assumes so, it will crash when dereferencing the pointer.
The patch below makes them match:
--- webkitgtk-2.20.3/Source/WebCore/css/CSSProperty.cpp.orig
2018-06-22 10:40:49.389060321 +0200
+++ webkitgtk-2.20.3/Source/WebCore/css/CSSProperty.cpp 2018-06-22
10:40:52.681053717 +0200
@@ -29,7 +29,7 @@
namespace WebCore {
struct SameSizeAsCSSProperty {
- uint32_t bitfields;
+ uint16_t bitfields;
void* value;
};
If anything relies on having a hole in between the two fields, explicit
padding should be added.
Haven't checked the rest.
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert at linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
More information about the Pkg-webkit-maintainers
mailing list