tech-pkg archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

mk/compiler/ now depends on ccache3

With 2022Q4 branch manager hat on:

Mayuresh reported bulk failures on pkgsrc-users, caused by the increased
dependency footprint of ccache 4.

For now through freeeze end, just depends on ccache3, because
I don't want to deal with any more issues -- my time for pkgsrc is more
limited this minute than usual, and this has already required a bunch
of it.

I have built and installed ccache4 (all the deps were already built
since my main machine has heavy things), and with the new that
installed version is used as expected.

We can discuss how to accomodate both people with low-resource machines
and people that want to run the new version, with any changes happening
post-branch.   I sketched out how I think it should be in

--- Begin Message ---
Module Name:	pkgsrc
Committed By:	gdt
Date:		Fri Dec  9 12:18:56 UTC 2022

Modified Files:

Log Message:
mk/compiler/ Use ccache3

The update to ccache4 caused a large increase in dependencies,
breaking builds using e.g. "PKGSRC_COMPILER=ccache gcc", and the
pre-update discussion of consequences and how to deal with it did not

The right long-term solution is to have a variable to select which
ccache is used, and per-version circular dependency lists, accomoding
both those who wish to use ccache 3 on low-resource machines and those
who wish to use ccache 4.

With 20224 branch manager hat on, I don't want to deal with ccache
instability (or any instability at all now that we are past 12/1), so
I have set to depend on ccache3, the status quo ante

Note that if one has any ccache installed, it will be used, so people
that want to use ccache4 can just install it and then flip on
"PKGSRC_COMPILER=ccache gcc".

To generate a diff of this commit:
cvs rdiff -u -r1.39 -r1.40 pkgsrc/mk/compiler/

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/mk/compiler/
diff -u pkgsrc/mk/compiler/ pkgsrc/mk/compiler/
--- pkgsrc/mk/compiler/	Mon Sep  2 02:23:02 2019
+++ pkgsrc/mk/compiler/	Fri Dec  9 12:18:56 2022
@@ -1,4 +1,4 @@
-# $NetBSD:,v 1.39 2019/09/02 02:23:02 rillig Exp $
+# $NetBSD:,v 1.40 2022/12/09 12:18:56 gdt Exp $
 # Copyright (c) 2004 The NetBSD Foundation, Inc.
 # All rights reserved.
@@ -54,6 +54,14 @@
 # Keywords: ccache
+# \todo We now have two versions of ccache, one with fairly light
+# dependencies and one with heavier dependencies (C++17, cmake, ruby).
+# Obviously some people are going to prefer one and some the other,
+# and thus the right approach is to have a CCACHE_TYPE variable that
+# can mean devel/ccache3 or devel/ccache, and to use that to control
+# both the circular dependency list and the package that is depended
+# on.  For now (meaning the 2022Q4 branch), just set to ccache3.
 .if !defined(COMPILER_CCACHE_MK)
@@ -130,7 +138,7 @@ PREPEND_PATH+=	${_CCACHE_DIR}/bin
 # Add the dependency on ccache.
-TOOL_DEPENDS+=	ccache-[0-9]*:../../devel/ccache
+TOOL_DEPENDS+=	ccache-[0-9]*:../../devel/ccache3
 .  endif
 # Override the compiler-specific hash with the version string for the

--- End Message ---

Home | Main Index | Thread Index | Old Index