From: Junio C Hamano <gitster@pobox.com>
To: Patrick Steinhardt <ps@pks.im>
Cc: git@vger.kernel.org, Samuel Thibault <samuel.thibault@ens-lyon.org>
Subject: Re: [PATCH] Fix GNU/Hurd build
Date: Thu, 12 Mar 2026 13:38:21 -0700 [thread overview]
Message-ID: <xmqqbjgsdbr6.fsf@gitster.g> (raw)
In-Reply-To: <20260312191901.174808-1-samuel.thibault@ens-lyon.org> (Samuel Thibault's message of "Thu, 12 Mar 2026 20:19:01 +0100")
Samuel Thibault <samuel.thibault@ens-lyon.org> writes:
> GNU/Hurd does not have a PATH_MAX limitation
Thanks. clar folks might prefer to take it upstream and have us as
a downstream to import from them, so I'll forward it first before
taking it for ourselves.
It makes me wonder if an organization like this is easier to follow,
i.e., platform specific settings first and then catch-all default at
the end:
#if defined(CLAR_LONGPATHS)
#define CLAR_MAX_PATH 4096
#elif defined(PATH_MAX)
#define CLAR_MAX_PATH PATH_MAX
#elif deifned(MAX_PATH)
#define CLAR_MAX_PATH MAX_PATH
#fi
#if !defined(CLAR_MAX_PATH)
#define CLAR_MAX_PATH 4096
#fi
but that is a separate issue best handled by the clar folks.
--- >8 ---
From: Samuel Thibault <samuel.thibault@ens-lyon.org>
Date: Thu, 12 Mar 2026 20:19:01 +0100
Subject: [PATCH] clar: compilation fix for GNU/Hurd
<clar.h> fails to define CLAR_MAX_PATH on GNU/Hurd where PATH_MAX is
not defined.
Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
---
t/unit-tests/clar/clar.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/t/unit-tests/clar/clar.h b/t/unit-tests/clar/clar.h
index ca72292ae9..4394aabbb9 100644
--- a/t/unit-tests/clar/clar.h
+++ b/t/unit-tests/clar/clar.h
@@ -10,7 +10,7 @@
#include <stdlib.h>
#include <limits.h>
-#if defined(_WIN32) && defined(CLAR_WIN32_LONGPATHS)
+#if defined(__GNU__) || defined(_WIN32) && defined(CLAR_WIN32_LONGPATHS)
# define CLAR_MAX_PATH 4096
#elif defined(_WIN32)
# define CLAR_MAX_PATH MAX_PATH
--
2.53.0-707-gf7b889d8f7
next prev parent reply other threads:[~2026-03-12 20:38 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-12 19:19 [PATCH] Fix GNU/Hurd build Samuel Thibault
2026-03-12 20:38 ` Junio C Hamano [this message]
2026-03-13 6:39 ` Patrick Steinhardt
2026-03-13 17:24 ` Samuel Thibault
2026-03-13 19:08 ` Junio C Hamano
2026-03-16 6:41 ` Patrick Steinhardt
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=xmqqbjgsdbr6.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=ps@pks.im \
--cc=samuel.thibault@ens-lyon.org \
/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