Bug#978098: webkit2gtk: Re-enable build for hurd-i386?
Laurent Bigonville
bigon at debian.org
Fri Dec 25 22:15:54 GMT 2020
Source: webkit2gtk
Version: 2.30.4-1
Severity: wishlist
Tags: patch
X-Debbugs-Cc: debian-hurd at lists.debian.org
Hello,
It seems that the porters have a patch that is allowing webkit to build
on hurd-i386
Shouldn't the patch be applied in "official" package as well (and maybe
upstream)?
Kind regards,
Laurent Bigonville
-- System Information:
Debian Release: bullseye/sid
APT prefers unstable-debug
APT policy: (500, 'unstable-debug'), (500, 'unstable'), (1, 'experimental-debug'), (1, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386
Kernel: Linux 5.9.0-5-amd64 (SMP w/4 CPU threads)
Kernel taint flags: TAINT_FIRMWARE_WORKAROUND
Locale: LANG=fr_BE.UTF-8, LC_CTYPE=fr_BE.UTF-8 (charmap=UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: SELinux: enabled - Mode: Permissive - Policy name: refpolicy
-------------- next part --------------
diff -Nru webkit2gtk-2.30.3/debian/changelog webkit2gtk-2.30.3/debian/changelog
--- webkit2gtk-2.30.3/debian/changelog 2020-11-20 15:24:07.000000000 +0100
+++ webkit2gtk-2.30.3/debian/changelog 2020-12-05 18:54:19.000000000 +0100
@@ -1,3 +1,13 @@
+webkit2gtk (2.30.3-1+hurd.1) unreleased; urgency=medium
+
+ * fix-ftbfs-hurd.patch: Fix linuxisms.
+ * control: Disable bubblewrap, xdg-dbus-proxy, libseccomp-dev,
+ libwpebackend-fdo-1.0-dev build-deps on hurd-any. Enable libsystemd-dev on
+ linux-any only. Enable building packages on hurd-any.
+ * rules: Pass -DUSE_SYSTEMD=OFF on !linux.
+
+ -- Samuel Thibault <sthibault at debian.org> Sat, 05 Dec 2020 17:54:19 +0000
+
webkit2gtk (2.30.3-1) unstable; urgency=high
* New upstream release
diff -Nru webkit2gtk-2.30.3/debian/control webkit2gtk-2.30.3/debian/control
--- webkit2gtk-2.30.3/debian/control 2020-11-20 15:24:07.000000000 +0100
+++ webkit2gtk-2.30.3/debian/control 2020-12-05 13:31:51.000000000 +0100
@@ -7,9 +7,9 @@
Alberto Garcia <berto at igalia.com>
X-Ubuntu-Use-Langpack: no
Build-Depends: gawk,
- bubblewrap (>= 0.3.1) [!alpha !ia64 !m68k !riscv64 !sh4 !sparc64],
- xdg-dbus-proxy [!alpha !ia64 !m68k !riscv64 !sh4 !sparc64],
- libseccomp-dev [!alpha !ia64 !m68k !riscv64 !sh4 !sparc64],
+ bubblewrap (>= 0.3.1) [!alpha !ia64 !m68k !riscv64 !sh4 !sparc64 !hurd-any],
+ xdg-dbus-proxy [!alpha !ia64 !m68k !riscv64 !sh4 !sparc64 !hurd-any],
+ libseccomp-dev [!alpha !ia64 !m68k !riscv64 !sh4 !sparc64 !hurd-any],
cmake (>= 3.3),
debhelper (>= 11.2~),
jdupes,
@@ -30,11 +30,11 @@
libxml2-dev (>= 2.8),
libsoup2.4-dev (>= 2.42.0),
libsqlite3-dev (>= 3.0),
- libsystemd-dev,
+ libsystemd-dev [linux-any],
libgudev-1.0-dev [linux-any],
libupower-glib-dev,
libwoff-dev (>= 1.0.2),
- libwpebackend-fdo-1.0-dev,
+ libwpebackend-fdo-1.0-dev [!hurd-any],
gperf,
bison,
flex,
@@ -70,7 +70,7 @@
Package: libjavascriptcoregtk-4.0-18
Section: libs
-Architecture: linux-any
+Architecture: linux-any hurd-any
Multi-Arch: same
Pre-Depends: ${misc:Pre-Depends}
Depends: ${shlibs:Depends},
@@ -87,7 +87,7 @@
Package: libjavascriptcoregtk-4.0-dev
Section: libdevel
-Architecture: linux-any
+Architecture: linux-any hurd-any
Multi-Arch: same
Depends: libjavascriptcoregtk-4.0-18 (= ${binary:Version}),
gir1.2-javascriptcoregtk-4.0 (= ${binary:Version}),
@@ -104,7 +104,7 @@
Package: libjavascriptcoregtk-4.0-bin
Section: interpreters
-Architecture: linux-any
+Architecture: linux-any hurd-any
Pre-Depends: ${misc:Pre-Depends}
Depends: ${shlibs:Depends},
${misc:Depends}
@@ -121,7 +121,7 @@
Package: gir1.2-javascriptcoregtk-4.0
Section: introspection
-Architecture: linux-any
+Architecture: linux-any hurd-any
Multi-Arch: same
Depends: ${gir:Depends},
${misc:Depends}
@@ -139,7 +139,7 @@
Package: libwebkit2gtk-4.0-37
Section: libs
-Architecture: linux-any
+Architecture: linux-any hurd-any
Multi-Arch: same
Pre-Depends: ${misc:Pre-Depends}
Depends: libjavascriptcoregtk-4.0-18 (= ${binary:Version}),
@@ -171,7 +171,7 @@
Package: libwebkit2gtk-4.0-dev
Section: libdevel
-Architecture: linux-any
+Architecture: linux-any hurd-any
Multi-Arch: same
Depends: libwebkit2gtk-4.0-37 (= ${binary:Version}),
gir1.2-webkit2-4.0 (= ${binary:Version}),
@@ -220,7 +220,7 @@
Package: gir1.2-webkit2-4.0
Section: introspection
-Architecture: linux-any
+Architecture: linux-any hurd-any
Multi-Arch: same
Depends: gir1.2-javascriptcoregtk-4.0 (= ${binary:Version}),
${gir:Depends},
@@ -256,7 +256,7 @@
browser-plugin-freshplayer-pepperflash.
Package: webkit2gtk-driver
-Architecture: linux-any
+Architecture: linux-any hurd-any
Pre-Depends: ${misc:Pre-Depends}
Depends: libwebkit2gtk-4.0-37 (= ${binary:Version}),
${shlibs:Depends},
diff -Nru webkit2gtk-2.30.3/debian/patches/fix-ftbfs-hurd.patch webkit2gtk-2.30.3/debian/patches/fix-ftbfs-hurd.patch
--- webkit2gtk-2.30.3/debian/patches/fix-ftbfs-hurd.patch 1970-01-01 01:00:00.000000000 +0100
+++ webkit2gtk-2.30.3/debian/patches/fix-ftbfs-hurd.patch 2020-12-05 18:54:19.000000000 +0100
@@ -0,0 +1,77 @@
+https://bugs.webkit.org/show_bug.cgi?id=219570
+https://bugs.webkit.org/show_bug.cgi?id=219571
+https://bugs.webkit.org/show_bug.cgi?id=219572
+
+Index: webkit2gtk-2.30.3/Source/WTF/wtf/RAMSize.cpp
+===================================================================
+--- webkit2gtk-2.30.3.orig/Source/WTF/wtf/RAMSize.cpp
++++ webkit2gtk-2.30.3/Source/WTF/wtf/RAMSize.cpp
+@@ -33,7 +33,9 @@
+ #elif defined(USE_SYSTEM_MALLOC) && USE_SYSTEM_MALLOC
+ #if OS(LINUX)
+ #include <sys/sysinfo.h>
+-#endif // OS(LINUX)
++#elif OS(UNIX)
++#include <unistd.h>
++#endif // OS(LINUX) || OS(UNIX)
+ #else
+ #include <bmalloc/bmalloc.h>
+ #endif
+@@ -58,9 +60,13 @@ static size_t computeRAMSize()
+ struct sysinfo si;
+ sysinfo(&si);
+ return si.totalram * si.mem_unit;
++#elif OS(UNIX)
++ long pages = sysconf(_SC_PHYS_PAGES);
++ long pageSize = sysconf(_SC_PAGE_SIZE);
++ return pages * pageSize;
+ #else
+ #error "Missing a platform specific way of determining the available RAM"
+-#endif // OS(LINUX) || OS(FREEBSD)
++#endif // OS(LINUX) || OS(FREEBSD) || OS(UNIX)
+ #else
+ return bmalloc::api::availableMemory();
+ #endif
+Index: webkit2gtk-2.30.3/Source/JavaScriptCore/runtime/ConfigFile.h
+===================================================================
+--- webkit2gtk-2.30.3.orig/Source/JavaScriptCore/runtime/ConfigFile.h
++++ webkit2gtk-2.30.3/Source/JavaScriptCore/runtime/ConfigFile.h
+@@ -42,8 +42,10 @@ private:
+
+ #if OS(WINDOWS)
+ static const size_t s_maxPathLength = 260; // Windows value for "MAX_PATH"
+-#else
++#elif defined(PATH_MAX)
+ static const size_t s_maxPathLength = PATH_MAX;
++#else
++ static const size_t s_maxPathLength = 4095;
+ #endif
+
+ static char s_processName[];
+Index: webkit2gtk-2.30.3/Source/WebCore/platform/text/hyphen/HyphenationLibHyphen.cpp
+===================================================================
+--- webkit2gtk-2.30.3.orig/Source/WebCore/platform/text/hyphen/HyphenationLibHyphen.cpp
++++ webkit2gtk-2.30.3/Source/WebCore/platform/text/hyphen/HyphenationLibHyphen.cpp
+@@ -67,11 +67,22 @@ static void scanDirectoryForDictionaries
+ for (auto& filePath : FileSystem::listDirectory(directoryPath, "hyph_*.dic")) {
+ String locale = extractLocaleFromDictionaryFilePath(filePath).convertToASCIILowercase();
+
++#if _POSIX_VERSION >= 200112
++ char *normalizedPath;
++ normalizedPath = realpath(FileSystem::fileSystemRepresentation(filePath).data(), NULL);
++ if (!normalizedPath)
++ continue;
++
++ filePath = FileSystem::stringFromFileSystemRepresentation(normalizedPath);
++ free(normalizedPath);
++#else
+ char normalizedPath[PATH_MAX];
+ if (!realpath(FileSystem::fileSystemRepresentation(filePath).data(), normalizedPath))
+ continue;
+
+ filePath = FileSystem::stringFromFileSystemRepresentation(normalizedPath);
++#endif
++
+ availableLocales.add(locale, Vector<String>()).iterator->value.append(filePath);
+
+ String localeReplacingUnderscores = String(locale);
diff -Nru webkit2gtk-2.30.3/debian/patches/series webkit2gtk-2.30.3/debian/patches/series
--- webkit2gtk-2.30.3/debian/patches/series 2020-11-20 15:24:07.000000000 +0100
+++ webkit2gtk-2.30.3/debian/patches/series 2020-12-05 18:54:19.000000000 +0100
@@ -5,3 +5,4 @@
prefer-pthread.patch
dont-detect-sse2.patch
reduce-memory-overheads.patch
+fix-ftbfs-hurd.patch
diff -Nru webkit2gtk-2.30.3/debian/rules webkit2gtk-2.30.3/debian/rules
--- webkit2gtk-2.30.3/debian/rules 2020-11-20 15:24:07.000000000 +0100
+++ webkit2gtk-2.30.3/debian/rules 2020-12-05 13:44:15.000000000 +0100
@@ -24,6 +24,11 @@
EXTRA_CMAKE_ARGUMENTS += -DENABLE_JIT=OFF -DENABLE_C_LOOP=ON
endif
+# Systemd is Linux-only
+ifneq ($(DEB_HOST_ARCH_OS),linux)
+ EXTRA_CMAKE_ARGUMENTS += -DUSE_SYSTEMD=OFF
+endif
+
# See https://bugs.webkit.org/show_bug.cgi?id=197192
ifneq (,$(filter $(DEB_HOST_ARCH),arm64))
EXTRA_CMAKE_ARGUMENTS += -DWTF_CPU_ARM64_CORTEXA53=OFF
More information about the Pkg-webkit-maintainers
mailing list