Chris Marusich <cmmarus...@gmail.com> writes:

> configure:6100: error: cannot compute sizeof (long long)

It was mentioned on IRC that a better way to fix this would be to
configure libstdc++ to install to /lib instead of /lib64, since in Guix
we install libraries to /lib by convention, even on 64-bit systems.

See: https://logs.guix.gnu.org/guix/2021-02-06.log

I looked into this a bit more after that.  It turns out that we do
something like that already, in the original gcc package definition, for
existing architectures.  However, Léo pointed out that on the rs6000
architecture (i.e., powerpc), the gcc/config/rs6000 directory's build
logic hard-codes some /lib64 references.  I have added a phase that
replaces those hard-coded references. I should also mention that I did
try to use the --libdir configure flag to tell libstdc++ to install to
/lib64, but it didn't work; libstdc++ just ignored the flag and still
installed its libraries in /lib64.  Replacing the hard-coded references
fixed it, though.

In addition, I discovered that the libstdc++ package does not actually
re-use the package arguments from gcc.  Therefore, it was necessary to
add a similar phase in the make-libstdc++ procedure.

Although it is possible that, to resolve this specific bug (gcc-final:
"configure: error: cannot compute sizeof (long long)"), only the
make-libstdc++ change is necessary, it seems prudent to go ahead and
also make the change described above for gcc, to avoid future problems.
I have pushed both changes to wip-ppc64le in commit
db761a593992aea441055bda260461f4302a4667 on the wip-ppc64le branch.


-- 
Chris

Attachment: signature.asc
Description: PGP signature

Reply via email to