From nobody Wed Sep 13 14:56:30 2023 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 4Rm3SK6hwLz4sZdc; Wed, 13 Sep 2023 14:56:33 +0000 (UTC) (envelope-from jbeich@freebsd.org) Received: from freefall.freebsd.org (freefall.freebsd.org [96.47.72.132]) (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 "freefall.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Rm3SK6GT3z3DQN; Wed, 13 Sep 2023 14:56:33 +0000 (UTC) (envelope-from jbeich@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1694616993; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=+ADB6qq3/BFl0j2bjzkjbcVAlyS1ZKlvsHIyGzrCZLg=; b=XsX5LaS2qeTHfh6PnWwMaM/9l7MG5aeHxV+1Z7MrnZXwNRZurFTKiTVkK094JOhzWdpkv7 7RQ9OuDjHOJ+hnSjvpCiBcqUt5UI2H3o0cL+t56NhRNFQ3rK3UzOOSarxDfG8h0Vfw53jH Us1zS8KD3xTS3IV2TDuHRauWqC0uKt3j3FeGD3WXXQJ7bgZcWA4I1OKKvYJJYJ6YOyC6Hg 5uxfuQxxWdo+p6RwZAuHYUC0AUHOooIjH1tM52RG7Hmnc3WCcxie8pRr49Y/lUek5PUdBj ZWzdeDgZxYHJkOXPM3/CVDiYqYWR665KX49jbvsI/4Gxaxpb/6wfFLo/EQzxWw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1694616993; a=rsa-sha256; cv=none; b=gSTJdooLyqHW9O1bUcI61BEEwJhwRvjLP6A00zaVGFCQZkjgtJmbP3Fb7OH0tiJK02pj3y s4xwaO1AcUlyk5UB4yp5omxAWNde+CVApH42bxlKvblDa/kzf2rZ8MDEeZGGzJM1RvffNI fyt0AbU94J26jQ3gZrnDAexxRd91jJeCRfCAWB6PBRO7tKM6HSREzpoxxHJjPeeJnEMQPQ yyfXzAoHbli6ckedbV4e3V2Rhq6B517QBhtidgVNJNSY2pXkoPT/HVWD0SPv4Eor5G/qBk n9rDlmBoMVU7Jfg/mCufQYfvmoBdjR0BBP3To5PS7RLJmFNaTt5CWHyLaAu0/w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1694616993; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=+ADB6qq3/BFl0j2bjzkjbcVAlyS1ZKlvsHIyGzrCZLg=; b=XNBedfub+kXIjWlB8snNX2KGSCCubyqtLkqqywCrVKwR2uP6aROdM4P/EhWK6qTN2XDEOf jtGZs9GlofD5BWF9cjzpcqzo1AnYc1vktRQpAqis1ktvqJMYbzUnaznOCQYJuzulIdpuTG zAVgDyd0Lapavt26zDPeBAEGDfZTDrIY5YmLtrKO0M/1zLVLq6Rd6g2h5zMLY23Iz4qEw2 XZRNyQiaAX8gKwznLJxfRGcxVvFdekn7wAI3CaEck/RWepbI2k4sFSZ1Y+TVIjzjJhnoJI wl2V/h/K8lsnXS8autuI8QrWPI1SxKSOruzNPESCyEV15AsHQheKd235yNNkQA== Received: by freefall.freebsd.org (Postfix, from userid 1354) id B2E899C36; Wed, 13 Sep 2023 14:56:33 +0000 (UTC) From: Jan Beich To: Emmanuel Vadot Cc: Gleb Popov , "Tobias C. Berner" , ports-committers@freebsd.org, dev-commits-ports-all@freebsd.org, dev-commits-ports-main@freebsd.org Subject: Re: git: 4df0e66a3662 - main - llvm.mk: add export/noexport to handle CC/CXX/CPP exports In-Reply-To: (Jan Beich's message of "Wed, 13 Sep 2023 13:22:50 +0200") References: <202309130518.38D5INm2018105@gitrepo.freebsd.org> <20230913102352.b641f29cd7cb76f2937d1a61@bidouilliste.com> Date: Wed, 13 Sep 2023 16:56:30 +0200 Message-ID: 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 Jan Beich writes: > Emmanuel Vadot writes: > >> On Wed, 13 Sep 2023 08:55:48 +0300 >> Gleb Popov wrote: >> >>> On Wed, Sep 13, 2023 at 8:20?AM Tobias C. Berner wrote: >>> > >>> > + USES=llvm.mk now supports 'export' (default) and 'noexport' arguments. >>> > + When export is set, CC, CXX and CPP will be set to the path corresponding >>> > + to the chosen llvm-version. >>> >>> The choice for the default seems strange to me. Now every port that >>> has USES=llvm will be switching to building with a non-base compiler. >>> Is this really a sensible default? >> >> Isn't that what you want when you add USES=llvm ? > > Changing CC is USES=compiler job. Contributors starting using USES=llvm > for changing Clang version because USES=compiler is poorly maintained. > > I predominantly add USES=llvm to satisfy libLLVM (mesa-devel, rpcs3) or > libclang (USES=cargo + CARGO_CRATES=bindgen). In a few cases when I need > newer Clang (for C++20 std:ranges, C++23) I also need newer libc++ but > devel/llvm* maintainer refuses to provide libc++ (bug 260139). > > Forcing CC/CXX/CPP without testing all consumers has a chance of > introducing regressions. For example, when using LTO it's important to > make sure CMake doesn't pick up /usr/bin/llvm-ar or /usr/bin/llvm-ranlib > because those may not support LLVM bitcode used by devel/llvm*. > > https://cgit.freebsd.org/ports/commit/?id=5e71e4d45129 > https://cgit.freebsd.org/ports/commit/?id=2ce01a07d7c9 > > While the affected ports had LTO enabled by default there's also > WITH_LTO knob handled by /usr/ports/Mk/Features/lto.mk. D37747 had TEST PLAN with "Actually test", SUMMARY with "Heavily WIP", said :lib wasn't affected and limited port Clang to older base Clang. The mini exp-run by a reviewer was limited to "the specific ports of interest" thus didn't cover all consumers (let alone all ports). For example, I've discovered this broke one of my ports: https://cgit.freebsd.org/ports/commit/?id=391f28644973 The commit message is no better: didn't mention the new default is "export". For example, FreeBSD >= 14.0 now uses port Clang 15 instead of base Clang 16. This may degrade optimization slightly, assuming Clang improves each version.