Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp481068rwb; Thu, 1 Dec 2022 04:50:51 -0800 (PST) X-Google-Smtp-Source: AA0mqf7/DSv564vT87lqr8ThrK7x+jubOvYFLigmka58lQembwVCEreho8qZorNZqMXj2lrkoghq X-Received: by 2002:a17:907:111a:b0:7c0:8b49:650b with SMTP id qu26-20020a170907111a00b007c08b49650bmr10830328ejb.23.1669899051457; Thu, 01 Dec 2022 04:50:51 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669899051; cv=none; d=google.com; s=arc-20160816; b=WqPrwCibrnR/TxRBseasBDfd0GWCiczYCzOYG+BwHyjJ2eWO7ky67zgI/lBgnruJnd 8xYTXXK6y/KFQR0oa/OjRg5zRZtrwb6qsopKWSnHwpaDX4ofbUHR4+hX9aCb2lKrb325 iaMzhFqiShZN24aEGJ5YTo/9WH+SUfZtc7fyHnbMG/ipD97HV10G4lZzdXZUfc14wDKo M0NMo7ag4qZjFPhibBGVacr+fH57i67rzC0Smtf79LK7jvAJRCQ42lsShicgmnDi3xeM BHmD95WlpxnvVvvbMKCXrYFAZsPaBDbwq4xBp5zgDpUOUfYEgDE8A8UO8+yv+dFEMDnT 0iMw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=gZLFHPHmu42F5vgCZp4ijmCKeW/Bp2vfBJ56tLv98tY=; b=jfsxvoKXZNA2lgnErXfQGbySMUERjhdPmm2qm4cYw1h8cT07zKJ3Yx+6w5j/Sge2Wh zKxCbjIU2QyvDzjRvSco2IMPTwl92VQGkDL0RiU4d3cREa5UyOMIpSPl/MvVdT1cRRm0 nzeLWeaQPikVBZYi1Je/FK3Yilk2HbsU/uby+rH+fLdo/iL4kUrudWGxQufD3wtHJzYa gKvwo6RyLZa9kCS240hI4qdt7Y00DdXVT+LF1RujvoC2yHSVJgOW5qzQ8WfsOlDIWepe FDDH316JkDefvtD2EEGc96db9r7t88kF//eiJ9Bg4kknDiTFDL02ywPqVR4JemoE1INu LWrg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=kg0NfjNL; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id i10-20020a170906264a00b007c07a807a78si2829498ejc.215.2022.12.01.04.50.30; Thu, 01 Dec 2022 04:50:51 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=kg0NfjNL; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230159AbiLAMmc (ORCPT + 82 others); Thu, 1 Dec 2022 07:42:32 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53754 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231450AbiLAMmW (ORCPT ); Thu, 1 Dec 2022 07:42:22 -0500 Received: from mail-yb1-xb29.google.com (mail-yb1-xb29.google.com [IPv6:2607:f8b0:4864:20::b29]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7B3558C681; Thu, 1 Dec 2022 04:42:20 -0800 (PST) Received: by mail-yb1-xb29.google.com with SMTP id v206so1856304ybv.7; Thu, 01 Dec 2022 04:42:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=gZLFHPHmu42F5vgCZp4ijmCKeW/Bp2vfBJ56tLv98tY=; b=kg0NfjNL+OZtMi114IVofJvt6YDQkbGAEpaviVRhPdIjwYYviGV2s3k43+qZF1bYj+ PZvcJoRTQZb7jt0VFVy6VxVIU+mKeStj/sw82fnqzlsBsaTM6SiZlmUblJqG7vGgY63n fnP/0Sbn57tfS23JPWy9myf87Ev7eGvIhH62f/rcucBwbnzRZEb1zAmKIWaodf4XrZkr 0yzHIEUQE7/nu520vdvk4z2EUr+3EjiM/bKfq5fN0wkXiuD07lWCn9TYf2w5JDmvEbvW rKqbLRg7zA5ZIqTxC+EgOOjN14v74AAvaffr8BGGBZ9K/GU2D2sfIyC4VFIGM4SLtUxh 1aSQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=gZLFHPHmu42F5vgCZp4ijmCKeW/Bp2vfBJ56tLv98tY=; b=MHXzGojgphhFusO0IdIK58XexMagUwG9g2D3s5tfybuUUeybQp4cFMb5gfrPN6SYi7 E1m5hgdMe9ozI11QSa3NON4atrU9VwS7XT5MRCafyIQt7HvhxgpplN1aVzZid5gLL1jt MGifPNxyg6z7Zaa6RlHbwEa2668DlEC5shhhUwHDVI14l2IKKD9f2BimCFStOzos4gn1 kKXlexOMSnepo8n/uEwxbxyZHTm9TW+LCMQ3+4izbwUhjV4M0TJCDkT1nN+ZZ2bw0KGt gWdhuoIfnUDOGLk9pNAgJ81nckNUlazSVwzgID2Mm+4xTRBTemgt/2MEhQYoUzzcJnYK hW5Q== X-Gm-Message-State: ANoB5plPv8ZEfMFFST+WPPyG5ezTp0aZNDaV2VbpXnv2Ke7JakpzHWep 9RZPdxR46oNDMXduySfa4QGhVFtV2gH5hjWEAKE= X-Received: by 2002:a25:c589:0:b0:6f5:8253:b125 with SMTP id v131-20020a25c589000000b006f58253b125mr22169566ybe.75.1669898539703; Thu, 01 Dec 2022 04:42:19 -0800 (PST) MIME-Version: 1.0 References: <20221130220825.1545758-1-carlos.bilbao@amd.com> In-Reply-To: <20221130220825.1545758-1-carlos.bilbao@amd.com> From: Miguel Ojeda Date: Thu, 1 Dec 2022 13:42:08 +0100 Message-ID: Subject: Re: [PATCH] docs: Integrate rustdoc into Rust documentation To: Carlos Bilbao Cc: corbet@lwn.net, ojeda@kernel.org, bilbao@vt.edu, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, konstantin@linuxfoundation.org, Akira Yokosawa Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Nov 30, 2022 at 11:08 PM Carlos Bilbao wrote: > > Include HTML output generated with rustdoc into the Linux kernel > documentation on Rust. Change target `make htmldocs` to combine RST Sphinx > and the generation of Rust documentation, when support is available. Looks better, thanks for this v2! A few comments below... > +ifdef CONFIG_RUST > + @make LLVM=1 rustdoc > +endif The Rust docs should probably be built with the build system/config/... as given, whether it is GCC, LLVM, etc. This should probably use `$(MAKE)` too; and if you intended to remove the command line definitions, `MAKEOVERRIDES` too. Ideally `htmldocs` would depend on `rustdoc`, though that would require shuffling quite a few things since to build the Rust docs we need a subset of the Rust dependencies built. Given we may be changing things soon anyway on the Rust `Makefile`, we can leave that for the future. By the way, while checking this, I noticed we use some `CONFIG_`s in this `Makefile`, but we do not perform a config sync for the `*docs` targets, so one needs to do so manually, i.e. it can be a pitfall for e.g. `CONFIG_WARN_MISSING_DOCUMENTS` and ` as well as a potential `CONFIG_RUST`. Should this be fixed orthogonally, or is it intended? (some targets do not need the sync, and the ones that need are probably less used, so I guess that could be the reason?). > +Rustdoc output > +============== > + > +If this documentation includes rustdoc-generated HTML, the entry point > +can be found `here. `_ Perhaps this sentence could be moved to the top of the index file, so that users do not need two clicks when visiting "Rust"? That way we avoid one more file too. > +RUSTDOC_OUTPUT=$(objtree)/Documentation/output/rust/rustdoc Please add a space around the equal sign to be consistent with (most) of the rest of the file. Cheers, Miguel