public inbox for git@vger.kernel.org
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: "Matthew John Cheetham via GitGitGadget" <gitgitgadget@gmail.com>
Cc: git@vger.kernel.org,  stolee@gmail.com,
	 johannes.schindelin@gmx.de,
	Kristoffer Haugsbakk <kristofferhaugsbakk@fastmail.com>,
	 Matthew John Cheetham <mjcheetham@outlook.com>
Subject: Re: [PATCH v2 2/6] build: include procinfo.c impl for macOS
Date: Fri, 13 Feb 2026 12:34:30 -0800	[thread overview]
Message-ID: <xmqqy0kwl6w9.fsf@gitster.g> (raw)
In-Reply-To: <546fcc3446508eb56312fa195483816d94ea0d41.1771012500.git.gitgitgadget@gmail.com> (Matthew John Cheetham via GitGitGadget's message of "Fri, 13 Feb 2026 19:54:56 +0000")

"Matthew John Cheetham via GitGitGadget" <gitgitgadget@gmail.com>
writes:

> 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(+)

Looking good.  I wondered if the first two steps should be a single
patch (as the tree will be with a totally unused file until the
second patch is applied), but this organization will give better
chances for the second patch to be viewed by folks who are good at
build infrastructure who are not necessarily interested in macOS
specific programming, so it probably is better presented this way.

>
> 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

  reply	other threads:[~2026-02-13 20:34 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-02-05 16:05 [PATCH 0/4] trace2: add macOS and Windows process ancestry tracing Matthew John Cheetham via GitGitGadget
2026-02-05 16:05 ` [PATCH 1/4] trace2: add macOS " Matthew John Cheetham via GitGitGadget
2026-02-09 14:36   ` Derrick Stolee
2026-02-09 15:13     ` Matthew John Cheetham
2026-02-10  4:15       ` Derrick Stolee
2026-02-05 16:05 ` [PATCH 2/4] build: include procinfo.c impl for macOS Matthew John Cheetham via GitGitGadget
2026-02-09 14:37   ` Derrick Stolee
2026-02-05 16:05 ` [PATCH 3/4] trace2: refactor Windows process ancestry trace2 event Matthew John Cheetham via GitGitGadget
2026-02-09 14:41   ` Derrick Stolee
2026-02-05 16:05 ` [PATCH 4/4] trace2: emit cmd_ancestry data for Windows Matthew John Cheetham via GitGitGadget
2026-02-05 16:19   ` Kristoffer Haugsbakk
2026-02-09 14:42   ` Derrick Stolee
2026-02-09 14:48 ` [PATCH 0/4] trace2: add macOS and Windows process ancestry tracing Derrick Stolee
2026-02-09 17:05   ` Junio C Hamano
2026-02-13 19:54 ` [PATCH v2 0/6] " Matthew John Cheetham via GitGitGadget
2026-02-13 19:54   ` [PATCH v2 1/6] trace2: add macOS " Matthew John Cheetham via GitGitGadget
2026-02-13 19:54   ` [PATCH v2 2/6] build: include procinfo.c impl for macOS Matthew John Cheetham via GitGitGadget
2026-02-13 20:34     ` Junio C Hamano [this message]
2026-02-13 19:54   ` [PATCH v2 3/6] trace2: refactor Windows process ancestry trace2 event Matthew John Cheetham via GitGitGadget
2026-02-13 20:36     ` Junio C Hamano
2026-02-13 19:54   ` [PATCH v2 4/6] trace2: emit cmd_ancestry data for Windows Matthew John Cheetham via GitGitGadget
2026-02-13 20:52     ` Junio C Hamano
2026-02-13 19:54   ` [PATCH v2 5/6] test-tool: extend trace2 helper with 400ancestry Matthew John Cheetham via GitGitGadget
2026-02-13 19:55   ` [PATCH v2 6/6] t0213: add trace2 cmd_ancestry tests Matthew John Cheetham via GitGitGadget
2026-02-14  0:30   ` [PATCH v2 0/6] trace2: add macOS and Windows process ancestry tracing Derrick Stolee

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=xmqqy0kwl6w9.fsf@gitster.g \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=gitgitgadget@gmail.com \
    --cc=johannes.schindelin@gmx.de \
    --cc=kristofferhaugsbakk@fastmail.com \
    --cc=mjcheetham@outlook.com \
    --cc=stolee@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox