From nobody Thu Feb 23 22:34:57 2023 X-Original-To: freebsd-current@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 4PN7DB2tQQz3ss4Z for ; Thu, 23 Feb 2023 22:36:26 +0000 (UTC) (envelope-from sjg@juniper.net) Received: from mx0b-00273201.pphosted.com (mx0b-00273201.pphosted.com [67.231.152.164]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.pphosted.com", Issuer "Thawte RSA CA 2018" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4PN7DB0Fdgz3nRG; Thu, 23 Feb 2023 22:36:25 +0000 (UTC) (envelope-from sjg@juniper.net) Authentication-Results: mx1.freebsd.org; none Received: from pps.filterd (m0108162.ppops.net [127.0.0.1]) by mx0b-00273201.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 31NITGn1013809; Thu, 23 Feb 2023 14:36:04 -0800 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=juniper.net; h=to : cc : subject : in-reply-to : references : from : mime-version : content-type : content-id : content-transfer-encoding : date : message-id; s=PPS1017; bh=h49AyXInOPYMvYFhu5QRrhfAwDP5mE4EsIBJmPhyv1g=; b=HwIXU27oE5CuihK3wiZvYeNy7AxIVIUlPr/f+pDqT+513H9aaSSnPCkXuyCmL3f+/OEn iE/ZnBO6THHZ4MFlPB8SYYFcoLV1kkeKLcsBhMTYhwLyDkNkZPO7X7U1quCiHO0FYlwe 358ih9JZpGhGhnOGQt9Bxbk0djfT09RJ2gbANW6tCPltIAKYRIeBVvIjO82PG2CicCp6 HmG5RNYnsg0vn/scwn9yTPzNShiSRHCrCITDMkPQ7UV654i5vLTiaRCeSThF1ch9JN2G G5xk6h1fxEFxnLMgVq4pDyTQ31N5n4cYtNUhEFLc/qciN9rSlZR422xcLTMfgyz9/nm1 Ew== Received: from bl0pr02cu005-vft-obe.outbound.protection.outlook.com (mail-eastusazlp17012028.outbound.protection.outlook.com [40.93.11.28]) by mx0b-00273201.pphosted.com (PPS) with ESMTPS id 3nwy85adtk-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 23 Feb 2023 14:36:04 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=EgHTWnojy077a519X4qiFh3mRkG1c+lgpq4SG2p4fLTew2FN9p56Wj7EgiE5fD85i5w66qn/gTb7A9aeJ7aLqP273lrj1RbbTtp+8BMKSz6AaIMQYNq2OtAMy0LI/O7643sMlCL5Aj/Ab7lQac6zcTMgKlPlMKG7RqZvoB1nJSVaiQTiWdLXJu9RbrtNSc7tlo0ZyH+OU2E7+PyUHVmc0YiGypTKSyHuH7UuGtQiKxpXOkrk8BJ8MNszGu0hDlzTZADTE+4GHp/SoK7q9E3p8ncg7/o9JaqBY1NG6KKWdddklcV2lDN80vClWtgGqBImyPFZL9KdMlwuhkWMrMUGlg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=h49AyXInOPYMvYFhu5QRrhfAwDP5mE4EsIBJmPhyv1g=; b=krWiYL1hQuf6lC5dPRD/3LiOL+ca8vzzgAQYz2Mc+JNUMxDmVpb8f2s7LQSlvqxHQTswUtpvVvltX+c2GzOT49UQa9dVWQcZ3yJ1Uck6/t6zC7e4Wju2lCIcckMMoGEDtFs1qhucQblEXelsx33GOa9lpQmP1Cgw9k91XTLkjTFAziXwaioTwdqPnWHenYHw20fWZ67oTqmDnt5+F5kdl4DYcgCMhUoySIvxcfweauyyYY4nUF0fJr77v65nvFZD0rzQ/DMyi0RmY0IRspDcsO8IoYhbD5eeryAKyrgLOBE6KgdiLUnsgYAtXw++4gtunJWR0iuIGcDAdMY5qqYYjQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=softfail (sender ip is 66.129.239.14) smtp.rcpttodomain=yahoo.com smtp.mailfrom=juniper.net; dmarc=fail (p=reject sp=reject pct=100) action=oreject header.from=juniper.net; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=juniper.net; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=h49AyXInOPYMvYFhu5QRrhfAwDP5mE4EsIBJmPhyv1g=; b=GvQvFPUSXr23bC1QUw3fpqTAt28pTWE2pvWuKluTmmCnzXXzXKx5qjR8lXIWj3wON9c2KUiUlmAQyVzfvIe/qjdW/THvRZNl8Bxqiim/H7J62RSO+wCkRfTml9FKA/QJWDFK1BIHiIeHJc3mRpx+hYjGmD28NoyNGJw3LL0CYiQ= Received: from DM6PR06CA0083.namprd06.prod.outlook.com (2603:10b6:5:336::16) by CH2PR05MB7096.namprd05.prod.outlook.com (2603:10b6:610:47::30) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6134.19; Thu, 23 Feb 2023 22:35:59 +0000 Received: from DM6NAM12FT043.eop-nam12.prod.protection.outlook.com (2603:10b6:5:336:cafe::53) by DM6PR06CA0083.outlook.office365.com (2603:10b6:5:336::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6134.21 via Frontend Transport; Thu, 23 Feb 2023 22:35:59 +0000 X-MS-Exchange-Authentication-Results: spf=softfail (sender IP is 66.129.239.14) smtp.mailfrom=juniper.net; dkim=none (message not signed) header.d=none;dmarc=fail action=oreject header.from=juniper.net; Received-SPF: SoftFail (protection.outlook.com: domain of transitioning juniper.net discourages use of 66.129.239.14 as permitted sender) Received: from p-exchfe-eqx-01.jnpr.net (66.129.239.14) by DM6NAM12FT043.mail.protection.outlook.com (10.13.179.162) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6134.19 via Frontend Transport; Thu, 23 Feb 2023 22:35:59 +0000 Received: from p-exchbe-eqx-02.jnpr.net (10.104.9.15) by p-exchfe-eqx-01.jnpr.net (10.104.9.16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.30; Thu, 23 Feb 2023 16:35:58 -0600 Received: from p-mailhub01.juniper.net (10.104.20.6) by p-exchbe-eqx-02.jnpr.net (10.104.9.15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.30 via Frontend Transport; Thu, 23 Feb 2023 16:35:58 -0600 Received: from kaos.jnpr.net (kaos.jnpr.net [172.23.255.201]) by p-mailhub01.juniper.net (8.14.4/8.11.3) with ESMTP id 31NMZuI2014770; Thu, 23 Feb 2023 14:35:57 -0800 (envelope-from sjg@juniper.net) Received: by kaos.jnpr.net (Postfix, from userid 1377) id E41CC2119D; Thu, 23 Feb 2023 14:34:57 -0800 (PST) Received: from kaos.jnpr.net (localhost [127.0.0.1]) by kaos.jnpr.net (Postfix) with ESMTP id E2F9D21028; Thu, 23 Feb 2023 14:34:57 -0800 (PST) To: Mark Millard CC: Bryan Drewery , Current FreeBSD , Peter , Subject: Re: FYI: Why META_MODE rebuilds so much for building again after installworld (no source changes) In-Reply-To: References: <3345EBA5-A09C-4E3F-B94D-39F57F56BDBB@yahoo.com> <73088.1611797582@kaos.jnpr.net> <10819.1677108389@kaos.jnpr.net> <76FA98EF-6184-4D7E-A01F-0EE8117D0D10@yahoo.com> <29887.1677115125@kaos.jnpr.net> <27790339-240F-4C97-97C7-38AFD8DE03D5@yahoo.com> <72419.1677133429@kaos.jnpr.net> <30.1677183903@kaos.jnpr.net> Comments: In-reply-to: Mark Millard message dated "Thu, 23 Feb 2023 13:44:57 -0800." From: "Simon J. Gerraty" X-Mailer: MH-E 8.6+git; nmh 1.7.1; GNU Emacs 28.1 List-Id: Discussions about the use of FreeBSD-current List-Archive: https://lists.freebsd.org/archives/freebsd-current List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-current@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <32946.1677191697.1@kaos.jnpr.net> Content-Transfer-Encoding: quoted-printable Date: Thu, 23 Feb 2023 14:34:57 -0800 Message-ID: <36040.1677191697@kaos.jnpr.net> X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DM6NAM12FT043:EE_|CH2PR05MB7096:EE_ X-MS-Office365-Filtering-Correlation-Id: 1a167c9f-581c-4850-81a3-08db15ee563e X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: fsYj/DMcneuQ106OGI/75LlLj8StZiHUIrRIRc1pephsu/sTDg+tX7Xc6jPHo9Wc52YG6u2lMyn5LeAt3/Dvl7XWspkz/KrHE7Y/LsyoKrdDUDVRrjrtDnAISVLBJD0tSy5VtVTB4TMz5NERXPMxjhsH9CQmrbFqFYPYrCFGTPSbJz7z3mkq5EzyuLQyUaH3UncsTIze4+cNiwtIuzVwhbobzYm7FRLjPWYJO8rNg0V4Z99RJLrgRHFsiQqoArz+YFUMAencEu0nPDv37fn/ZjxY0U8L5Pwojrvco+7CW8vpwmXxEV+KdtNNyDED1MxU22VFktcJ4VJuvzfYAm94ErFjzk1DiefTvYyj+KH/G0C7JcJCCQKGpNAv3Ag6JnYqtD5V2qJXiU2FeDUTSqNKNGYbr2g/cCp7eoykpo8Iu+oZTlLfoFY+p1wECO1yBChwFzSyo/atEj82tlhwi9Q0MyRcnUiNIcCwj/YKMcVxVLy1xWzC2iwiYTeRK0l+9haexYnoPXyy62W1G7a4LncSMBhwO3EzcUFaQ7EO6dIPesYIJwHl38ttIY6qa4mcyqDx4a603RqvAK+IJ4I0e1jO0Y4NIoqc4zDUz6xANmzVOV5re0zKjIVtxUOqYOPXb65orWkDDo/PIK+GmsppGxZHb5cPwzTmmXV1RS2ysr6jU3D0jwwMd3B5tuQhM5re3sEleHArD/hHKy92wjQW2BXDms4VGcMj0hP9r2BORhno6KKgw0hZOzYD/FU/YvZmRUQwRoH+rMfTccQ4jpK2iGawmY6786kKye6xSkIRAfIDCes= X-Forefront-Antispam-Report: CIP:66.129.239.14;CTRY:US;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:p-exchfe-eqx-01.jnpr.net;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230025)(4636009)(346002)(396003)(376002)(136003)(39860400002)(451199018)(46966006)(40470700004)(36840700001)(81166007)(40480700001)(336012)(82740400003)(9686003)(36860700001)(70586007)(40460700003)(26005)(47076005)(7126003)(55016003)(186003)(6266002)(107886003)(2906002)(6916009)(316002)(54906003)(5660300002)(41300700001)(8676002)(4326008)(70206006)(7696005)(356005)(86362001)(82310400005)(8936002)(478600001)(36900700001);DIR:OUT;SFP:1102; X-OriginatorOrg: juniper.net X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Feb 2023 22:35:59.5456 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 1a167c9f-581c-4850-81a3-08db15ee563e X-MS-Exchange-CrossTenant-Id: bea78b3c-4cdb-4130-854a-1d193232e5f4 X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=bea78b3c-4cdb-4130-854a-1d193232e5f4;Ip=[66.129.239.14];Helo=[p-exchfe-eqx-01.jnpr.net] X-MS-Exchange-CrossTenant-AuthSource: DM6NAM12FT043.eop-nam12.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CH2PR05MB7096 X-Proofpoint-ORIG-GUID: QLnWy3qIOWny6Y0QP2635IGwA6RlgEQz X-Proofpoint-GUID: QLnWy3qIOWny6Y0QP2635IGwA6RlgEQz X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.219,Aquarius:18.0.930,Hydra:6.0.562,FMLib:17.11.170.22 definitions=2023-02-23_13,2023-02-23_01,2023-02-09_01 X-Proofpoint-Spam-Details: rule=outbound_spam_notspam policy=outbound_spam score=0 clxscore=1015 impostorscore=0 mlxscore=0 suspectscore=0 malwarescore=0 spamscore=0 bulkscore=0 priorityscore=1501 lowpriorityscore=0 phishscore=0 adultscore=0 mlxlogscore=999 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2212070000 definitions=main-2302230187 X-Rspamd-Queue-Id: 4PN7DB0Fdgz3nRG X-Spamd-Bar: ---- X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:22843, ipnet:67.231.152.0/24, country:US] X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-ThisMailContainsUnwantedMimeParts: N Mark Millard wrote: > [External Email. Be cautious of content] > = > = > [Note for "how many separate bmake instances are in that log?": > I do not know how to tell how many submakes are run total. It > was with -j32 on the threadripper 1950X, if that is was you > were after.] You can get a clue from the number of directories being built - each will have its own instance of bmake. > > Per my last response, I'd be pretty sure MAKEOBJDIR is incorrect. > = > Which still leaves me experimenting to find a correct > reference. Do you know notation will always lead to the > same absolute path with the proper /usr/obj/BUILDs/*/usr/main-src/*.*/ > prefix ? (I've been showing just the main-amd64-nodbg-clang > and amd64.amd64 combination but there are many more.) I would question why you care. What is wrong with ${OBJTOP} ? Hmm, this does not look promising actually: grep '^OBJTOP' share/mk/*mk share/mk/bsd.obj.mk:OBJTOP?=3D ${MAKEOBJDIR} share/mk/bsd.obj.mk:OBJTOP?=3D ${.OBJDIR:S,${.CURDIR},,}${SRCTOP} share/mk/local.meta.sys.mk:OBJTOP:=3D ${OBJROOT}${TARGET_OBJ_SPEC} share/mk/local.meta.sys.mk:OBJTOP :=3D ${HOST_OBJTOP} share/mk/local.sys.mk:OBJTOP?=3D ${.OBJDIR:S,${.CURDIR},,}${SRCTOP} share/mk/src.sys.obj.mk:OBJTOP:=3D ${OBJROOT}${TARGET}.${TARGET_ARCH} share/mk/src.sys.obj.mk:OBJTOP:=3D ${OBJROOT:H} share/mk/src.sys.obj.mk:OBJTOP:=3D ${OBJROOT}${MACHINE}.${MACHINE_ARCH} share/mk/src.sys.obj.mk:OBJTOP:=3D ${OBJROOT:H} share/mk/src.sys.obj.mk:OBJTOP:=3D ${MAKEOBJDIRPREFIX}${SRCTOP} share/mk/src.sys.obj.mk:OBJTOP=3D ${SRCTOP} Without full context, apart from local.meta.sys.mk some of the above looks highly dubious In some respects the BSD build provides way too much flexibility. About 20 years ago at Juniper we found it untenable to continue allowing users 4 different options for the relationship between their srcs and objects. So we simply mandated: SRCTOP=3D ${SB}/src OBJROOT=3D ${SB}/obj/ OBJTOP=3D ${OBJROOT}/${MACHINE}/ MAKEOBJDIR=3D ${.CURDIR:S,${SRCTOP},${OBJTOP},} and life was better, but in a project like FreeBSD you cannot imposed your will that way ;-) > >>>>> .MAKE.META.IGNORE_PATHS+=3D ${OBJTOP}/tmp/ > >>>> > >>>> (Ignoring the variability of OBJTOP issue . . .) > >>>> > >>>> I do not expect that would work: ignoring things > >>>> it likely should not. > >>> > >>> Sure, but it may be useful as an experiment to ensure things are > >>> behaving as expected. > >> > >> As a test: > >> > >> .if ${.MAKE.LEVEL} =3D=3D 0 > >> .MAKE.META.IGNORE_PATHS+=3D ${MAKEOBJDIR:tA}/tmp/ > >> .MAKE.META.IGNORE_PATHS:=3D ${.MAKE.META.IGNORE_PATHS} > >> .endif > > > > Lose the .if ${.MAKE.LEVEL} =3D=3D 0 > > it is almost certainly keeping things from working as expected. > = > What do you want tested instead of MAKEOBJDIR ? I would expect you want ${OBJTOP} (assuming a sane value for OBJTOP ;-) > I'm taking a guess (no .MAKE.LEVEL use): Correct. > = > .MAKE.META.IGNORE_PATHS+=3D ${OBJTOP:tA}/tmp/ > .MAKE.META.IGNORE_PATHS:=3D ${.MAKE.META.IGNORE_PATHS:tA} You do not want to apply :tA to everything. .MAKE.META.IGNORE_PATHS+=3D ${OBJTOP}/tmp/ ${OBJTOP:tA}/tmp/ should be valid. > = > = > >> I still get things like: > >> > >> /usr/obj/BUILDs/main-amd64-nodbg-clang/usr/main-src/amd64.amd64/sys/G= ENERIC-NODBG/modules/usr/main-src/sys/modules/zlib/x86.meta: 23: file '/us= r/obj/BUILDs/main-amd64-nodbg-clang/usr/main-src/amd64.amd64/tmp/legacy/us= r/sbin/realpath' is newer than the target... and is OBJTOP /usr/obj/BUILDs/main-amd64-nodbg-clang/usr/main-src/amd64.am= d64 ? > >> Building /usr/obj/BUILDs/main-amd64-nodbg-clang/usr/main-src/amd64.am= d64/sys/GENERIC-NODBG/modules/usr/main-src/sys/modules/zlib/x86 > > > > Because that will not be level 0 and so .MAKE.META.IGNORE_PATHS is not > > set. > = > I tried the above and I still get (picking to look for > tmp/legacy/usr/sbin/ln examples): > = > /usr/obj/BUILDs/main-amd64-nodbg-clang/usr/main-src/amd64.amd64/sys/GENE= RIC-NODBG/modules/usr/main-src/sys/modules/aac/opt_scsi.h.meta: 22: file '= /usr/obj/BUILDs/main-amd64-nodbg-clang/usr/main-src/amd64.amd64/tmp/legacy= /usr/sbin/ln' is newer than the target... Its a bit messy with kernels since there isn't a src directory associated with each (in FreeBSD anyway) but you could add the following to one of the makefiles that will be in play: .info ${.CURDIR .OBJDIR OBJTOP .MAKE.META.IGNORE_PATHS:L:@v@${.newline}$v=3D= ${$v}@} to help you see what is going on. It should then be easy to see whether OBJTOP is covered by .MAKE.META.IGNORE_PATHS