[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CANiq72n3qnWwDjp0E1xY1m15qhMHz8_AXcL9hstVM8Xwfi=pbw@mail.gmail.com>
Date: Wed, 4 Jan 2023 02:55:59 +0100
From: Miguel Ojeda <miguel.ojeda.sandonis@...il.com>
To: Jonathan Corbet <corbet@....net>
Cc: Carlos Bilbao <carlos.bilbao@....com>, ojeda@...nel.org,
akiyks@...il.com, jani.nikula@...ux.intel.com,
rdunlap@...radead.org, linux-doc@...r.kernel.org,
linux-kernel@...r.kernel.org, konstantin@...uxfoundation.org
Subject: Re: [PATCH v5 0/2] docs: Integrate rustdoc into Rust documentation
On Wed, Jan 4, 2023 at 1:25 AM Jonathan Corbet <corbet@....net> wrote:
>
> Does it really need objtool?
No, it does not. That is a byproduct of using the `prepare` target to
setup Rust for the descend, but we could rearrange some things for
`rustdoc`.
> A certain amount of extra building is OK as long as it doesn't radically
> slow down the (already glacial) docs build. I'd like it to not *break*
> the docs build if the right dependencies aren't there, though.
I agree if we go with a fixed/preset/configless approach, because in
that case we will always have `CONFIG_RUST=y` and therefore the
generation of Rust docs is really just an attempt that may or may not
fail (or we could only attempt to do so if the dependencies are met
exactly as expected).
On the other hand, if we went with the current setup, where a config
is used, then if the user has specified `CONFIG_RUST=y`, I think it is
fair to fail, since the operation cannot be completed, just like the
normal build. Of course, we could also do the "just attempt it"
approach and print a loud message if it failed, but I think, as a
user, would still prefer as a user if it just failed.
> It seems like that step should fail regardless, not just for the docs
> build, no?
The bindgen step should fail the same way for both normal builds and
docs, indeed.
I think I understand now what you meant by "fail more gracefully". I
thought you meant fail with a better/proper message given versioning
information or similar, but you primarily meant avoid breaking the
entire docs build if the Rust part fails, right?
Cheers,
Miguel
Powered by blists - more mailing lists