From nobody Mon Oct 04 20:49:04 2021 X-Original-To: dev-commits-ports-branches@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 0336310FD207; Mon, 4 Oct 2021 20:49:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4HNXrJ6fgVz4jSd; Mon, 4 Oct 2021 20:49:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id C440F1FB73; Mon, 4 Oct 2021 20:49:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 194Kn4N6072648; Mon, 4 Oct 2021 20:49:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 194Kn4LN072647; Mon, 4 Oct 2021 20:49:04 GMT (envelope-from git) Date: Mon, 4 Oct 2021 20:49:04 GMT Message-Id: <202110042049.194Kn4LN072647@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-branches@FreeBSD.org From: Jan Beich Subject: git: f331c5d651fc - 2021Q4 - cad/PrusaSlicer: unbreak build after 620968a43a5f List-Id: Commits to the quarterly branches of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-branches@freebsd.org X-BeenThere: dev-commits-ports-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jbeich X-Git-Repository: ports X-Git-Refname: refs/heads/2021Q4 X-Git-Reftype: branch X-Git-Commit: f331c5d651fc3d0348b6857b92497bb1a790a522 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch 2021Q4 has been updated by jbeich: URL: https://cgit.FreeBSD.org/ports/commit/?id=f331c5d651fc3d0348b6857b92497bb1a790a522 commit f331c5d651fc3d0348b6857b92497bb1a790a522 Author: Jan Beich AuthorDate: 2021-10-04 20:42:59 +0000 Commit: Jan Beich CommitDate: 2021-10-04 20:48:52 +0000 cad/PrusaSlicer: unbreak build after 620968a43a5f Restore the patch accidentally removed due to an out of date comment. 8a4af427075f removed pthread_setname_np references. src/libslic3r/Thread.cpp:13:10: fatal error: 'tbb/tbb_thread.h' file not found #include ^~~~~~~~~~~~~~~~~~ (cherry picked from commit 6e6ff7d6ab173ab893715f7a0a9b2a57b3a15b7f) --- .../files/patch-src_libslic3r_Thread.cpp | 41 ++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/cad/PrusaSlicer/files/patch-src_libslic3r_Thread.cpp b/cad/PrusaSlicer/files/patch-src_libslic3r_Thread.cpp new file mode 100644 index 000000000000..32ff24bbfd77 --- /dev/null +++ b/cad/PrusaSlicer/files/patch-src_libslic3r_Thread.cpp @@ -0,0 +1,41 @@ +--- src/libslic3r/Thread.cpp.orig 2021-07-16 10:14:03 UTC ++++ src/libslic3r/Thread.cpp +@@ -9,10 +9,10 @@ + #include + #include + #include ++#include ++#include + #include +-#include + #include +-#include + + #include "Thread.hpp" + +@@ -206,13 +206,13 @@ void name_tbb_thread_pool_threads() + nthreads = 1; + #endif + +- if (nthreads != nthreads_hw) +- new tbb::task_scheduler_init(int(nthreads)); ++ if (nthreads != nthreads_hw) ++ tbb::global_control(tbb::global_control::max_allowed_parallelism, nthreads); + + std::atomic nthreads_running(0); + std::condition_variable cv; + std::mutex cv_m; +- auto master_thread_id = tbb::this_tbb_thread::get_id(); ++ auto master_thread_id = std::this_thread::get_id(); + tbb::parallel_for( + tbb::blocked_range(0, nthreads, 1), + [&nthreads_running, nthreads, &master_thread_id, &cv, &cv_m](const tbb::blocked_range &range) { +@@ -226,7 +226,7 @@ void name_tbb_thread_pool_threads() + std::unique_lock lk(cv_m); + cv.wait(lk, [&nthreads_running, nthreads]{return nthreads_running == nthreads;}); + } +- auto thread_id = tbb::this_tbb_thread::get_id(); ++ auto thread_id = std::this_thread::get_id(); + if (thread_id == master_thread_id) { + // The calling thread runs the 0'th task. + assert(range.begin() == 0);