From nobody Mon Nov 08 12:59:14 2021 X-Original-To: dev-commits-ports-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id B91421837CB5; Mon, 8 Nov 2021 12:59:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Hnrm24sHzz3P5J; Mon, 8 Nov 2021 12:59:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 81A2811FDC; Mon, 8 Nov 2021 12:59:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 1A8CxEYJ067026; Mon, 8 Nov 2021 12:59:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 1A8CxErX067025; Mon, 8 Nov 2021 12:59:14 GMT (envelope-from git) Date: Mon, 8 Nov 2021 12:59:14 GMT Message-Id: <202111081259.1A8CxErX067025@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Baptiste Daroussin Subject: git: 62f3ada9497a - main - index: keep index file as long as possible List-Id: Commit messages for all branches of the ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-all@freebsd.org X-BeenThere: dev-commits-ports-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: bapt X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 62f3ada9497ac74c9fe7fe8e4207eebd43af0989 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by bapt: URL: https://cgit.FreeBSD.org/ports/commit/?id=62f3ada9497ac74c9fe7fe8e4207eebd43af0989 commit 62f3ada9497ac74c9fe7fe8e4207eebd43af0989 Author: Baptiste Daroussin AuthorDate: 2021-11-08 12:51:02 +0000 Commit: Baptiste Daroussin CommitDate: 2021-11-08 12:58:22 +0000 index: keep index file as long as possible When generating the INDEX file, we are already building it in a temporary file and swap it last minute. make the index target now directly depend on the INDEX file generation target. Turn that target into a PHONY target so the file is always regenerated when someone calls make index. PR: 202070 --- Makefile | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index ad4b13aec200..b32de32b747f 100644 --- a/Makefile +++ b/Makefile @@ -64,9 +64,7 @@ PORTSTOP= yes .include -index: - @rm -f ${INDEXDIR}/${INDEXFILE} - @cd ${.CURDIR} && ${MAKE} ${INDEXDIR}/${INDEXFILE} +index: ${INDEXDIR}/${INDEXFILE} fetchindex: ${INDEXDIR}/${INDEXFILE}.bz2 @bunzip2 < ${INDEXDIR}/${INDEXFILE}.bz2 > ${INDEXDIR}/${INDEXFILE} && \ @@ -110,7 +108,7 @@ MAKE_INDEX= /usr/libexec/make_index /dev/stdin MAKE_INDEX= perl ${.CURDIR}/Tools/make_index .endif -${INDEXDIR}/${INDEXFILE}: +${INDEXDIR}/${INDEXFILE}: .PHONY @${INDEX_ECHO_1ST} "Generating ${INDEXFILE} - please wait.."; \ if [ "${INDEX_PRISTINE}" != "" ]; then \ export LOCALBASE=/nonexistentlocal; \