git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH v2 2/6] build: include procinfo.c impl for macOS

From
Matthew John Cheetham via GitGitGadget <gitgitgadget@gmail.com>
Date
Feb 13, 2026, 19:54 UTC
Message-ID
<546fcc3446508eb56312fa195483816d94ea0d41.1771012500.git.gitgitgadget@gmail.com>
In-Reply-To
<pull.2040.v2.git.1771012500.gitgitgadget@gmail.com>
From: Matthew John Cheetham <mjcheetham@outlook.com>
Include an implementation of trace2_collect_process_info for macOS.
Signed-off-by: Matthew John Cheetham <mjcheetham@outlook.com>
---
 config.mak.uname                    | 2 ++
 contrib/buildsystems/CMakeLists.txt | 2 ++
 meson.build                         | 2 ++
 3 files changed, 6 insertions(+)
diff --git a/config.mak.uname b/config.mak.uname
index 1691c6ae6e..baa5018461 100644
--- a/config.mak.uname
+++ b/config.mak.uname
@@ -148,6 +148,8 @@ ifeq ($(uname_S),Darwin)
 	HAVE_NS_GET_EXECUTABLE_PATH = YesPlease
 	CSPRNG_METHOD = arc4random
 	USE_ENHANCED_BASIC_REGULAR_EXPRESSIONS = YesPlease
+	HAVE_PLATFORM_PROCINFO = YesPlease
+	COMPAT_OBJS += compat/darwin/procinfo.o
 
 	# Workaround for `gettext` being keg-only and not even being linked via
 	# `brew link --force gettext`, should be obsolete as of
diff --git a/contrib/buildsystems/CMakeLists.txt b/contrib/buildsystems/CMakeLists.txt
index edb0fc04ad..d489f0cada 100644
--- a/contrib/buildsystems/CMakeLists.txt
+++ b/contrib/buildsystems/CMakeLists.txt
@@ -274,6 +274,8 @@ if(CMAKE_SYSTEM_NAME STREQUAL "Windows")
 elseif(CMAKE_SYSTEM_NAME STREQUAL "Linux")
 	add_compile_definitions(PROCFS_EXECUTABLE_PATH="/proc/self/exe" HAVE_DEV_TTY )
 	list(APPEND compat_SOURCES unix-socket.c unix-stream-server.c compat/linux/procinfo.c)
+elseif(CMAKE_SYSTEM_NAME STREQUAL "Darwin")
+	list(APPEND compat_SOURCES compat/darwin/procinfo.c)
 endif()
 
 if(CMAKE_SYSTEM_NAME STREQUAL "Windows")
diff --git a/meson.build b/meson.build
index 1f95a06edb..32d470e4f7 100644
--- a/meson.build
+++ b/meson.build
@@ -1292,6 +1292,8 @@ if host_machine.system() == 'linux'
   libgit_sources += 'compat/linux/procinfo.c'
 elif host_machine.system() == 'windows'
   libgit_sources += 'compat/win32/trace2_win32_process_info.c'
+elif host_machine.system() == 'darwin'
+  libgit_sources += 'compat/darwin/procinfo.c'
 else
   libgit_sources += 'compat/stub/procinfo.c'
 endif
-- 
gitgitgadget
Previous: Matthew John Cheetham via GitGitGadgetNext: Junio C Hamano
Message 17 of 25 in “trace2: add macOS and Windows process ancestry tracing”
  1. 0/4 trace2: add macOS and Windows process ancestry tracingMatthew John Cheetham via GitGitGadget, Feb 5, 2026
  2. 2/4 build: include procinfo.c impl for macOSMatthew John Cheetham via GitGitGadget, Feb 5, 2026
  3. Derrick StoleeFeb 9, 2026
  4. 1/4 trace2: add macOS process ancestry tracingMatthew John Cheetham via GitGitGadget, Feb 5, 2026
  5. Derrick StoleeFeb 9, 2026
  6. Matthew John CheethamFeb 9, 2026
  7. Derrick StoleeFeb 10, 2026
  8. 3/4 trace2: refactor Windows process ancestry trace2 eventMatthew John Cheetham via GitGitGadget, Feb 5, 2026
  9. Derrick StoleeFeb 9, 2026
  10. 4/4 trace2: emit cmd_ancestry data for WindowsMatthew John Cheetham via GitGitGadget, Feb 5, 2026
  11. Kristoffer HaugsbakkFeb 5, 2026
  12. Derrick StoleeFeb 9, 2026
  13. Derrick StoleeFeb 9, 2026
  14. Junio C HamanoFeb 9, 2026
  15. 0/6 trace2: add macOS and Windows process ancestry tracingMatthew John Cheetham via GitGitGadget, Feb 13, 2026
  16. 1/6 trace2: add macOS process ancestry tracingMatthew John Cheetham via GitGitGadget, Feb 13, 2026
  17. 2/6 build: include procinfo.c impl for macOSMatthew John Cheetham via GitGitGadget, Feb 13, 2026
  18. Junio C HamanoFeb 13, 2026
  19. 3/6 trace2: refactor Windows process ancestry trace2 eventMatthew John Cheetham via GitGitGadget, Feb 13, 2026
  20. Junio C HamanoFeb 13, 2026
  21. 4/6 trace2: emit cmd_ancestry data for WindowsMatthew John Cheetham via GitGitGadget, Feb 13, 2026
  22. Junio C HamanoFeb 13, 2026
  23. 5/6 test-tool: extend trace2 helper with 400ancestryMatthew John Cheetham via GitGitGadget, Feb 13, 2026
  24. 6/6 t0213: add trace2 cmd_ancestry testsMatthew John Cheetham via GitGitGadget, Feb 13, 2026
  25. Derrick StoleeFeb 14, 2026

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.