guix-devel
[Top][All Lists]
Advanced

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

Re: [PATCH 1/7] build-system: Add cargo build system.


From: Ludovic Courtès
Subject: Re: [PATCH 1/7] build-system: Add cargo build system.
Date: Tue, 13 Dec 2016 23:11:46 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (gnu/linux)

David Craven <address@hidden> skribis:

>> Hmm why is there a second one?  ‘gnu-build-system’ already provides gcc
>> and gcc:lib as implicit inputs, so maybe it’s just a matter of removing
>> ‘gcc’ from Rust’s ‘inputs’?
>
> So we do have an implicit gcc:lib package as an input. But I have to patchelf
> the rustc binaries and libraries so I need a way to retrieve the gcc lib 
> output.
> I can do (assoc-ref inputs "gcc") but how do I get a reference to the
> lib output?
> (assoc-ref* inputs "gcc" "lib") doesn't work... So I add ("gcc:lib"
> ,gcc "lib") explicitly
> to the inputs so that I can retrieve it. This results in slightly
> different versions
> being included.

OK, got it.

Then you should probably be able to do:

  (inputs `(("gcc:lib" ,(canonical-package gcc) "lib") …))

>> When you do ‘guix build rust -s i686-linux’, you get 32-bit packages.
>> Is that enough or am I missing something?
>
> The problem here is that we are patching precompiled binaries for i686 to get
> them to run with guix. So I need to get a reference to a 32-bit glibc
> from within the package definition. I think that we'd have to 
> --enable-multilib.
> I don't know if we can make it a separate output and how we can prevent it
> from being added to %final-inputs by default. And then we need a way of
> obtaining it from within a package definition which amounts to the same
> problem as with gcc:lib.

We don’t currently --enable-multilib, but you could force a reference to
a 32-bit libc with this hack:

  (inputs `(("glibc32" ,(package (inherit glibc)
                          (arguments '(#:system "i686-linux" …))))))

That’s unnecessary when the system is already "i686-linux", of course.

Would that help?

Cheers,
Ludo’.



reply via email to

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