From 1c00a61ca3b94fc76cbd28bd68e2c0a076336628 Mon Sep 17 00:00:00 2001 From: Marek Fiala Date: Fri, 9 Aug 2024 11:25:30 +0200 Subject: [PATCH 1/2] feat(tools): Update tools: cmake, ninja, ccache cmake v3.24.0 -> v3.30.2 ninja v1.11.1 -> v1.12.1 ccache v4.8 -> v4.10.2 Closes https://github.com/espressif/esp-idf/pull/14376 --- tools/tools.json | 86 ++++++++++++++++++++++++------------------------ 1 file changed, 43 insertions(+), 43 deletions(-) diff --git a/tools/tools.json b/tools/tools.json index 4c900645dd8d..35ae183926f4 100644 --- a/tools/tools.json +++ b/tools/tools.json @@ -634,46 +634,46 @@ "versions": [ { "linux-amd64": { - "sha256": "726f88e6598523911e4bce9b059dc20b851aa77f97e4cc5573f4e42775a5c16f", - "size": 47042675, - "url": "https://github.com/Kitware/CMake/releases/download/v3.24.0/cmake-3.24.0-linux-x86_64.tar.gz" + "sha256": "cdd7fb352605cee3ae53b0e18b5929b642900e33d6b0173e19f6d4f2067ebf16", + "size": 53635506, + "url": "https://github.com/Kitware/CMake/releases/download/v3.30.2/cmake-3.30.2-linux-x86_64.tar.gz" }, "linux-arm64": { - "sha256": "50c3b8e9d3a3cde850dd1ea143df9d1ae546cbc5e74dc6d223eefc1979189651", - "size": 48478082, - "url": "https://github.com/Kitware/CMake/releases/download/v3.24.0/cmake-3.24.0-linux-aarch64.tar.gz" + "sha256": "d18f50f01b001303d21f53c6c16ff12ee3aa45df5da1899c2fe95be7426aa026", + "size": 54889935, + "url": "https://github.com/Kitware/CMake/releases/download/v3.30.2/cmake-3.30.2-linux-aarch64.tar.gz" }, "linux-armel": { - "sha256": "7dc787ef968dfef92491a4f191b8739ff70f8a649608b811c7a737b52481beb0", - "size": 19811327, - "url": "https://dl.espressif.com/dl/cmake/cmake-3.24.0-Linux-armv7l.tar.gz" + "sha256": "446650c69ea74817a770f96446c162bb7ad24ffecaacb35fcd4845ec7d3c9099", + "size": 17035042, + "url": "https://dl.espressif.com/dl/cmake/cmake-3.30.2-Linux-armv7l.tar.gz" }, "linux-armhf": { - "sha256": "7dc787ef968dfef92491a4f191b8739ff70f8a649608b811c7a737b52481beb0", - "size": 19811327, - "url": "https://dl.espressif.com/dl/cmake/cmake-3.24.0-Linux-armv7l.tar.gz" + "sha256": "446650c69ea74817a770f96446c162bb7ad24ffecaacb35fcd4845ec7d3c9099", + "size": 17035042, + "url": "https://dl.espressif.com/dl/cmake/cmake-3.30.2-Linux-armv7l.tar.gz" }, "macos": { - "sha256": "3e0cca74a56d9027dabb845a5a26e42ef8e8b33beb1655d6a724187a345145e4", - "size": 72801419, - "url": "https://github.com/Kitware/CMake/releases/download/v3.24.0/cmake-3.24.0-macos-universal.tar.gz" + "sha256": "c6fdda745f9ce69bca048e91955c7d043ba905d6388a62e0ff52b681ac17183c", + "size": 79199037, + "url": "https://github.com/Kitware/CMake/releases/download/v3.30.2/cmake-3.30.2-macos-universal.tar.gz" }, "macos-arm64": { - "sha256": "3e0cca74a56d9027dabb845a5a26e42ef8e8b33beb1655d6a724187a345145e4", - "size": 72801419, - "url": "https://github.com/Kitware/CMake/releases/download/v3.24.0/cmake-3.24.0-macos-universal.tar.gz" + "sha256": "c6fdda745f9ce69bca048e91955c7d043ba905d6388a62e0ff52b681ac17183c", + "size": 79199037, + "url": "https://github.com/Kitware/CMake/releases/download/v3.30.2/cmake-3.30.2-macos-universal.tar.gz" }, - "name": "3.24.0", + "name": "3.30.2", "status": "recommended", "win32": { - "sha256": "b1ad8c2dbf0778e3efcc9fd61cd4a962e5c1af40aabdebee3d5074bcff2e103c", - "size": 40212531, - "url": "https://github.com/Kitware/CMake/releases/download/v3.24.0/cmake-3.24.0-windows-x86_64.zip" + "sha256": "48bf4b3dc2d668c578e0884cac7878e146b036ca6b5ce4f8b5572f861b004c25", + "size": 45404613, + "url": "https://github.com/Kitware/CMake/releases/download/v3.30.2/cmake-3.30.2-windows-x86_64.zip" }, "win64": { - "sha256": "b1ad8c2dbf0778e3efcc9fd61cd4a962e5c1af40aabdebee3d5074bcff2e103c", - "size": 40212531, - "url": "https://github.com/Kitware/CMake/releases/download/v3.24.0/cmake-3.24.0-windows-x86_64.zip" + "sha256": "48bf4b3dc2d668c578e0884cac7878e146b036ca6b5ce4f8b5572f861b004c25", + "size": 45404613, + "url": "https://github.com/Kitware/CMake/releases/download/v3.30.2/cmake-3.30.2-windows-x86_64.zip" } }, { @@ -817,26 +817,26 @@ "versions": [ { "linux-amd64": { - "sha256": "32bb769de4d57aa7ee0e292cfcb7553e7cc8ea0961f7aa2b3aee60aa407c4033", - "size": 106415, - "url": "https://dl.espressif.com/dl/ninja-1.10.2-linux64.tar.gz" + "sha256": "6f98805688d19672bd699fbbfa2c2cf0fc054ac3df1f0e6a47664d963d530255", + "size": 123084, + "url": "https://github.com/ninja-build/ninja/releases/download/v1.12.1/ninja-linux.zip" }, "macos": { - "sha256": "847bb1ca4bc16d8dba6aeed3ecb5055498b86bc68c364c37583eb5738bb440f1", - "size": 240112, - "url": "https://dl.espressif.com/dl/ninja-1.10.2-osx.tar.gz" + "sha256": "89a287444b5b3e98f88a945afa50ce937b8ffd1dcc59c555ad9b1baf855298c9", + "size": 281130, + "url": "https://github.com/ninja-build/ninja/releases/download/v1.12.1/ninja-mac.zip" }, "macos-arm64": { - "sha256": "847bb1ca4bc16d8dba6aeed3ecb5055498b86bc68c364c37583eb5738bb440f1", - "size": 240112, - "url": "https://dl.espressif.com/dl/ninja-1.10.2-osx.tar.gz" + "sha256": "89a287444b5b3e98f88a945afa50ce937b8ffd1dcc59c555ad9b1baf855298c9", + "size": 281130, + "url": "https://github.com/ninja-build/ninja/releases/download/v1.12.1/ninja-mac.zip" }, - "name": "1.10.2", + "name": "1.12.1", "status": "recommended", "win64": { - "sha256": "bbde850d247d2737c5764c927d1071cbb1f1957dcabda4a130fa8547c12c695f", - "size": 262670, - "url": "https://dl.espressif.com/dl/ninja-1.10.2-win64.zip" + "sha256": "f550fec705b6d6ff58f2db3c374c2277a37691678d6aba463adcbb129108467a", + "size": 275425, + "url": "https://github.com/ninja-build/ninja/releases/download/v1.12.1/ninja-win.zip" } } ] @@ -891,7 +891,7 @@ "description": "Ccache (compiler cache)", "export_paths": [ [ - "ccache-4.8-windows-x86_64" + "ccache-4.10.2-windows-x86_64" ] ], "export_vars": { @@ -919,12 +919,12 @@ "version_regex": "ccache version ([0-9.]+)", "versions": [ { - "name": "4.8", + "name": "4.10.2", "status": "recommended", "win64": { - "sha256": "a2b3bab4bb8318ffc5b3e4074dc25636258bc7e4b51261f7d9bef8127fda8309", - "size": 2005781, - "url": "https://github.com/ccache/ccache/releases/download/v4.8/ccache-4.8-windows-x86_64.zip" + "sha256": "6252f081876a9a9f700fae13a5aec5d0d486b28261d7f1f72ac11c7ad9df4da9", + "size": 1610890, + "url": "https://github.com/ccache/ccache/releases/download/v4.10.2/ccache-4.10.2-windows-x86_64.zip" } } ] From abbfb9d07387cc80d18251c5b30a373495ea76df Mon Sep 17 00:00:00 2001 From: Marek Fiala Date: Tue, 27 Aug 2024 14:29:17 +0200 Subject: [PATCH 2/2] feat(tools): Exclude modified folders by rebuild --- tools/test_build_system/test_rebuild.py | 22 ++++++++++++++++------ 1 file changed, 16 insertions(+), 6 deletions(-) diff --git a/tools/test_build_system/test_rebuild.py b/tools/test_build_system/test_rebuild.py index 9996da303590..c5df4bc378b1 100644 --- a/tools/test_build_system/test_rebuild.py +++ b/tools/test_build_system/test_rebuild.py @@ -1,15 +1,21 @@ -# SPDX-FileCopyrightText: 2022-2023 Espressif Systems (Shanghai) CO LTD +# SPDX-FileCopyrightText: 2022-2024 Espressif Systems (Shanghai) CO LTD # SPDX-License-Identifier: Apache-2.0 # These tests check whether the build system rebuilds some files or not # depending on the changes to the project. import logging import os from pathlib import Path -from typing import List, Union +from typing import List +from typing import Union import pytest -from test_build_system_helpers import (ALL_ARTIFACTS, APP_BINS, BOOTLOADER_BINS, PARTITION_BIN, IdfPyFunc, - get_snapshot, replace_in_file) +from test_build_system_helpers import ALL_ARTIFACTS +from test_build_system_helpers import APP_BINS +from test_build_system_helpers import BOOTLOADER_BINS +from test_build_system_helpers import get_snapshot +from test_build_system_helpers import IdfPyFunc +from test_build_system_helpers import PARTITION_BIN +from test_build_system_helpers import replace_in_file @pytest.mark.usefixtures('test_app_copy') @@ -18,7 +24,9 @@ def test_rebuild_no_changes(idf_py: IdfPyFunc) -> None: idf_py('build') logging.info('get the first snapshot') # excluding the 'log' subdirectory here since it changes after every build - all_build_files = get_snapshot('build/**/*', exclude_patterns='build/log/*') + all_build_files = get_snapshot('build/**/*', exclude_patterns=['build/log/*', + 'build/CMakeFiles/bootloader-complete', + 'build/bootloader-prefix/src/bootloader-stamp/bootloader-done']) logging.info('check that all build artifacts were generated') for artifact in ALL_ARTIFACTS: @@ -27,7 +35,9 @@ def test_rebuild_no_changes(idf_py: IdfPyFunc) -> None: logging.info('build again with no changes') idf_py('build') # if there are no changes, nothing gets rebuilt - all_build_files_after_rebuild = get_snapshot('build/**/*', exclude_patterns='build/log/*') + all_build_files_after_rebuild = get_snapshot('build/**/*', exclude_patterns=['build/log/*', + 'build/CMakeFiles/bootloader-complete', + 'build/bootloader-prefix/src/bootloader-stamp/bootloader-done']) all_build_files_after_rebuild.assert_same(all_build_files)