As promised, I've been completely renovating mk/compiler/gcc.mk to
hopefully reduce a lot of the complexity, make it less likely that
future changes will result in accidental breakage, add numerous
comments, as well as improving performance.
The branch is here:
https://github.com/NetBSD/pkgsrc/compare/trunk...TritonDataCenter:pkgsrc:feature/gcc-selection/trunk
Overview:
* Move GCC_REQD and associated logic into a separate file.
* If the user has requested USE_NATIVE_GCC=yes then skip all of the
GCC_REQD processing.
* Add support for GCC_BOOTSTRAP_PKGS, a list of PKGPATH packages that
are in the dependency path for gcc and gcc-libs, making it easier
for users to avoid circular dependencies when USE_PKGSRC_GCC=yes.
* Make it easier for users to select their own GCC packages, e.g.
from wip or other repositories.
* Remove _USE_GCC_SHLIB and USE_GCC_RUNTIME, and simply enable based
on USE_PKGSRC_GCC_RUNTIME, with the same exclusions as above.
Removing USE_GCC_RUNTIME from individual packages can be done later.
* Remove ALLOW_NEWER_COMPILER, it essentially duplicates the
USE_NATIVE_GCC logic and confuses things.
* Remove bogus _LANGUAGES setup, assume GCC packages support all
languages, and simplify.
* Simplify GCC version detection, reducing number of forks, and remove
support for long-obsolete compilers.
* Simplify NetBSD USE_PKGSRC_GCC_RUNTIME selection.
* Rename a bunch of variables to make it clearer what they actually
do.
* Use newer make syntax.
* Stop trying to support NetBSD < 1.5.
This will obviously require lots of testing before it even goes near the
tree, but I would appreciate feedback on any of the more contentious
parts, and obviously testing would be fantastic too.
Just a quick note to say thanks for doing this, Jonathan.
I like the simplifications, and also the GCC_BOOTSTRAP_PACKAGES definition - nice!
In passing, I also think the use of ":tl" modifier could be made much more widespread in pkgsrc - it makes things so much clearer. And I think that we can probably assume it will be out there by now.
revision 1.68
date: 2002-02-06 08:26:12 -0800; author: pk; state: Exp; lines: +50 -3;
Add `tu' and `tl' variable expansion modifiers, which transform the
value to uppercase and lowercase, respectively. From Kevin Neal from FreeBSD.
Thanks once again,
Alistair