Subject: [bug#36346] [PATCH] gnu: Allow building toolchain with non-default libc.

From: Marius Bakke <[email-masked]>
Date: Sat, 06 Jul 2019 00:46:56 +0200

Carl Dong <[email-masked]> writes:

> From: Carl Dong <[email-masked]>
>
> * gnu/packages/base.scm (make-gcc-libc): Make public.
> * gnu/packages/commencement.scm (make-gcc-toolchain): Add 'libc'
>   optional argument to specify using a non-default glibc package, also
>   make public.

It would be easier to digest this patch if it came with an actual user
of this change.  Right now it complicates a very simple procedure for no
apparent reason.  Can you elaborate a bit on the use case?

Guix excels at creating bespoke toolchains like these.  It is easy to
express this change as a new 'make-gcc-toolchain-with-custom-libc'
procedure.  So I'm not sure if it's worth changing 'make-gcc-toolchain',
which serves a fairly specific use case.

I would expect any reasonably complex toolchain to need further tweaks,
and we cannot possibly support all such configuration inside
'make-gcc-toolchain'.

Does that make sense?

It does sound useful to make these procedures more generally accessible
however.  Perhaps 'make-gcc-toolchain' could be implemented in terms of
a more generic 'make-toolchain' interface?