From patchwork Tue Nov 29 14:09:14 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?w4Z2YXIgQXJuZmrDtnLDsCBCamFybWFzb24=?= X-Patchwork-Id: 13058605 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2C753C4321E for ; Tue, 29 Nov 2022 14:09:32 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235097AbiK2OJ3 (ORCPT ); Tue, 29 Nov 2022 09:09:29 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45026 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235032AbiK2OJZ (ORCPT ); Tue, 29 Nov 2022 09:09:25 -0500 Received: from mail-ej1-x62e.google.com (mail-ej1-x62e.google.com [IPv6:2a00:1450:4864:20::62e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 393EA22B06 for ; Tue, 29 Nov 2022 06:09:22 -0800 (PST) Received: by mail-ej1-x62e.google.com with SMTP id vv4so34088727ejc.2 for ; Tue, 29 Nov 2022 06:09:22 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=6Q37YzqBkTLrE60NsBW6jIhh4Jau5xx2CLdYrci8Bbs=; b=A1Jmls0XB8H4jxldZrK9as38EgQJQ7dl2+YTeQgji1KRE2Cp7Ibo963qTz96NPuOGw Z+W8alOLzZBoVo9ml7GjWBoT7FvxBY2tCItA6YzUXO+5wIl93R9X8ocRiGuwqWxCyZ+G ThilddKI2AWWsluZIZIS6MJ7ynylac36O30Oprl3YVTaw9u4RISymQ+5CKz06g6xwNO0 AgOLiejaJO9X0j77DhzUyHo+KSv/6PKxcXGLhfgMkw5JFlIMGDEY/zeYeMrHwBkeEhhy TDpbbYaQsyR1PyDexcbCqCYQ4/bF+NwVha14eaDj5WWoBcylY0/RBJKrT8I7inugMfcN 2dhQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=6Q37YzqBkTLrE60NsBW6jIhh4Jau5xx2CLdYrci8Bbs=; b=NxFcZiO+bIQ4AsQ5wD8Ot//M7Se/mww/5R8zC3Eh4BLX58cO6stt0QVOAnYzN+4i7O AJNJmEjgEbz5hx/p8CuXz8z14ehDO1s3qJzAgIKdx/VEZb0t7G3a7RHwd4cqDweT29Gq cUgXhhknlCzvrSWu+kvefnAvEj5aKcikL+cUmEUyJSLmHZ4MHU9Zd8jjUtZOiE8I/mQG 82bU//Y52IippT1T03Xd08nWwhuDp8F+i4sci4A5pHhDUFnMGGO/2XjXrTM6pBgRwE4Y u5fCmFUEiTy9ozeKQkpW6p1+FWA97yYecPWgf//pbU2Ypj62pTxUkGJgiKiKQ/G6a/Pp 3NYw== X-Gm-Message-State: ANoB5pl1zljd6OYaGXnx6OnScGT8yWVQOFSSPzVfh8gFSWbKf/fpl+Fj zj4ABuDZqjb5hvNqIaDunwi3X/U6eYvg/A== X-Google-Smtp-Source: AA0mqf55xj9JSrjLdrfAE0TYEmD84hqHekmEWQnzECBhtgvG8R3489nXu4EF9dqtkd3ajq7HzdagmQ== X-Received: by 2002:a17:906:c042:b0:781:541:8f1d with SMTP id bm2-20020a170906c04200b0078105418f1dmr49038443ejb.117.1669730960390; Tue, 29 Nov 2022 06:09:20 -0800 (PST) Received: from vm.nix.is (vm.nix.is. [2a01:4f8:120:2468::2]) by smtp.gmail.com with ESMTPSA id be14-20020a0564021a2e00b00463597d2c25sm6307907edb.74.2022.11.29.06.09.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 29 Nov 2022 06:09:19 -0800 (PST) From: =?utf-8?b?w4Z2YXIgQXJuZmrDtnLDsCBCamFybWFzb24=?= To: git@vger.kernel.org Cc: Junio C Hamano , Paul Smith , =?utf-8?b?w4Z2YXIgQXJuZmrDtnLDsCBCamFybWFzb24=?= Subject: [PATCH v2 1/4] Documentation/Makefile: de-duplicate *.[157] dependency list Date: Tue, 29 Nov 2022 15:09:14 +0100 Message-Id: X-Mailer: git-send-email 2.39.0.rc0.993.g0c499e58e3b In-Reply-To: References: <20221127224251.2508200-1-psmith@gnu.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org Use the "DOC_MAN[157]" variables combined into a new "DOC_MANN" to declare that e.g. "git-am.1" depends on "manpage-base-url.xsl" etc. This change helps to make a subsequent change smaller. Signed-off-by: Ævar Arnfjörð Bjarmason --- Documentation/Makefile | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Documentation/Makefile b/Documentation/Makefile index 5e1a7f655c2..d239f6751f0 100644 --- a/Documentation/Makefile +++ b/Documentation/Makefile @@ -129,9 +129,13 @@ ARTICLES_HTML += $(patsubst %,%.html,$(ARTICLES) $(SP_ARTICLES)) HTML_FILTER ?= $(ARTICLES_HTML) $(OBSOLETE_HTML) DOC_HTML = $(MAN_HTML) $(filter $(HTML_FILTER),$(ARTICLES_HTML) $(OBSOLETE_HTML)) +DOC_MANN = DOC_MAN1 = $(patsubst %.txt,%.1,$(filter $(MAN_FILTER),$(MAN1_TXT))) +DOC_MANN += $(DOC_MAN1) DOC_MAN5 = $(patsubst %.txt,%.5,$(filter $(MAN_FILTER),$(MAN5_TXT))) +DOC_MANN += $(DOC_MAN5) DOC_MAN7 = $(patsubst %.txt,%.7,$(filter $(MAN_FILTER),$(MAN7_TXT))) +DOC_MANN += $(DOC_MAN7) prefix ?= $(HOME) bindir ?= $(prefix)/bin @@ -351,7 +355,8 @@ $(OBSOLETE_HTML): %.html : %.txto $(ASCIIDOC_DEPS) manpage-base-url.xsl: manpage-base-url.xsl.in $(QUIET_GEN)sed "s|@@MAN_BASE_URL@@|$(MAN_BASE_URL)|" $< > $@ -%.1 %.5 %.7 : %.xml manpage-base-url.xsl $(wildcard manpage*.xsl) +$(DOC_MANN): manpage-base-url.xsl $(wildcard manpage*.xsl) +%.1 %.5 %.7 : %.xml $(QUIET_XMLTO)$(XMLTO) -m $(MANPAGE_XSL) $(XMLTO_EXTRA) man $< %.xml : %.txt $(ASCIIDOC_DEPS) From patchwork Tue Nov 29 14:09:15 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?w4Z2YXIgQXJuZmrDtnLDsCBCamFybWFzb24=?= X-Patchwork-Id: 13058607 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 30380C4321E for ; Tue, 29 Nov 2022 14:09:34 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235173AbiK2OJd (ORCPT ); Tue, 29 Nov 2022 09:09:33 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45028 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235049AbiK2OJZ (ORCPT ); Tue, 29 Nov 2022 09:09:25 -0500 Received: from mail-ej1-x636.google.com (mail-ej1-x636.google.com [IPv6:2a00:1450:4864:20::636]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 322F85E3F3 for ; Tue, 29 Nov 2022 06:09:23 -0800 (PST) Received: by mail-ej1-x636.google.com with SMTP id gu23so15850914ejb.10 for ; Tue, 29 Nov 2022 06:09:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=mqdhRJeWjbhJCcIHCixaVYUEMhTO9hcQ77FXmfLanrg=; b=Moe253T758/F80s1GcYp7bMxqJI7jvBGVd5ZMWkgs8WMI/qyYLVqouDGPBDNmJIMee 0LBpTBHrBFs4QbNoo2AV8HltWxc25AhJiQVnivACzF/4aBYddgFJ0lgoSNvCq5E0fFHt I6eC0BqAQonBimOt1K1VPDNRS0yoETrEta4CsELc3YoXQw0QPPCFgO+v9xgWzWhCL8M/ 1479/jVapq/XwTsIwQJkwLM6mRRI34iLyyGJlGcopEF0WT9pHoKrKKWhnudslP/q1d9S xpTroi/J1T9XhDJMPHkS1+tDfy7Te6J6AqptWTHGa0sHFR1D/riWeXRFgwqWcnb2VFW8 j5dA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=mqdhRJeWjbhJCcIHCixaVYUEMhTO9hcQ77FXmfLanrg=; b=Okd+YWVmKugtwLd/6ZlmTT5jVfZU2IE6AjBO3PwUgoBBbtJ4o4vpf7a7G0B7DmE4iF QEEdN1QcZdBOvxfu8L2BDLAKy8n31SC+zi1fNOG3YVdgiFwOPhz+t5xkwmjdDHXnIA5B Kw9lQsecy2s+YNmx+hFDiP1/P1EMZ85aPXyDNa7ccB7mCdH01DnDuK+aFujAWTEgAf10 VbSBx+dsZs/Vq1siO0XH0bKxzAfuGmfeTlJqOOAvBKQNvjmOuJirhDgyXZFFt6mOoWGS ef+b7yxOJ7A0pA9OZ4yGR2Dz9eSY4o0XUmG2CLChQKjmRqHwCr2XLCbZsjfnws0XLH5e dmgg== X-Gm-Message-State: ANoB5plarebND5iT4LJaewyAgvtx3fUZNp3Wnjoudiy+Mo/IwLPsp9qX RWc5QlBAQ/mTaIlhCcwzqaM3zyZUt4s59g== X-Google-Smtp-Source: AA0mqf6AUbRRs6a3vgINdAKsAKIiSTks8I4BUEi6xZSa82m3ZueN0YLt934u4Ku9J0yHTEx9Onif8A== X-Received: by 2002:a17:906:ca18:b0:781:c97c:84d1 with SMTP id jt24-20020a170906ca1800b00781c97c84d1mr47708537ejb.147.1669730961307; Tue, 29 Nov 2022 06:09:21 -0800 (PST) Received: from vm.nix.is (vm.nix.is. [2a01:4f8:120:2468::2]) by smtp.gmail.com with ESMTPSA id be14-20020a0564021a2e00b00463597d2c25sm6307907edb.74.2022.11.29.06.09.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 29 Nov 2022 06:09:20 -0800 (PST) From: =?utf-8?b?w4Z2YXIgQXJuZmrDtnLDsCBCamFybWFzb24=?= To: git@vger.kernel.org Cc: Junio C Hamano , Paul Smith , Alexander Kanavin , =?utf-8?b?w4Z2YXIgQXJuZmrDtnI=?= =?utf-8?b?w7AgQmphcm1hc29u?= Subject: [PATCH v2 2/4] Documentation/Makefile: avoid multiple patterns when generating one file Date: Tue, 29 Nov 2022 15:09:15 +0100 Message-Id: X-Mailer: git-send-email 2.39.0.rc0.993.g0c499e58e3b In-Reply-To: References: <20221127224251.2508200-1-psmith@gnu.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org From: Paul Smith A GNU make pattern rule with multiple targets has always meant that a single invocation of the recipe will build all the targets. However in older versions of GNU make a recipe that did not really build all the targets would be tolerated. Starting with GNU make 4.4 this behavior is deprecated and pattern rules are expected to generate files to match all the patterns. If not all targets are created then GNU make will not consider any target up to date and will re-run the recipe when it is run again. I.e. a command like: make -C Documentation git-am.1 Will never be satisfied that "git-am.1" has been made, because we didn't also make "git-am.5" and "git-am.7", as the warning it'll emit indicates: $ make -C Documentation git-am.1 [...] XMLTO git-am.1 Makefile:355: warning: pattern recipe did not update peer target 'git-am.7'. Makefile:355: warning: pattern recipe did not update peer target 'git-am.5'. Modify Documentation/Makefile to split the man page-creating pattern rule into a separate pattern rule for each pattern. This requires a small amount of copy/pasting, but due to splitting out the "DOC_MANN" in the preceding commit it's not too bad. Reported-by: Alexander Kanavin Signed-off-by: Paul Smith Signed-off-by: Ævar Arnfjörð Bjarmason --- Documentation/Makefile | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Documentation/Makefile b/Documentation/Makefile index d239f6751f0..89929e3d60b 100644 --- a/Documentation/Makefile +++ b/Documentation/Makefile @@ -356,7 +356,11 @@ manpage-base-url.xsl: manpage-base-url.xsl.in $(QUIET_GEN)sed "s|@@MAN_BASE_URL@@|$(MAN_BASE_URL)|" $< > $@ $(DOC_MANN): manpage-base-url.xsl $(wildcard manpage*.xsl) -%.1 %.5 %.7 : %.xml +%.1 : %.xml + $(QUIET_XMLTO)$(XMLTO) -m $(MANPAGE_XSL) $(XMLTO_EXTRA) man $< +%.5 : %.xml + $(QUIET_XMLTO)$(XMLTO) -m $(MANPAGE_XSL) $(XMLTO_EXTRA) man $< +%.7 : %.xml $(QUIET_XMLTO)$(XMLTO) -m $(MANPAGE_XSL) $(XMLTO_EXTRA) man $< %.xml : %.txt $(ASCIIDOC_DEPS) From patchwork Tue Nov 29 14:09:17 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?w4Z2YXIgQXJuZmrDtnLDsCBCamFybWFzb24=?= X-Patchwork-Id: 13058608 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1349AC4321E for ; Tue, 29 Nov 2022 14:09:37 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235178AbiK2OJe (ORCPT ); Tue, 29 Nov 2022 09:09:34 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45152 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235082AbiK2OJ0 (ORCPT ); Tue, 29 Nov 2022 09:09:26 -0500 Received: from mail-ej1-x62e.google.com (mail-ej1-x62e.google.com [IPv6:2a00:1450:4864:20::62e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3508859FF3 for ; Tue, 29 Nov 2022 06:09:25 -0800 (PST) Received: by mail-ej1-x62e.google.com with SMTP id n21so34024642ejb.9 for ; Tue, 29 Nov 2022 06:09:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=y8wDyZgg9QMEoWmHITR0hjRGFfAsuwOwI7fxLXhJfso=; b=hwEhj+H7gER4FoAr1PKHQD4b45lXtN4vOcJjBjGYCNHrsqtO1KHeXdhCIgKg9y7KEf 0ArDCQGAhwfv5p5lglR3e5WOg8GavrIJAPK/5rNxQKib6S2lU+N5QXTkmUVEgvmmD6O8 wMoxLYHvmS8rVRwuY2JSljd56kBN8EWzufrEqD+EFjF5POg2uPuVNdzqDK66zmcHt5cY Ehc2rIEYnPXL89o8mxTDKCnWCYDs4ik/wZ51kH6RmtlOR9yDJT92SZ/XQcFdB+zT6qn0 r41q27RWdO+ukcx7h0+lBP2n34UkjE7kQboBuwfcj2ruqcc7py3eb6VuRM/gg6DTjNBB 9YQQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=y8wDyZgg9QMEoWmHITR0hjRGFfAsuwOwI7fxLXhJfso=; b=b6J0tG2xracDHAEyNdxul1MVZXYYV97kUaVYIN+J8xqZmuuuqWFUbU2lEmj4La97qo y2Fqke8tiicwInPrOHmDsw6YQ+tOl7m/ilgC1KvWUkVakDjOLmXyurBU0h18iykd1SK1 z74mAlR17h4BqCx212oWvFH6gSziqLBV0tXkC0NRZT/yL6E+0H+LNin8ySRlkGCHVitD 6mToKACJWpRXzRF43MQw9USuhP+nmgbKd7v+Xvct6HgfMcYkncsSMQKvdqrWiL8qRok3 0iOVljAKzI3OAI5RsS4FIe794TbWlhyioaUjT0qowfKVytvk7KxsTDy6YZZl7v86ed7i OJSQ== X-Gm-Message-State: ANoB5pk8O29Ph7WXFD6J7buls7Y7bSkDCcmzgXyfPwqwLNXQPR3oS43X D4PQbmdCz33k4/NaIHuLKwPpnAe+ose28Q== X-Google-Smtp-Source: AA0mqf7FBSJb5wH4YKmzBkM1EMqElmaFgE+7u5Zy492obdGe8eeA5DaQqhgFt68/A7Qp6C8ypAsnpA== X-Received: by 2002:a17:906:1e8a:b0:7b2:b992:694d with SMTP id e10-20020a1709061e8a00b007b2b992694dmr42920674ejj.651.1669730963085; Tue, 29 Nov 2022 06:09:23 -0800 (PST) Received: from vm.nix.is (vm.nix.is. [2a01:4f8:120:2468::2]) by smtp.gmail.com with ESMTPSA id be14-20020a0564021a2e00b00463597d2c25sm6307907edb.74.2022.11.29.06.09.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 29 Nov 2022 06:09:22 -0800 (PST) From: =?utf-8?b?w4Z2YXIgQXJuZmrDtnLDsCBCamFybWFzb24=?= To: git@vger.kernel.org Cc: Junio C Hamano , Paul Smith , =?utf-8?b?w4Z2YXIgQXJuZmrDtnLDsCBCamFybWFzb24=?= Subject: [PATCH v2 4/4] Documentation/Makefile: narrow wildcard rules to our known files Date: Tue, 29 Nov 2022 15:09:17 +0100 Message-Id: X-Mailer: git-send-email 2.39.0.rc0.993.g0c499e58e3b In-Reply-To: References: <20221127224251.2508200-1-psmith@gnu.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org Instead of declaring that we'll generate e.g. any "%.1" from a corresponding "%.xml" let's narrow that list down to only our known manpage files, and likewise for %.xml. We already generated e.g. "man1" on the basis of "$(DOC_MAN1)", we just weren't keeping track of what we were generating exactly in the these middle steps. Signed-off-by: Ævar Arnfjörð Bjarmason --- Documentation/Makefile | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/Documentation/Makefile b/Documentation/Makefile index 89929e3d60b..f84b54ac093 100644 --- a/Documentation/Makefile +++ b/Documentation/Makefile @@ -356,14 +356,14 @@ manpage-base-url.xsl: manpage-base-url.xsl.in $(QUIET_GEN)sed "s|@@MAN_BASE_URL@@|$(MAN_BASE_URL)|" $< > $@ $(DOC_MANN): manpage-base-url.xsl $(wildcard manpage*.xsl) -%.1 : %.xml - $(QUIET_XMLTO)$(XMLTO) -m $(MANPAGE_XSL) $(XMLTO_EXTRA) man $< -%.5 : %.xml - $(QUIET_XMLTO)$(XMLTO) -m $(MANPAGE_XSL) $(XMLTO_EXTRA) man $< -%.7 : %.xml - $(QUIET_XMLTO)$(XMLTO) -m $(MANPAGE_XSL) $(XMLTO_EXTRA) man $< - -%.xml : %.txt $(ASCIIDOC_DEPS) +define doc-mann-rule +$$(DOC_MAN$(1)) : %.$(1) : %.xml + $$(QUIET_XMLTO)$$(XMLTO) -m $$(MANPAGE_XSL) $$(XMLTO_EXTRA) man $$< + +endef +$(eval $(foreach n,1 5 7,$(call doc-mann-rule,$(n)))) + +$(MAN_XML): %.xml : %.txt $(ASCIIDOC_DEPS) $(QUIET_ASCIIDOC)$(TXT_TO_XML) -d manpage -o $@ $< user-manual.xml: user-manual.txt user-manual.conf asciidoctor-extensions.rb GIT-ASCIIDOCFLAGS