Here is a set of patches, for starting discussion... I only build-tested them natively on/for x86_64 (and cross built for aarch64 for the sudo one) On Mon, Mar 30, 2020 at 11:25 PM Vincent Legoll wrote: > > Hello Mathieu, > > On Mon, Mar 30, 2020 at 8:57 AM Mathieu Othacehe wrote: > > > Are those changes useful to do on their own ? > > > > Well yes it may reduce the closure size of the package (run `guix size > > sudo`) to get it. > > I'm not seeing any size difference, but groff is not in the output: > > on master, groff in inputs: > > $ ./pre-inst-env guix size sudo > store item total self > /gnu/store/ahqgl4h89xqj695lgqvsaf6zh2nhy4pj-glibc-2.29 > 37.4 35.8 36.9% > /gnu/store/2plcy91lypnbbysb18ymnhaw3zwk8pg1-gcc-7.4.0-lib > 70.0 32.6 33.7% > /gnu/store/9kzrrccpzl6i1sfwb0drb00gi2gwk0x0-coreutils-8.31 > 90.0 16.5 17.0% > /gnu/store/vsvba1ilj2zj536pvsil6r0mf5rnjj45-sudo-1.8.31p1 > 96.9 3.5 3.6% > /gnu/store/dvs3acxwfnwgc7yma6h3y937ri2li47y-gmp-6.1.2 > 72.6 2.6 2.7% > /gnu/store/vkj5rdiavl87m21d9i0k69rfw79p13gj-linux-pam-1.3.1 > 73.2 2.1 2.2% > /gnu/store/cp72ncw4prnsga65n3pzll07hpsg524f-bash-static-5.0.7 > 1.6 1.6 1.7% > /gnu/store/29jhbbg1hf557x8j53f9sxd9imlmf02a-bash-minimal-5.0.7 > 38.4 1.0 1.1% > /gnu/store/nffbgghxyvrj29lcgxs5fpmi3sx9zzql-acl-2.2.53 > 70.7 0.5 0.5% > /gnu/store/in1738m2zvhgpz78n2yqa972sdzc42ss-attr-2.4.48 > 70.3 0.3 0.3% > /gnu/store/qx7p7hiq90mi7r78hcr9cyskccy2j4bg-zlib-1.2.11 > 70.2 0.2 0.2% > /gnu/store/waw5ci4lazbf2a1x9v6gw1v274nk0gny-libcap-2.27 > 70.2 0.2 0.2% > total: 96.9 MiB > > on a branch with groff in native-inputs: > > $ ./pre-inst-env guix size sudo > store item total self > /gnu/store/ahqgl4h89xqj695lgqvsaf6zh2nhy4pj-glibc-2.29 > 37.4 35.8 36.9% > /gnu/store/2plcy91lypnbbysb18ymnhaw3zwk8pg1-gcc-7.4.0-lib > 70.0 32.6 33.7% > /gnu/store/9kzrrccpzl6i1sfwb0drb00gi2gwk0x0-coreutils-8.31 > 90.0 16.5 17.0% > /gnu/store/l320ig872ny66d1yi6v7n4zb93iz50dx-sudo-1.8.31p1 > 96.9 3.5 3.6% > /gnu/store/dvs3acxwfnwgc7yma6h3y937ri2li47y-gmp-6.1.2 > 72.6 2.6 2.7% > /gnu/store/vkj5rdiavl87m21d9i0k69rfw79p13gj-linux-pam-1.3.1 > 73.2 2.1 2.2% > /gnu/store/cp72ncw4prnsga65n3pzll07hpsg524f-bash-static-5.0.7 > 1.6 1.6 1.7% > /gnu/store/29jhbbg1hf557x8j53f9sxd9imlmf02a-bash-minimal-5.0.7 > 38.4 1.0 1.1% > /gnu/store/nffbgghxyvrj29lcgxs5fpmi3sx9zzql-acl-2.2.53 > 70.7 0.5 0.5% > /gnu/store/in1738m2zvhgpz78n2yqa972sdzc42ss-attr-2.4.48 > 70.3 0.3 0.3% > /gnu/store/qx7p7hiq90mi7r78hcr9cyskccy2j4bg-zlib-1.2.11 > 70.2 0.2 0.2% > /gnu/store/waw5ci4lazbf2a1x9v6gw1v274nk0gny-libcap-2.27 > 70.2 0.2 0.2% > total: 96.9 MiB > > > It can also fix cross-compilation. Because when cross-compiling, if > > groff needs to be run at build-time, it needs to be for the native > > architecture and not the target one. > > > > You can check it by running `guix build --target=aarch64-linux-gnu sudo` > > for instance. > > That fails on master (libpaper) whereas with the patch it works, > so I guess the patch is useful on that front. > > The patch for sudo will be in the following emails. > > Is there anything else to check / test ? > > -- > Vincent Legoll -- Vincent Legoll