GNU bug report logs -
#33465
[PATCH] gnu: rust: Don't depend on 'git'.
Previous Next
Reported by: Marius Bakke <mbakke <at> fastmail.com>
Date: Thu, 22 Nov 2018 13:59:02 UTC
Severity: normal
Tags: patch
Done: Marius Bakke <mbakke <at> fastmail.com>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 33465 in the body.
You can then email your comments to 33465 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
guix-patches <at> gnu.org
:
bug#33465
; Package
guix-patches
.
(Thu, 22 Nov 2018 13:59:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Marius Bakke <mbakke <at> fastmail.com>
:
New bug report received and forwarded. Copy sent to
guix-patches <at> gnu.org
.
(Thu, 22 Nov 2018 13:59:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
* gnu/packages/rust.scm (rust-1.19)[inputs]: Remove GIT.
(rust-1.20)[arguments]: Disable Cargo tests that require git.
(rust-1.26)[arguments]: Likewise.
---
Notes:
Guix,
The Rust toolchain is very expensive to build and needs less volatility.
So far I have only built up to Rust 1.23 with this patch. I suggest
applying this on 'core-updates', and giving Rust in 'master' a
git-2.19.1 input to the previous substitutes are valid again.
WDYT?
gnu/packages/rust.scm | 15 +++++++++++++--
1 file changed, 13 insertions(+), 2 deletions(-)
diff --git a/gnu/packages/rust.scm b/gnu/packages/rust.scm
index a56faad07..ae41a7dd3 100644
--- a/gnu/packages/rust.scm
+++ b/gnu/packages/rust.scm
@@ -41,7 +41,6 @@
#:use-module (gnu packages python)
#:use-module (gnu packages ssh)
#:use-module (gnu packages tls)
- #:use-module (gnu packages version-control)
#:use-module (gnu packages)
#:use-module (guix build-system cargo)
#:use-module (guix build-system gnu)
@@ -387,7 +386,6 @@ test = { path = \"../libtest\" }
("cmake" ,cmake)
("flex" ,flex) ; For the tests
("gdb" ,gdb) ; For the tests
- ("git" ,git)
("procps" ,procps) ; For the tests
("python-2" ,python-2)
("rustc-bootstrap" ,mrustc)
@@ -446,6 +444,13 @@ safety and thread safety guarantees.")
;; i686-linux.
(substitute* "src/tools/cargo/tests/test.rs"
(("fn cargo_test_env") "#[ignore]\nfn cargo_test_env"))
+
+ ;; These tests pull in a dependency on "git", which changes
+ ;; too frequently take part in the Rust toolchain.
+ (substitute* "src/tools/cargo/tests/new.rs"
+ (("fn author_prefers_cargo") "#[ignore]\nfn author_prefers_cargo")
+ (("fn finds_author_git") "#[ignore]\nfn finds_author_git")
+ (("fn finds_local_author_git") "#[ignore]\nfn finds_local_author_git"))
#t))
(add-after 'patch-cargo-tests 'ignore-glibc-2.27-incompatible-test
;; https://github.com/rust-lang/rust/issues/47863
@@ -678,6 +683,12 @@ jemalloc = \"" jemalloc "/lib/libjemalloc_pic.a" "\"
;; i686-linux.
(substitute* "src/tools/cargo/tests/testsuite/test.rs"
(("fn cargo_test_env") "#[ignore]\nfn cargo_test_env"))
+
+ ;; Avoid dependency on "git".
+ (substitute* "src/tools/cargo/tests/new.rs"
+ (("fn author_prefers_cargo") "#[ignore]\nfn author_prefers_cargo")
+ (("fn finds_author_git") "#[ignore]\nfn finds_author_git")
+ (("fn finds_local_author_git") "#[ignore]\nfn finds_local_author_git"))
#t))
(add-after 'patch-cargo-tests 'disable-cargo-test-for-nightly-channel
(lambda* _
--
2.19.1
Information forwarded
to
guix-patches <at> gnu.org
:
bug#33465
; Package
guix-patches
.
(Thu, 22 Nov 2018 14:08:01 GMT)
Full text and
rfc822 format available.
Message #8 received at submit <at> debbugs.gnu.org (full text, mbox):
Le 2018-11-22 14:58, Marius Bakke a écrit :
> * gnu/packages/rust.scm (rust-1.19)[inputs]: Remove GIT.
> (rust-1.20)[arguments]: Disable Cargo tests that require git.
> (rust-1.26)[arguments]: Likewise.
> ---
>
> Notes:
> Guix,
>
> The Rust toolchain is very expensive to build and needs less
> volatility.
>
> So far I have only built up to Rust 1.23 with this patch. I
> suggest
> applying this on 'core-updates', and giving Rust in 'master' a
> git-2.19.1 input to the previous substitutes are valid again.
>
> WDYT?
Hi, I don't really know how our rust packages are built, but I wonder if
they have more than the bare minimum optional features for our purposes
(apart from 1.24 used by icecat and the latest version, we probably
don't need to build everything)? Maybe it's worth investigating if that
can speed up the build of the whole chain. It seems we're two versions
behind current rust too. Is anyone working on packaging them?
>
> gnu/packages/rust.scm | 15 +++++++++++++--
> 1 file changed, 13 insertions(+), 2 deletions(-)
>
> diff --git a/gnu/packages/rust.scm b/gnu/packages/rust.scm
> index a56faad07..ae41a7dd3 100644
> --- a/gnu/packages/rust.scm
> +++ b/gnu/packages/rust.scm
> @@ -41,7 +41,6 @@
> #:use-module (gnu packages python)
> #:use-module (gnu packages ssh)
> #:use-module (gnu packages tls)
> - #:use-module (gnu packages version-control)
> #:use-module (gnu packages)
> #:use-module (guix build-system cargo)
> #:use-module (guix build-system gnu)
> @@ -387,7 +386,6 @@ test = { path = \"../libtest\" }
> ("cmake" ,cmake)
> ("flex" ,flex) ; For the tests
> ("gdb" ,gdb) ; For the tests
> - ("git" ,git)
> ("procps" ,procps) ; For the tests
> ("python-2" ,python-2)
> ("rustc-bootstrap" ,mrustc)
> @@ -446,6 +444,13 @@ safety and thread safety guarantees.")
> ;; i686-linux.
> (substitute* "src/tools/cargo/tests/test.rs"
> (("fn cargo_test_env") "#[ignore]\nfn
> cargo_test_env"))
> +
> + ;; These tests pull in a dependency on "git", which
> changes
> + ;; too frequently take part in the Rust toolchain.
> + (substitute* "src/tools/cargo/tests/new.rs"
> + (("fn author_prefers_cargo") "#[ignore]\nfn
> author_prefers_cargo")
> + (("fn finds_author_git") "#[ignore]\nfn
> finds_author_git")
> + (("fn finds_local_author_git") "#[ignore]\nfn
> finds_local_author_git"))
> #t))
> (add-after 'patch-cargo-tests
> 'ignore-glibc-2.27-incompatible-test
> ;; https://github.com/rust-lang/rust/issues/47863
> @@ -678,6 +683,12 @@ jemalloc = \"" jemalloc "/lib/libjemalloc_pic.a"
> "\"
> ;; i686-linux.
> (substitute*
> "src/tools/cargo/tests/testsuite/test.rs"
> (("fn cargo_test_env") "#[ignore]\nfn
> cargo_test_env"))
> +
> + ;; Avoid dependency on "git".
> + (substitute* "src/tools/cargo/tests/new.rs"
> + (("fn author_prefers_cargo") "#[ignore]\nfn
> author_prefers_cargo")
> + (("fn finds_author_git") "#[ignore]\nfn
> finds_author_git")
> + (("fn finds_local_author_git") "#[ignore]\nfn
> finds_local_author_git"))
> #t))
> (add-after 'patch-cargo-tests
> 'disable-cargo-test-for-nightly-channel
> (lambda* _
Information forwarded
to
guix-patches <at> gnu.org
:
bug#33465
; Package
guix-patches
.
(Fri, 23 Nov 2018 12:06:02 GMT)
Full text and
rfc822 format available.
Message #11 received at 33465 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Hi Julien and Marius,
Julien Lepiller writes:
> Le 2018-11-22 14:58, Marius Bakke a écrit:
>> * gnu/packages/rust.scm (rust-1.19)[inputs]: Remove GIT.
>> (rust-1.20)[arguments]: Disable Cargo tests that require git.
>> (rust-1.26)[arguments]: Likewise.
>> ---
>>
>> Notes:
>> Guix,
>>
>> The Rust toolchain is very expensive to build and needs less
>> volatility.
>>
>> So far I have only built up to Rust 1.23 with this patch. I
>> suggest
>> applying this on 'core-updates', and giving Rust in 'master' a
>> git-2.19.1 input to the previous substitutes are valid again.
>>
>> WDYT?
>
> Hi, I don't really know how our rust packages are built, but I wonder
> if they have more than the bare minimum optional features for our
> purposes (apart from 1.24 used by icecat and the latest version, we
> probably don't need to build everything)? Maybe it's worth
> investigating if that can speed up the build of the whole chain.
One thing I've been wondering about would be to remove the 'check phase
when building a rust that will be used for bootstrapping only. Since the
tests are not ran in parallel, they take a huge amount of time.
See attached patched, I'm testing it now. It's currently building
rust <at> 1.23. WDYT?
Thanks,
Pierre
[0001-gnu-rust-Do-not-run-tests-when-building-for-bootstra.patch (text/x-patch, attachment)]
Information forwarded
to
guix-patches <at> gnu.org
:
bug#33465
; Package
guix-patches
.
(Fri, 23 Nov 2018 16:27:02 GMT)
Full text and
rfc822 format available.
Message #14 received at 33465 <at> debbugs.gnu.org (full text, mbox):
> From 46233c5f6ced0ad5e535a848527ad35309535b97 Mon Sep 17 00:00:00 2001
> From: Pierre Langlois <pierre.langlois <at> gmx.com>
> Date: Fri, 23 Nov 2018 11:58:06 +0000
> Subject: [PATCH] gnu: rust: Do not run tests when building for bootstrapping.
>
> * gnu/packages/rust.scm (rust-bootstrapped-package): Add 'arguments' field
> that removes the check phase.
Whoops, ignore that patch, it doesn't do what I wanted it to do. The
point was to skip the tests *only* for temporary packages used for
bootstrapping the final one. But here it's disabled the tests all the
time, we don't want that... my bad! I'll another look when I have time.
Thanks,
Pierre
Information forwarded
to
guix-patches <at> gnu.org
:
bug#33465
; Package
guix-patches
.
(Fri, 23 Nov 2018 17:48:01 GMT)
Full text and
rfc822 format available.
Message #17 received at 33465 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Pierre Langlois writes:
> Whoops, ignore that patch, it doesn't do what I wanted it to do. The
> point was to skip the tests *only* for temporary packages used for
> bootstrapping the final one. But here it's disabled the tests all the
> time, we don't want that... my bad! I'll another look when I have time.
Right, attached is what I meant to do.
Thanks!
Pierre
[0001-gnu-rust-Do-not-run-tests-when-building-for-bootstra.patch (text/x-patch, attachment)]
Reply sent
to
Marius Bakke <mbakke <at> fastmail.com>
:
You have taken responsibility.
(Sat, 24 Nov 2018 01:10:02 GMT)
Full text and
rfc822 format available.
Notification sent
to
Marius Bakke <mbakke <at> fastmail.com>
:
bug acknowledged by developer.
(Sat, 24 Nov 2018 01:10:03 GMT)
Full text and
rfc822 format available.
Message #22 received at 33465-done <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Pierre Langlois <pierre.langlois <at> gmx.com> writes:
> Pierre Langlois writes:
>
>> Whoops, ignore that patch, it doesn't do what I wanted it to do. The
>> point was to skip the tests *only* for temporary packages used for
>> bootstrapping the final one. But here it's disabled the tests all the
>> time, we don't want that... my bad! I'll another look when I have time.
>
> Right, attached is what I meant to do.
Hello!
I don't have a strong opinion for or against disabling tests in the Rust
bootstrap toolchain. But with Git removed, most (all?) of Rusts
dependencies are packages that do not change very frequently (i.e. only
on the 'staging' and 'core-updates' branches), so maybe it's not as
urgent?
Regardless, I've pushed the original patch to the 'core-updates'
branch. Could you submit the other patch to a separate issue or to
guix-devel? TIA!
[signature.asc (application/pgp-signature, inline)]
Information forwarded
to
guix-patches <at> gnu.org
:
bug#33465
; Package
guix-patches
.
(Sat, 24 Nov 2018 21:46:01 GMT)
Full text and
rfc822 format available.
Message #25 received at 33465-done <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Hi,
I'd prefer if the git parts were removed in a new phase "remove-git-tests" and
that phase removed (ha) in the newest rust - otherwise we never test rust git
integration.
Then the substitution wouldn't need to be duplicated either.
[Message part 2 (application/pgp-signature, inline)]
Information forwarded
to
guix-patches <at> gnu.org
:
bug#33465
; Package
guix-patches
.
(Sun, 25 Nov 2018 11:54:01 GMT)
Full text and
rfc822 format available.
Message #28 received at 33465-done <at> debbugs.gnu.org (full text, mbox):
Hi Danny,
Danny Milosavljevic writes:
> Hi,
>
> I'd prefer if the git parts were removed in a new phase "remove-git-tests" and
> that phase removed (ha) in the newest rust - otherwise we never test rust git
> integration.
>
> Then the substitution wouldn't need to be duplicated either.
Alternatively, if we go with removing tests althogether when building
rust for bootstrapping, we can also remove non-essential native inputs
such as git and gdb. And then we can keep all of them for the final
rust.
As with Marius, I don't have a strong opinion on this, I just thought
I'd mention it as a possibility to speedup rust's build process. I can
submit a patch in a separate ticket if you think it's a good idea.
Thanks!
Pierre
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Sun, 23 Dec 2018 12:24:05 GMT)
Full text and
rfc822 format available.
This bug report was last modified 6 years and 260 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.