[Top][All Lists]

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

Re: building package: gcc 7.5.0 referenced instead of latest gcc; not su

From: Chris Marusich
Subject: Re: building package: gcc 7.5.0 referenced instead of latest gcc; not sure why
Date: Wed, 24 Feb 2021 02:24:51 -0800
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux)

Hi Andy,

Andy Tai <> writes:

> I tried to update a package definition (vtk) and then tried to build it
> ./pre-inst-env guix build -k -K vtk
> and the log file shows gcc 7.5 being used

The vtk package uses the cmake-build-system, which like every build
system adds some inputs to the build implicitly.  One of those "implicit
inputs" is gcc-final, defined in gnu/packages/commencement.scm, and it
happens to be GCC 7.5:

  scheme@(guix-user)> (@@ (gnu packages commencement) gcc-final)
  $1 = #<package gcc@7.5.0 gnu/packages/commencement.scm:3561 7fe14101d780>

To see how the cmake-build-system adds gcc-final as an implicit input,
you can start by looking at guix/build-system/cmake.scm.  In short, the
"lower" procedure returns a bag, and it adds the inputs produced by the
standard-packages procedure to the returned bag.  The standard-packages
procedure is defined in guix/build-system/gnu.scm (the
cmake-build-system re-uses many parts of the gnu-build-system), and it
returns %final-inputs, which is defined in gnu/packages/commencement.
It is here that the "gcc" input is bound to gcc-final.

I don't know why gcc-final is still GCC 7.5 rather than a more recent
version, but I suspect it is related to the fact that upgrading
gcc-final would cause virtually every package to be rebuilt.  For that
reason, we probably don't upgrade it often.


Attachment: signature.asc
Description: PGP signature

reply via email to

[Prev in Thread] Current Thread [Next in Thread]