From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A7F6EC433E0 for ; Mon, 18 May 2020 17:17:07 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 77E70207ED for ; Mon, 18 May 2020 17:17:07 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=pobox.com header.i=@pobox.com header.b="PoV3mt1r" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728152AbgERRRG (ORCPT ); Mon, 18 May 2020 13:17:06 -0400 Received: from pb-smtp21.pobox.com ([173.228.157.53]:60232 "EHLO pb-smtp21.pobox.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727006AbgERRRG (ORCPT ); Mon, 18 May 2020 13:17:06 -0400 Received: from pb-smtp21.pobox.com (unknown [127.0.0.1]) by pb-smtp21.pobox.com (Postfix) with ESMTP id 95B2EC839C; Mon, 18 May 2020 13:17:04 -0400 (EDT) (envelope-from junio@pobox.com) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; s=sasl; bh=BFBJBVLaAvQtNmhU5etEpos9HX4=; b=PoV3mt 1rsyXlOyHZqkt6RyTcVb9UBY/N+v8DagR85wr3RHurxrG1RHelLSWfgxMKV31cAy BOuhjc5annoGZFhMTERv2Vx0L85qZiotC3F/m1LJUvr2ZN8h/EG99GA33AD3hfr+ tqIamfpamEkzPpP7DBrJlHqVirdROOArbSmX0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; q=dns; s=sasl; b=b+1aSyD3Vtd2gngEpyF7zXOtOaIaBHIJ nRXOkWdfYlaoIdziolBJ+3ZPDHMPxX8sOnTaT8DvcNlqOC1HByac18v8HcplSFOT 52J0lK/4FWiiGdbNgmOtewbpmLOU2TJL8fjHEp18GjuiG0anqQ497Orz9vnDrlhK NuyLTA5FkbQ= Received: from pb-smtp21.sea.icgroup.com (unknown [127.0.0.1]) by pb-smtp21.pobox.com (Postfix) with ESMTP id 8DDABC839B; Mon, 18 May 2020 13:17:04 -0400 (EDT) (envelope-from junio@pobox.com) Received: from pobox.com (unknown [35.196.173.25]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by pb-smtp21.pobox.com (Postfix) with ESMTPSA id C6F81C8391; Mon, 18 May 2020 13:17:01 -0400 (EDT) (envelope-from junio@pobox.com) From: Junio C Hamano To: Darren Tucker Cc: git@vger.kernel.org Subject: Re: [PATCH 6/7] Check if strtoumax is a macro (eg HP-UX 11.11). References: <20200518100356.29292-1-dtucker@dtucker.net> <20200518100356.29292-6-dtucker@dtucker.net> Date: Mon, 18 May 2020 10:17:00 -0700 In-Reply-To: <20200518100356.29292-6-dtucker@dtucker.net> (Darren Tucker's message of "Mon, 18 May 2020 20:03:55 +1000") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Pobox-Relay-ID: 6362E40E-992B-11EA-A29C-8D86F504CC47-77302942!pb-smtp21.pobox.com Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org Darren Tucker writes: > Signed-off-by: Darren Tucker > --- > configure.ac | 10 ++++++++-- > 1 file changed, 8 insertions(+), 2 deletions(-) > > diff --git a/configure.ac b/configure.ac > index 14e09b04b6..87a39c5ae0 100644 > --- a/configure.ac > +++ b/configure.ac > @@ -1164,10 +1164,16 @@ GIT_CHECK_FUNC(strtoull, > [NO_STRTOULL=YesPlease]) > GIT_CONF_SUBST([NO_STRTOULL]) > # > -# Define NO_STRTOUMAX if you don't have strtoumax in the C library. > +# Define NO_STRTOUMAX if you don't have strtoumax in the C library > +# or as a macro in inttypes.h. > GIT_CHECK_FUNC(strtoumax, > [NO_STRTOUMAX=], > -[NO_STRTOUMAX=YesPlease]) > +[ > + AC_CHECK_DECL(strtoumax, > + [NO_STRTOUMAX=], > + [NO_STRTOUMAX=YesPlease], > + [#include ]) > +]) It is kind of surprising that we got away with GIT_CHECK_FUNC() that misses an implementation by macro without having problems with other symbols. I don't mind taking this patch as-is, but it makes me wonder if we need to devise a more systematic approach to the issue than "oh, I found GIT_CHECK_FUNC() does not work for X on system Y, so let's add an AC_CHECK_DECL() for it, too" approach, which this patch is its first step. Thanks.