Message ID | cover.1709219325.git.jean@foundationdevices.com |
---|---|
Headers |
Return-Path: <guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org> X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 1087227BBEA; Thu, 29 Feb 2024 15:19:56 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 232DC27BBE2 for <patchwork@mira.cbaines.net>; Thu, 29 Feb 2024 15:19:55 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from <guix-patches-bounces@gnu.org>) id 1rfiCB-0004gC-B6; Thu, 29 Feb 2024 10:19:39 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <Debian-debbugs@debbugs.gnu.org>) id 1rfiC8-0004c1-8c for guix-patches@gnu.org; Thu, 29 Feb 2024 10:19:36 -0500 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from <Debian-debbugs@debbugs.gnu.org>) id 1rfiC7-0002j7-Vh for guix-patches@gnu.org; Thu, 29 Feb 2024 10:19:35 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from <Debian-debbugs@debbugs.gnu.org>) id 1rfiCY-0004Ym-9i; Thu, 29 Feb 2024 10:20:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#69476] [PATCH 0/8] guix: Add xtensa-ath9k-elf platform. Resent-From: Jean-Pierre De Jesus DIAZ <jean@foundationdevices.com> Original-Sender: "Debbugs-submit" <debbugs-submit-bounces@debbugs.gnu.org> Resent-CC: efraim@flashner.co.il, vagrant@debian.org, guix-patches@gnu.org Resent-Date: Thu, 29 Feb 2024 15:20:02 +0000 Resent-Message-ID: <handler.69476.B.170922000017514@debbugs.gnu.org> Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 69476 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 69476@debbugs.gnu.org Cc: Jean-Pierre De Jesus DIAZ <jean@foundationdevices.com>, Efraim Flashner <efraim@flashner.co.il>, Vagrant Cascadian <vagrant@debian.org> X-Debbugs-Original-To: guix-patches@gnu.org X-Debbugs-Original-Xcc: Efraim Flashner <efraim@flashner.co.il>, Vagrant Cascadian <vagrant@debian.org> Received: via spool by submit@debbugs.gnu.org id=B.170922000017514 (code B ref -1); Thu, 29 Feb 2024 15:20:02 +0000 Received: (at submit) by debbugs.gnu.org; 29 Feb 2024 15:20:00 +0000 Received: from localhost ([127.0.0.1]:35008 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces@debbugs.gnu.org>) id 1rfiCV-0004YQ-Jo for submit@debbugs.gnu.org; Thu, 29 Feb 2024 10:20:00 -0500 Received: from lists.gnu.org ([209.51.188.17]:55750) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <jean@foundationdevices.com>) id 1rfiCS-0004YH-8b for submit@debbugs.gnu.org; Thu, 29 Feb 2024 10:19:58 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <jean@foundationdevices.com>) id 1rfiC0-0004US-LL for guix-patches@gnu.org; Thu, 29 Feb 2024 10:19:28 -0500 Received: from mail-wr1-x42d.google.com ([2a00:1450:4864:20::42d]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from <jean@foundationdevices.com>) id 1rfiBy-0002iT-S3 for guix-patches@gnu.org; Thu, 29 Feb 2024 10:19:28 -0500 Received: by mail-wr1-x42d.google.com with SMTP id ffacd0b85a97d-33dcad9e3a2so691441f8f.3 for <guix-patches@gnu.org>; Thu, 29 Feb 2024 07:19:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=foundationdevices.com; s=google; t=1709219964; x=1709824764; darn=gnu.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=YAjzHf6L/6NcctSSgaqSPWEc7kn09GVVhFPhlhjiWkI=; b=EhLp2LwJZEAdxP5eX7E+bRFNPAqlpQbMtj+waDAStgAhO4h17FkQOZLEJO+AUX6P/b T0FDjj131B10SgHDRj63UbE8nijpGggKyM/sLs0MNd0UoXVo3wph3xIcDdraAg8RB7Do VIYMl59VZeGzcYPbdLym/1FjGrfadccIcy1owpQV2kDfv4tSSXrJIhsq218HZ+kuOAsU xvus+ATXPXXs/+QRyZKhuW+7R2ctVp6cSFtxV0AGxSfUr86Llb2usk3aW5uyaPc3NKj6 3VwJdeVWzDJYA7el66UHvLL0W1pj1ERBE3zQrzT83+JNJlvNkckAn8EihdCfE2arW+f8 whCQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709219964; x=1709824764; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=YAjzHf6L/6NcctSSgaqSPWEc7kn09GVVhFPhlhjiWkI=; b=EPXGsnqEVx71cICNm/UH7b396ncXQE1PqW5/bvStoGxzlxZVKWNMHZhd9WMEeGhfut 57ZfgvkVLEfLyotw9eCwybWqPj7tcwjWAzK5/ZVx+m3Mb39Hdo+RwrNipqbhWeo5/1Xf +J3WgGTRIVAnRo705H1QJfSn3or/NQGFsEvAFVNbji2fiGtLw4YgSyYrbmqcehSiugDu dVO0artVquF45LJ0tVBgkxpClL9q2K4unRVcfKdkh2KSKIogKfskEoiDbkKEHXJvYbaW ClJOvuWqWAPreoCe9GxcXnOM98AzgG3coKuO9gxrwTaWlEgcp4iHvgjio6qzoo2Ou6ho m3ug== X-Gm-Message-State: AOJu0YybAojn7UrgvrKaGNVOMupFcbRyfBFKC2ph/CbhcNh1VRPnpLnr yWmSn2PkE4BOua3/KzgM27vZsWsHz8EIgKg3ddNgUpNqF6jJGu6JvQZ0zVhiRQ4w+ShF2dEfdI1 yh/M= X-Google-Smtp-Source: AGHT+IGOLJxw5VWQD31/GfNWBhsWpkcS4zeTUQCRTlpyl0ljKT7+XSOO391dHhWPvwUvc9jP+q+/aQ== X-Received: by 2002:adf:b645:0:b0:33d:32fe:cb49 with SMTP id i5-20020adfb645000000b0033d32fecb49mr1658318wre.3.1709219964395; Thu, 29 Feb 2024 07:19:24 -0800 (PST) Received: from jeandudey.home ([89.131.29.87]) by smtp.gmail.com with ESMTPSA id i10-20020adff30a000000b0033b6e26f0f9sm2010701wro.42.2024.02.29.07.19.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 29 Feb 2024 07:19:24 -0800 (PST) Date: Thu, 29 Feb 2024 16:19:17 +0100 Message-ID: <cover.1709219325.git.jean@foundationdevices.com> X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=2a00:1450:4864:20::42d; envelope-from=jean@foundationdevices.com; helo=mail-wr1-x42d.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: <guix-patches.gnu.org> List-Unsubscribe: <https://lists.gnu.org/mailman/options/guix-patches>, <mailto:guix-patches-request@gnu.org?subject=unsubscribe> List-Archive: <https://lists.gnu.org/archive/html/guix-patches> List-Post: <mailto:guix-patches@gnu.org> List-Help: <mailto:guix-patches-request@gnu.org?subject=help> List-Subscribe: <https://lists.gnu.org/mailman/listinfo/guix-patches>, <mailto:guix-patches-request@gnu.org?subject=subscribe> Reply-to: Jean-Pierre De Jesus DIAZ <jean@foundationdevices.com> X-ACL-Warn: , Jean-Pierre De Jesus DIAZ via Guix-patches <guix-patches@gnu.org> From: Jean-Pierre De Jesus DIAZ via Guix-patches via <guix-patches@gnu.org> Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches |
Series |
guix: Add xtensa-ath9k-elf platform.
|
|
Message
Jean-Pierre De Jesus DIAZ
Feb. 29, 2024, 3:19 p.m. UTC
Hello, As the ath9k-htc-firmware package requires a custom toolchain to build the firmware I thought it was best to have a target for this specific package as it modifies the default configuration of the Xtensa target in GCC. To work around this a new target is added: xtensa-ath9k-elf. It uses binutils@2.33 and the patched version of GCC to properly compile the firmware. So, as a result it allows using #:target keyword parameter to cross-compile the firmware and avoids explicitly adding the cross compiler in the NATIVE-INPUTS field. As a result the ath9k-htc-firmware package was splitted into two and uses the cmake-build-sytem now to use Guix's cross-compilation support properly, so it removes the need for the ath9k-htc-firmware-objcopy.patch. The [PATCH 7/8] contains a patch that was already sent to: https://issues.guix.gnu.org/68366 I don't have the hardware to test this firmware but the build produces the same hashes for the firmware so it's safe to say that the firmware should keep working. The hashes with this patch series: a5481cc67d962b217de1300121a6c7584e847cbe215442553d24a2173ca9202e /gnu/store/0i3zw28pvrr8l85fx79i8lq0f9vmgyjz-ath9k-htc-ar9271-firmware-1.4.0/lib/firmware/htc_9271.fw eef84c16e3edad3fdec19c985d190b5ed3f5bd5bae20be5579681ab35f001406 /gnu/store/iqbd77grzy4sngkxz9lgyvk52apn8vzj-ath9k-htc-ar7010-firmware-1.4.0/lib/firmware/htc_7010.fw And the hashes in master at commit 75bad75367fcf2c289fae3b40dbcc850f92177be: a5481cc67d962b217de1300121a6c7584e847cbe215442553d24a2173ca9202e /gnu/store/0m45gn74b5bavxq77158i3l593lh082r-ath9k-htc-firmware-1.4.0/lib/firmware/htc_9271.fw eef84c16e3edad3fdec19c985d190b5ed3f5bd5bae20be5579681ab35f001406 /gnu/store/0m45gn74b5bavxq77158i3l593lh082r-ath9k-htc-firmware-1.4.0/lib/firmware/htc_7010.fw Jean-Pierre De Jesus DIAZ (8): doc: Add documentation for x86_64-linux-gnux32. guix: Add xtensa-ath9k-elf platform. gnu: ath9k-htc-firmware: Remove binary blobs. gnu: ath9k-htc-firmware: Allow using other targets. gnu: ath9k-htc-firmware: Use xtensa-ath9k-elf. gnu: cross-binutils: Use binutils-2.33 for ath9k. guix: cmake-build-system: Handle unknown systems. gnu: ath9k-htc-firmware: Split package. Makefile.am | 1 + doc/guix.texi | 12 +++ gnu/local.mk | 1 - gnu/packages/cross-base.scm | 17 +++- gnu/packages/firmware.scm | 88 +++++++++---------- .../patches/ath9k-htc-firmware-objcopy.patch | 14 --- gnu/system.scm | 3 +- guix/build/cmake-build-system.scm | 10 ++- guix/platforms/xtensa.scm | 28 ++++++ 9 files changed, 105 insertions(+), 69 deletions(-) delete mode 100644 gnu/packages/patches/ath9k-htc-firmware-objcopy.patch create mode 100644 guix/platforms/xtensa.scm base-commit: 75bad75367fcf2c289fae3b40dbcc850f92177be
Comments
On 2024-02-29, Jean-Pierre De Jesus DIAZ wrote: > As the ath9k-htc-firmware package requires a custom toolchain to build > the firmware I thought it was best to have a target for this specific > package as it modifies the default configuration of the Xtensa target in > GCC. > > To work around this a new target is added: xtensa-ath9k-elf. > > It uses binutils@2.33 and the patched version of GCC to properly compile > the firmware. So, as a result it allows using #:target keyword parameter > to cross-compile the firmware and avoids explicitly adding the cross > compiler in the NATIVE-INPUTS field. I am not in a position to evaluate the correctness of the proposed toolchain changes, but conceptually it makes sense. > As a result the ath9k-htc-firmware package was splitted into two and > uses the cmake-build-sytem now to use Guix's cross-compilation support > properly, so it removes the need for the ath9k-htc-firmware-objcopy.patch. This makes sense to me too. > The [PATCH 7/8] contains a patch that was already sent to: > > https://issues.guix.gnu.org/68366 Ok, one of these two patch series will need to be refactored depending on which gets applied first. > I don't have the hardware to test this firmware but the build produces > the same hashes for the firmware so it's safe to say that the firmware > should keep working. I do have some of the hardware to test, though have not had a chance to test the patches... will try to get on that. Obviously producing identical hashes is quite compelling; this is an excellent example of applying Reproducible Builds to refactoring code! > The hashes with this patch series: > > a5481cc67d962b217de1300121a6c7584e847cbe215442553d24a2173ca9202e /gnu/store/0i3zw28pvrr8l85fx79i8lq0f9vmgyjz-ath9k-htc-ar9271-firmware-1.4.0/lib/firmware/htc_9271.fw > eef84c16e3edad3fdec19c985d190b5ed3f5bd5bae20be5579681ab35f001406 /gnu/store/iqbd77grzy4sngkxz9lgyvk52apn8vzj-ath9k-htc-ar7010-firmware-1.4.0/lib/firmware/htc_7010.fw > > And the hashes in master at commit 75bad75367fcf2c289fae3b40dbcc850f92177be: > > a5481cc67d962b217de1300121a6c7584e847cbe215442553d24a2173ca9202e /gnu/store/0m45gn74b5bavxq77158i3l593lh082r-ath9k-htc-firmware-1.4.0/lib/firmware/htc_9271.fw > eef84c16e3edad3fdec19c985d190b5ed3f5bd5bae20be5579681ab35f001406 /gnu/store/0m45gn74b5bavxq77158i3l593lh082r-ath9k-htc-firmware-1.4.0/lib/firmware/htc_7010.fw Yay! live well, vagrant
Hi Jean-Pierre, Looks like this patch series had fallen through the cracks. Jean-Pierre De Jesus DIAZ <jean@foundationdevices.com> skribis: > As the ath9k-htc-firmware package requires a custom toolchain to build > the firmware I thought it was best to have a target for this specific > package as it modifies the default configuration of the Xtensa target in > GCC. > > To work around this a new target is added: xtensa-ath9k-elf. > > It uses binutils@2.33 and the patched version of GCC to properly compile > the firmware. So, as a result it allows using #:target keyword parameter > to cross-compile the firmware and avoids explicitly adding the cross > compiler in the NATIVE-INPUTS field. > > As a result the ath9k-htc-firmware package was splitted into two and > uses the cmake-build-sytem now to use Guix's cross-compilation support > properly, so it removes the need for the ath9k-htc-firmware-objcopy.patch. > > The [PATCH 7/8] contains a patch that was already sent to: > > https://issues.guix.gnu.org/68366 Neat. > I don't have the hardware to test this firmware but the build produces > the same hashes for the firmware so it's safe to say that the firmware > should keep working. > > The hashes with this patch series: > > a5481cc67d962b217de1300121a6c7584e847cbe215442553d24a2173ca9202e /gnu/store/0i3zw28pvrr8l85fx79i8lq0f9vmgyjz-ath9k-htc-ar9271-firmware-1.4.0/lib/firmware/htc_9271.fw > eef84c16e3edad3fdec19c985d190b5ed3f5bd5bae20be5579681ab35f001406 /gnu/store/iqbd77grzy4sngkxz9lgyvk52apn8vzj-ath9k-htc-ar7010-firmware-1.4.0/lib/firmware/htc_7010.fw > > And the hashes in master at commit 75bad75367fcf2c289fae3b40dbcc850f92177be: > > a5481cc67d962b217de1300121a6c7584e847cbe215442553d24a2173ca9202e /gnu/store/0m45gn74b5bavxq77158i3l593lh082r-ath9k-htc-firmware-1.4.0/lib/firmware/htc_9271.fw > eef84c16e3edad3fdec19c985d190b5ed3f5bd5bae20be5579681ab35f001406 /gnu/store/0m45gn74b5bavxq77158i3l593lh082r-ath9k-htc-firmware-1.4.0/lib/firmware/htc_7010.fw Excellent; thanks for taking the time to check this! (FWIW I use a WiFi dongle that relies on this firmware so you’ll soon hear from me if something goes wrong. ;-)) > doc: Add documentation for x86_64-linux-gnux32. > guix: Add xtensa-ath9k-elf platform. > gnu: ath9k-htc-firmware: Remove binary blobs. > gnu: ath9k-htc-firmware: Allow using other targets. > gnu: ath9k-htc-firmware: Use xtensa-ath9k-elf. > gnu: cross-binutils: Use binutils-2.33 for ath9k. > guix: cmake-build-system: Handle unknown systems. > gnu: ath9k-htc-firmware: Split package. Applied, thanks! Ludo’.