Most likely due to missed #include <pthread_np.h>. https://kib.kiev.ua/poudriere/data/tom_poudriere_11-head/2019-06-14_03h40m08s/logs/errors/chromium-75.0.3770.80.log
Created attachment 205061 [details] patch Hi Konstantine, Please, apply the patch and try to build again. Thanks for reporting!
*** Bug 238564 has been marked as a duplicate of this bug. ***
(In reply to Carlos J. Puga Medina from comment #1) No, the patch does not help, and the error is same. As I said, you need pthread_np.h https://kib.kiev.ua/poudriere/data/tom_poudriere_11-head/2019-06-14_21h11m56s/logs/chromium-75.0.3770.80.log
(In reply to Konstantin Belousov from comment #3) pthread_get_name_np is supported on 11.2-STABLE. It's added in base/sampling_heap_profiler/sampling_heap_profiler.cc --- base/sampling_heap_profiler/sampling_heap_profiler.cc.orig 2019-06-04 18:55:15 UTC +++ base/sampling_heap_profiler/sampling_heap_profiler.cc @@ -30,6 +30,10 @@ #include <sys/prctl.h> #endif +#if defined(OS_BSD) +#include <pthread_np.h> +#endif + #if defined(OS_ANDROID) && BUILDFLAG(CAN_UNWIND_WITH_CFI_TABLE) && \ defined(OFFICIAL_BUILD) #include "base/trace_event/cfi_backtrace_android.h" @@ -65,6 +69,10 @@ const char* GetAndLeakThreadName() { #elif defined(OS_MACOSX) int err = pthread_getname_np(pthread_self(), name, kBufferLen); if (err == 0 && *name != '\0') + return strdup(name); +#elif defined(OS_BSD) + pthread_get_name_np(pthread_self(), name, kBufferLen); + if (*name != '\0') return strdup(name); #endif // defined(OS_LINUX) || defined(OS_ANDROID) We're working to unbreak chromium on 11.2-RELEASE.
Created attachment 205064 [details] patch Let's take advantage of pthread_get_name_np() only if it's available. Firefox applies the same solution.
Comment on attachment 205064 [details] patch - pthread_get_name_np isn't available on DragonFly yet while NetBSD uses glibc prototype - Firefox defines HAVE_PTHREAD_GET_NAME_NP via AC_CHECK_FUNCS but Chromium does not
A commit references this bug: Author: cpm Date: Sun Jun 16 02:17:03 UTC 2019 New revision: 504272 URL: https://svnweb.freebsd.org/changeset/ports/504272 Log: www/chromium: Unbreak build on < 11.3 In file included from gen/base/base_jumbo_17.cc:8: ./../../base/sampling_heap_profiler/sampling_heap_profiler.cc:74:3: error: use of undeclared identifier 'pthread_get_name_np' pthread_get_name_np(pthread_self(), name, kBufferLen); ^ PR: 238563 Reported by: kib@ Changes: head/www/chromium/files/patch-base_sampling__heap__profiler_sampling__heap__profiler.cc