From patchwork Sun Jan 4 20:08:37 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1267 Return-Path: X-Original-To: u-boot-concept@u-boot.org Delivered-To: u-boot-concept@u-boot.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1767557374; bh=qi0zOnptSXICefpzuAeWWE6zrdeylt8dzIrTmWHxjdo=; h=From:To:Date:In-Reply-To:References:CC:Subject:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=tuPQ49ddoFPQ23j7zlWb8c8O9+XB2vXU7sekThmEEimYsokDLne9Dpz/aVrjxcYiO XX7KI3mcPhUrkBU83QUCIARMKHIx+JT26fBD1Xjb6e22pjW91iN1xBRRlYxIJzbfAq nddiDNFNb/8vA/KEzTiz179gXY0EBdXq0rn+zTHCZ7egIn1N2k06WRs5jhHuFGPMSW EByysMg4r+BighHWjbViX33qd9IYaIqPx1DjZcEEFnhVZCOZITHGErY6ADmHoAFaNb 4+clpPR6WVDHMODsZ8g1WJzI+UUwT7/h1CtP3JKDP7se97EuLPhOpBgV/0fNhkwvKW BxlyJfwTgcrGw== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id 11402690DE for ; Sun, 4 Jan 2026 13:09:34 -0700 (MST) X-Virus-Scanned: Debian amavis at Received: from mail.u-boot.org ([127.0.0.1]) by localhost (mail.u-boot.org [127.0.0.1]) (amavis, port 10024) with ESMTP id z4TLFCwYIQ9K for ; Sun, 4 Jan 2026 13:09:34 -0700 (MST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1767557373; bh=qi0zOnptSXICefpzuAeWWE6zrdeylt8dzIrTmWHxjdo=; h=From:To:Date:In-Reply-To:References:CC:Subject:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=L5BjfoO6NTt4F508l9fLz2yrgF/nYa3hqRZS0f6ul4Af7iqnLjaux14D1/JZkAjWW xHtZs91oaxmylroNwClY59GoJl0VTtZs6VM26XVU27kHgrX3vYC1wwD4CscrAsxiEl /wz/WRxPyKP2zbGWu7uHkpDOBaDZaVmeJ88UGzPjZwZOMEiZAkR35XnuAcL9ce91Tv 3pgCI7Q0O0D2rraiSSU8gOpqW4Ra5IhP493s/0X23NhYsJx3fICzDLiuWp+EYC0vEK kPTuhiRESHotPui8U5ZNMLg+YOPSgWgZ6HTcdNXe5vUDnQiZexDcStgyi97dKG1lzZ aak+stgIrZQKg== Received: from mail.u-boot.org (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id F245E690BD for ; Sun, 4 Jan 2026 13:09:33 -0700 (MST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1767557371; bh=Sud0OQ6qM3eKja7jZ20vFxMyGDGOfnaB2bee9aWDEx0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=jtaXolJ6bqW/vFk36dugJgZkXUu1nWG8Gqn8uq/zV+wJezhXhCsXVvGkhcLPeJ4dh 3sgniLjSvo02lndd/LLydid5DSnjDQKzZuGcSyyfUbrLbVt9X0tYyQR78ridnF05i5 r3/LiEYhkH65fExSPesKph6OAOzioPf0hbTGOH30s1yf0yDGDvMRuavIaNYqMaXcxX g8x7cq5G8SbiiDE8EAXzjAToT+rZVLp56LwqZE4O55lI3p8J6eIyiwjkxpCl9KdiPm n/2BGiMYVwEwfdt39TllUHu/mDNY0P35FTFB77s5Me8YMDN/43JQiXU+IHU4opzCNX NxzrD8vst8xHg== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id A88B0690BD; Sun, 4 Jan 2026 13:09:31 -0700 (MST) X-Virus-Scanned: Debian amavis at Received: from mail.u-boot.org ([127.0.0.1]) by localhost (mail.u-boot.org [127.0.0.1]) (amavis, port 10026) with ESMTP id S1ZIBSdP6KPV; Sun, 4 Jan 2026 13:09:31 -0700 (MST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1767557367; bh=yTb7PCjtaimlUY7tDh47nNqxS5L+cSugZaJv2F7ZoOI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=RA3UOxMiz4E0YKYVV59YVwEaZ3x61Xx/4nrlKpGcSaqKMNphLYuaQ35EOed3ii3Se twzTXvuaav7wpD1KcpJCUNM1j4dxfiTIBCdvTTsiy99LGEJYAlq4oOP0JhGlkLeg0k ZCkFd0qO/qeNHk+4hzhSNkKCfbMi5LybU4iGnN3zYDrDnqnwfLlnNBT3Cv1gHDJALa m7jZsJGe5L2sY90KoskUdKhXzrCyfPgDzhuTf5zAb2PESfilWEgOe8fV/c5z8WzZJJ GG2nxVbCSSqjgcw01e8BU+Ig7yr93KrJcQMUNBVCNsj5e66WgT83M8yU7OkQ4iPZYL cp4GZYsJVF2wQ== Received: from u-boot.org (unknown [73.34.74.121]) by mail.u-boot.org (Postfix) with ESMTPSA id 74D2268FD8; Sun, 4 Jan 2026 13:09:27 -0700 (MST) From: Simon Glass To: U-Boot Concept Date: Sun, 4 Jan 2026 13:08:37 -0700 Message-ID: <20260104200844.481633-9-sjg@u-boot.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20260104200844.481633-1-sjg@u-boot.org> References: <20260104200844.481633-1-sjg@u-boot.org> MIME-Version: 1.0 Message-ID-Hash: YXKANKRLYNUMUPVAMP3RVX3M67UJHLIJ X-Message-ID-Hash: YXKANKRLYNUMUPVAMP3RVX3M67UJHLIJ X-MailFrom: sjg@u-boot.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: Heinrich Schuchardt , Simon Glass , Claude X-Mailman-Version: 3.3.10 Precedence: list Subject: [Concept] [PATCH 08/11] buildman: Document all Toolchain public members List-Id: Discussion and patches related to U-Boot Concept Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: From: Simon Glass Add missing 'ok' member to the class docstring and add type annotations to all documented members. Co-developed-by: Claude Signed-off-by: Simon Glass --- tools/buildman/toolchain.py | 31 ++++++++++++++++++------------- 1 file changed, 18 insertions(+), 13 deletions(-) diff --git a/tools/buildman/toolchain.py b/tools/buildman/toolchain.py index 68fea72bf6c..7ccb56a74aa 100644 --- a/tools/buildman/toolchain.py +++ b/tools/buildman/toolchain.py @@ -60,25 +60,30 @@ class Toolchain: """A single toolchain Public members: - gcc: Full path to C compiler - path: Directory path containing C compiler - cross: Cross compile string, e.g. 'arm-linux-' - arch: Architecture of toolchain as determined from the first - component of the filename. E.g. arm-linux-gcc becomes arm - priority: Toolchain priority (0=highest, 20=lowest) - override_toolchain: Toolchain to use for sandbox, overriding the normal - one + gcc (str): Full path to C compiler + path (str): Directory path containing C compiler + cross (str): Cross compile string, e.g. 'arm-linux-' + arch (str): Architecture of toolchain as determined from the first + component of the filename. E.g. arm-linux-gcc becomes arm + priority (int): Toolchain priority (0=highest, 20=lowest) + override_toolchain (str): Toolchain to use for sandbox, overriding the + normal one + ok (bool): True if the toolchain works, False otherwise """ def __init__(self, fname, test, verbose=False, priority=PRIORITY_CALC, arch=None, override_toolchain=None): """Create a new toolchain object. Args: - fname: Filename of the gcc component, possibly with ~ or $HOME in it - test: True to run the toolchain to test it - verbose: True to print out the information - priority: Priority to use for this toolchain, or PRIORITY_CALC to - calculate it + fname (str): Filename of the gcc component, possibly with ~ or + $HOME in it + test (bool): True to run the toolchain to test it + verbose (bool): True to print out the information + priority (int): Priority to use for this toolchain, or + PRIORITY_CALC to calculate it + arch (str): Architecture of toolchain, or None to detect from + filename + override_toolchain (str): Toolchain to use for sandbox, or None """ fname = os.path.expanduser(fname) self.gcc = fname