Bug#947735: qtlocation-opensource-src: Fix build on hurd-i386

2020-01-08 Thread Samuel Thibault
Control: reopen -1

Hello,

Version 5.12.5+dfsg-3 added the build of the mapbox plugin, which has a
portability issue. The attached patch was commited upstream, could you
apply it?
https://github.com/mapbox/mapbox-gl-native/pull/16085

Thanks,
Samuel
commit e4cab3f37fda236339d40a0de291cd75c9b1a51e
Author: Samuel Thibault 
Date:   Sun Dec 29 15:27:58 2019 +0100

[util] fix thread.cpp portability

diff --git a/src/3rdparty/mapbox-gl-native/platform/default/thread.cpp 
b/src/3rdparty/mapbox-gl-native/platform/default/thread.cpp
index 28772d956..58a7c12bc 100644
--- a/src/3rdparty/mapbox-gl-native/platform/default/thread.cpp
+++ b/src/3rdparty/mapbox-gl-native/platform/default/thread.cpp
@@ -12,26 +12,32 @@ namespace platform {
 
 std::string getCurrentThreadName() {
 char name[32] = "unknown";
+#ifdef __linux__
 pthread_getname_np(pthread_self(), name, sizeof(name));
+#endif
 
 return name;
 }
 
 void setCurrentThreadName(const std::string& name) {
+#ifdef __linux__
 if (name.size() > 15) { // Linux hard limit (see manpages).
 pthread_setname_np(pthread_self(), name.substr(0, 15).c_str());
 } else {
 pthread_setname_np(pthread_self(), name.c_str());
 }
+#endif
 }
 
 void makeThreadLowPriority() {
+#ifdef SCHED_IDLE
 struct sched_param param;
 param.sched_priority = 0;
 
 if (sched_setscheduler(0, SCHED_IDLE, ) != 0) {
 Log::Warning(Event::General, "Couldn't set thread scheduling policy");
 }
+#endif
 }
 
 } // namespace platform


Bug#947735: qtlocation-opensource-src: Fix build on hurd-i386

2019-12-29 Thread Samuel Thibault
Source: qtlocation-opensource-src
Version: 5.12.5+dfsg-2
Severity: important
Tags: patch
User: debian-h...@lists.debian.org
Usertags: hurd

Hello,

qtlocation-opensource-src currently can't build on hurd-i386 because it
does not enable the geoclue modules. The attach patch fixes this.

Samuel

-- System Information:
Debian Release: bullseye/sid
  APT prefers testing
  APT policy: (990, 'testing'), (500, 'unstable-debug'), (500, 
'testing-debug'), (500, 'stable-debug'), (500, 'proposed-updates-debug'), (500, 
'proposed-updates'), (500, 'oldstable-proposed-updates-debug'), (500, 
'oldstable-proposed-updates'), (500, 'oldoldstable'), (500, 'buildd-unstable'), 
(500, 'unstable'), (500, 'stable'), (500, 'oldstable'), (1, 
'experimental-debug'), (1, 'buildd-experimental'), (1, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 5.4.0 (SMP w/8 CPU cores)
Kernel taint flags: TAINT_OOT_MODULE
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8), 
LANGUAGE=fr_FR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

-- 
Samuel
c> [ ] morning [ ] afternoon [ ] evening [ ] night , everyone (choose as 
applicable)
Index: qtlocation-opensource-src-5.12.5+dfsg/src/plugins/position/position.pro
===
--- qtlocation-opensource-src-5.12.5+dfsg.orig/src/plugins/position/position.pro
+++ qtlocation-opensource-src-5.12.5+dfsg/src/plugins/position/position.pro
@@ -2,8 +2,8 @@ TEMPLATE = subdirs
 
 QT_FOR_CONFIG += positioning-private
 
-linux|freebsd|openbsd|netbsd:qtHaveModule(dbus):SUBDIRS += geoclue
-linux|freebsd|openbsd|netbsd:qtHaveModule(dbus):SUBDIRS += geoclue2
+linux|freebsd|openbsd|netbsd|hurd:qtHaveModule(dbus):SUBDIRS += geoclue
+linux|freebsd|openbsd|netbsd|hurd:qtHaveModule(dbus):SUBDIRS += geoclue2
 qtConfig(gypsy):SUBDIRS += gypsy
 qtConfig(winrt_geolocation):SUBDIRS += winrt
 qtHaveModule(simulator):SUBDIRS += simulator