From nobody Thu Jun 8 18:14:20 2023 X-Original-To: dev-commits-src-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 4QcXRJ2XHrz4cG28; Thu, 8 Jun 2023 18:14:20 +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 4QcXRJ20fcz3y9G; Thu, 8 Jun 2023 18:14:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1686248060; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=7QFHDnfm3M8gOFaozCsEwZpvolg7eGbxzwf8+eJzi4I=; b=eHmWNeZtS2cSQOG7u03MZx4tbfE1IcOSAQK303P3Mam6fXBghGpRi/UBBdT4Q/YKTT1qaI M/P4MT4cyF0JiZehKVmX7wjYPNhYIr8kpq7LUzrm46lf+VRbLxy1hMpvP6AIfNAXcFhu0L Bew+HWU/3VrrW2gNA9LwKEXvW8i7turWH+1sNV1tJJRsM9gFdMjpXmHX+Pg77gIEGprZTl wmqPaTwiVFQieAVtDBf0N9hdo8hVbV6ywMTEturgZIsis9VSyG07sQsfawOySBVBmbXvyK JRW0DCIMtEB5N/s2AXRltlubkGks6BYbE5ik+qNQ9pczeECpn8bzXIMUyKtzoA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1686248060; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=7QFHDnfm3M8gOFaozCsEwZpvolg7eGbxzwf8+eJzi4I=; b=uUuMODbgcf/zbyFp9py3X7YS/Zy7J2QxWIRD0gPvvUuvdWvl8ruwMNkBbMSwLZTGbZZeYI 91CfknkRdJs5wBTgIceggJbLbWbAbQk9/eNWkbGAKspmJTaJTtUB/ZuccnuTxnzdL53g2v cmbN54rbA0uXsOLMoJP5JfxmVFTV/PgIiror+bkgkp0elKup+vq+SLBmkdM+RvtKjAoFsg mNv12L1ZPBG8KKyL8v7L1mGZVfHdPZqUAVPQX/LLgn4ApOD4Qg0YcLaBH/6FvWGg53l/4U a3fUYGR3v8RKmFXZgiv4IsgRPTjlVRxnGHVYyeXCNBq6z7t2GWSzzwtgY9OxdQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1686248060; a=rsa-sha256; cv=none; b=C/PUhb5sSp3pk1EfJMG8zBSLsAacN6ZAxsCHnO8DIbj979RnmM6+9psCXuzsDUlRVdEASn 7wH1LVVT/LpUMQJJqws5gYPu09RUDmBuumwG1+bi8t6YCzCl44EiisMoNUK+Z4PXs23cAb LajQOVwwIm8MAuheKjY7u7OEicFcwoWNBw7xycjPV/gg+P9MzqVR5og65C5v/DdD54rfT2 scsSZLrKkD3Lu8jryGaVY8nXXI77dsxGDd9m3S+JQ5Z7KKUan/lTCYxmcDdiacJq7vxO4s 0l4+YqL03HoFShl31D+VtSgF4o/U/wpSYafETTNA9qi0xjX/szQs6qG/4Movkg== 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 4QcXRJ11SYz14Kp; Thu, 8 Jun 2023 18:14:20 +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 358IEKt3031904; Thu, 8 Jun 2023 18:14:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 358IEK32031903; Thu, 8 Jun 2023 18:14:20 GMT (envelope-from git) Date: Thu, 8 Jun 2023 18:14:20 GMT Message-Id: <202306081814.358IEK32031903@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Jessica Clarke Subject: git: 469727c966bb - main - Makefile.inc1: Use INSTALL_DDIR for distributeworld's distrib-dirs List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jrtc27 X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 469727c966bbd91447c8402470452b95810f3ffe Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by jrtc27: URL: https://cgit.FreeBSD.org/src/commit/?id=469727c966bbd91447c8402470452b95810f3ffe commit 469727c966bbd91447c8402470452b95810f3ffe Author: Jessica Clarke AuthorDate: 2023-06-08 16:47:04 +0000 Commit: Jessica Clarke CommitDate: 2023-06-08 18:14:12 +0000 Makefile.inc1: Use INSTALL_DDIR for distributeworld's distrib-dirs INSTALL_DDIR is the canonicalised version of DESTDIR/DISTDIR. Whilst most of what distrib-dirs does doesn't need the canonicalised form, it is responsible for installing the POSIX and en_US.US_ASCII NLS symlinks to C, and therefore needs the canonicalised version for those two uses of install for NO_ROOT builds, since our install does a naive text-based prefix strip when creating the METALOG entry rather than a smarter path semantics-aware one (which itself is really a bug, and has bitten us many times). As a result, using plain DESTDIR/DISTDIR instead can result in the METALOG having ./path/to/destdir/base/usr/share/nls/$LOCALE rather than ./base/usr/share/nls/$LOCALE and then being filtered out when creating base.meta (or, if you're unlucky and the absolute path begins with base or tests, weird things will probably happen). Given this footgun an audit of DESTDIR uses is probably in order, especially those using DESTDIR/DISTDIR, but this is sufficient for now. --- Makefile.inc1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile.inc1 b/Makefile.inc1 index 86e8da9467da..88ae6dadd8a1 100644 --- a/Makefile.inc1 +++ b/Makefile.inc1 @@ -1456,7 +1456,7 @@ distributeworld installworld stageworld: _installcheck_world .PHONY -mkdir ${DESTDIR}/${DISTDIR}/base ${_+_}cd ${.CURDIR}/etc; ${CROSSENV} PATH=${TMPPATH:Q} ${MAKE} \ METALOG=${METALOG} ${IMAKE_INSTALL} ${IMAKE_MTREE} \ - DISTBASE=/base DESTDIR=${DESTDIR}/${DISTDIR}/base \ + DISTBASE=/base DESTDIR=${INSTALL_DDIR}/base \ LOCAL_MTREE=${LOCAL_MTREE:Q} distrib-dirs ${INSTALL_SYMLINK} ${INSTALLFLAGS} usr/src/sys ${INSTALL_DDIR}/base/sys .endif # make(distributeworld)