[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 1/7] build-system: Add cargo build system.
From: |
David Craven |
Subject: |
Re: [PATCH 1/7] build-system: Add cargo build system. |
Date: |
Tue, 13 Dec 2016 19:07:17 +0100 |
> 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.
guix size rustc-bootstrap
/gnu/store/fafzikyzhwbryqxxqsbsdkkq47rfrd8z-rustc-bootstrap-1.12.1
414.6 240.4 58.0%
/gnu/store/y1g6991kxvdk4vxhsq07r5saww30v8dq-gcc-4.9.4
138.6 77.2 18.6%
/gnu/store/a64w9dq219a8d9k4mfz76mnzph9wsvfj-zlib-1.2.8
61.3 0.4 0.1%
/gnu/store/q4a1z2arssij8iq80i4k0zqallqlh2lv-gcc-4.9.4-lib
61.1 22.8 5.5%
/gnu/store/cdi08kw7r6r684w8mk0xq0dkgpjhfpmd-gcc-4.9.4-lib
61.0 22.7 5.5%
/gnu/store/qkw4zrwfybxww8f56nkb6hggxambk89b-bash-4.4.0
50.7 5.4 1.3%
/gnu/store/bm0gfw4jkw8gd0vpnnzrb6z0xncrbx3p-readline-7.0
45.3 1.3 0.3%
/gnu/store/hdrli1v7q3107w842s7di8rid82xlfvl-ncurses-6.0
44.0 5.7 1.4%
/gnu/store/vxdm2dqckv3yvwihr4hs6f886v6104az-zlib-1.2.8
38.6 0.4 0.1%
/gnu/store/iwgi9001dmmihrjg4rqhd6pa6788prjw-glibc-2.24
38.3 36.8 8.9%
/gnu/store/rvgmixpmsq5lqr9qflhkm70kg7a4rys2-bash-static-4.4.0
1.4 1.4 0.3%
total: 414.6 MiB
I also don't know why there are two zlib's in there.
guix gc --referrers /gnu/store/vxdm2dqckv3yvwihr4hs6f886v6104az-zlib-1.2.8
/gnu/store/vxdm2dqckv3yvwihr4hs6f886v6104az-zlib-1.2.8
/gnu/store/y1g6991kxvdk4vxhsq07r5saww30v8dq-gcc-4.9.4
guix gc --referrers /gnu/store/q4a1z2arssij8iq80i4k0zqallqlh2lv-gcc-4.9.4-lib
/gnu/store/59fld0ah99fn7fc5vfsn51dm4b7x401g-clang-3.8.1
/gnu/store/d5vl2fljy7vlhz51yccw8y76yw8rzjrc-cargo-bootstrap-0.13.0
/gnu/store/fafzikyzhwbryqxxqsbsdkkq47rfrd8z-rustc-bootstrap-1.12.1
/gnu/store/q4a1z2arssij8iq80i4k0zqallqlh2lv-gcc-4.9.4-lib
Maybe it doesn't matter too much, I was just curious that's all :)
> 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.