Wykres commitów

488 Commity (f841f0ae52ee76c3c347d67df38ed7aa28bfbf72)

Autor SHA1 Wiadomość Data
Aditya Patwardhan 482a8fb2d7
change(version): Update version to 5.1.2 2023-11-10 07:51:59 +05:30
Roland Dobai 06a4943e41 Merge branch 'fix/bin_names_with_dots_v5.1' into 'release/v5.1'
fix(build_system): Allow dots in the name of an app binary (backport v5.1)

See merge request espressif/esp-idf!25276
2023-08-25 14:42:32 +08:00
Aditya Patwardhan e088c3766b versions: Update version to 5.1.1 2023-08-21 14:24:40 +05:50
radim.karnis e72cf8c908 fix(build_system): Allow dots in the name of an app binary 2023-08-08 15:13:25 +02:00
Zim Kalinowski d636754e70 build system: more accurate error information for git_describe
Closes https://github.com/espressif/esp-idf/issues/9071

See merge request espressif/esp-idf!23891
2023-07-10 11:31:32 +08:00
Frantisek Hrbata 03162bb276 tools: extend information in project_description.json
This extends information provided in the project_description.json file.
Newly added information can be used in the SBOM generating tool and
also to improve hints regarding the the component dependency issues.

Added fields

version:
   This adds versioning to the project_description.json file,
   so it's easy to identify if it contains the required information.

project_version:
   Can be used as a version for the resulting binary e.g. `hello_world.bin`.

idf_path:
   This one is probably not necessary, but it allows tools to run even without
   esp-idf environment exported(e.g. export.sh).

c_compiler:
   The `CMAKE_C_COMPILER` value with full path to the compiler binary. This can
   be used to get information about toolchain, which was used to build the project.

common_component_reqs:
   List of common components as presented in cmake's __COMPONENT_REQUIRES_COMMON
   and set in tools/cmake/build.cmake:__build_init().

build_component_info:
   Detailed information about components used during build. It's a
   dictionary with the component name as a key and each component has
   a dictionary with detailed information. Following is an example for
   the efuse component.

   "efuse": {
       "alias": "idf::efuse",
       "target": "___idf_efuse",
       "prefix": "idf",
       "dir": "/home/fhrbata/work/esp-idf/components/efuse",
       "type": "LIBRARY",
       "lib": "__idf_efuse",
       "reqs": [],
       "priv_reqs": [ "bootloader_support", "soc", "spi_flash" ],
       "managed_reqs": [],
       "managed_priv_reqs": [],
       "file": "/home/fhrbata/work/blink/build/esp-idf/efuse/libefuse.a",
       "sources": [ "/home/fhrbata/work/esp-idf/components/efuse/esp32s3/esp_efuse_table.c", ... ],
       "include_dirs": [ "include", "esp32s3/include" ]
   }

Signed-off-by: Frantisek Hrbata <frantisek.hrbata@espressif.com>
2023-06-08 14:29:53 +02:00
Frantisek Hrbata 0f781c718c tools: fix make_json_list to return empty json list for empty cmake list
Currently make_json_list() returns '[ "" ]' for empty cmake list. Fix this
so empty json list is returned instead.

Signed-off-by: Frantisek Hrbata <frantisek.hrbata@espressif.com>
2023-06-08 14:29:53 +02:00
Jakob Hasse 2379ee36ab cxx: gnu++23 -> gnu++2b for clang compatibility, added docs and test
* Using -std=gnu++2b now for both gcc and clang as clang
  does not recognize gnu++23 yet
* Added a build test app to check the C++ standard in IDF
* Updated english docs to reflect the change to C++23
2023-05-11 17:48:38 +08:00
0xFEEDC0DE64 58fa57af93 Enable support for C++23 in esp-idf 2023-05-11 17:45:20 +08:00
Marius Vikhammer 63153794c9 build-system: replace ADDITIONAL_MAKE_CLEAN_FILES with ADDITIONAL_CLEAN_FILES
ADDITIONAL_MAKE_CLEAN_FILES is deprecated and only worked with make.
Replaced with the new ADDITIONAL_CLEAN_FILES (CMake 3.15) which also works with ninja.
2023-05-10 09:53:55 +08:00
laokaiyao 954a6a2cff esp32h4: removed esp32h4 related codes 2023-04-26 18:53:12 +08:00
laokaiyao cae47ce37e esp32h4: removed esp32h4 related files 2023-04-26 18:53:12 +08:00
Djordje Nedic 3e0f612a7e tools: Move out idf_size.py in favour of using the esp-idf-size package
This commit removes all idf_size.py files and references to them and adds esp-idf-size as a dependency and adequate wrappers to avoid breaking changes.
2023-03-27 19:40:33 +02:00
Frantisek Hrbata a558ad506e tools: fix custom sdkconfig renaming in set-target
Currently the set-target has sdkconfig file name hardcoded to the
default one and doesn't honor custom config paths or names.
IMHO the only place where we can really now the config file name
is in cmake. But also the config should be really renamed only if
the set-target action is running.

This moves the config file renaming into cmake and it's performed only
when _IDF_PY_SET_TARGET_ACTION env. var. is set to 'ON'. This should
hopefully guarantee that it's really renamed only while set-target is
running.

Signed-off-by: Frantisek Hrbata <frantisek.hrbata@espressif.com>
2023-03-08 16:45:55 +01:00
Frantisek Hrbata 1ca9e63e79 tools: add target consistency checks to cmake
Extend target checks in cmake, in case it's run directly and not via
idf.py or if idf.py misses something. This may happen
for example if cmake variables are set in project's CMakeLists.txt.

Some clean-ups are included along with the new checks and tests.

1. __target_check() function is removed. IIUC it should never fail,
   because the selected target is explicitly passed as environmental
   variable to kconfgen. Meaning the IDF_TARGET from environment variable may
   not be actually used in kconfgen if IDF_TARGET is already set it cmake cache.
   Note that the IDF_TARGET environment variable used for kconfgen is not
   based on the actual IDF_TARGET environment variable set for idf.py, but
   rather on the value set in __target_init() with

	set(IDF_TARGET ${env_idf_target} CACHE STRING "IDF Build Target")

   My understanding is that the original check was introduced to handle
   situation, where IDF_TARGET was already set in cmake's cache and
   the IDF_TARGET from environment variable was different. Since
   the kconfgen would use the original environment variable(not
   explicitly passed as it is now) the IDF_TARGET in cmake and in
   sdkconfig could differ. IOW I think the original check was introduced
   to cope with the following cmake behaviour

	set(VARIABLE "value1" CACHE STRING "test variable")
	set(VARIABLE "value2" CACHE STRING "test variable")
	message("Variable value: ${VARIABLE}")
	output: Variable value: value1

2. I scratched by head how it is possible that the following code
   in __target_check()

   	if(NOT ${IDF_TARGET} STREQUAL ${env_idf_target})

   could fail if IDF_TARGET is not set. For example in clean project

	IDF_TARGET=esp32 idf.py reconfigure

   Here env_idf_target==esp32 and IDF_TARGET is not set, so I would
   expect that cmake will fail with error message that the cache
   and env target do not match. The thing is that the variable
   evaluation is done before the if command, so it actually
   sees this

   	if(NOT  STREQUAL esp32)

   which is false and the error is not printed. It can be seen
   with 'cmake --trace-expand' command. I don't know if this
   was used on purpose or it worked just as a coincidence, but
   I find it very confusing, so I added explicit check if the
   IDF_TARGET is defined before the actual check. Same for
   CMAKE_TOOLCHAIN_FILE.

3. Error messages are not formated(line-wrapped) by cmake's markup
   so it's easier to check the output in tests.

Signed-off-by: Frantisek Hrbata <frantisek.hrbata@espressif.com>
2023-03-08 16:45:47 +01:00
Frantisek Hrbata 0d859f2786 tools: move target guessing into cmake
The _guess_or_check_idf_target() function has sdkconfig and sdkconfig.defaults
file names hardcoded. Since config file names may be specified with SDKCONFIG
or SDKCONFIG_DEFAULTS cmake vars, directly in CMakeLists.txt or passed in with
the -D cmake option, they are not respected.

Problem is when SDKCONFIG or SDKCONFIG_DEFAULTS is set in
CMakeLists.txt. While idf can detect cmake vars passed through it
to cmake via the -D option, detecting SDKCONFIG and SDKCONFIG_DEFAULTS
vars settings in CMakeLists.txt would require to parse it. This seems
like error prone approach. Also if the vars defined by the -D option
are passed directly to cmake, not via idf, they will not be visible to idf.

It seems reasonable to move the logic into cmake, where we know the correct
SDKCONFIG and SDKCONFIG_DEFAULTS values. So the IDF_TARGET detection/guessing
is moved into targets.cmake, where the IDF_TARGET is actually set. The target
is guessed based on the following precendence.

1) $ENV{IDF_TARGET}
2) IDF_TARGET
3) SDKCONFIG
4) sdkconfig
5) SDKCONFIG_DEFAULTS if non-empty or
   $ENV{SDKCONFIG_DEFAULTS} if non-empty or
   sdkconfig.defaults
6) esp32

All config files referred in $ENV{SDKCONFIG_DEFAULTS} and SDKCONFIG_DEFAULTS
are searched, compared to the current behaviour. First target found in the
above chain is used.

The original _guess_or_check_idf_target() is renamed to _check_idf_target() and
used for the target consistency checks only.

The get_sdkconfig_filename() helper is now used to get the sdkconfig file
for consistency checks. It looks in SDKCONFIG specified with the -D
option and project_description.json.

With this change config full paths are reported in messages, so it's clear
e.g. from which config the target was guessed from or which config has
consistency problem. test_non_default_target.py was adjusted to this
change and also new test for testing the IDF_TARGET guessing was added.

Signed-off-by: Frantisek Hrbata <frantisek.hrbata@espressif.com>
2023-03-08 16:37:58 +01:00
Alexey Lapshin 2ef6215621 tools: change esp32h2 march to rv32imac_zicsr_zifencei 2023-02-22 05:33:03 +00:00
Alexey Lapshin 61a7342acd tools: add riscv zicsr/zifencei because they were separated from i
https://groups.google.com/a/groups.riscv.org/g/sw-dev/c/aE1ZeHHCYf4
2023-02-22 05:33:03 +00:00
Alexey Lapshin c5ae3c67f1 Revert "tools: bypass atomic instruction variant for esp32c6 temporarily"
This reverts commit 08f05420c0.
2023-02-22 05:33:03 +00:00
Alexey Lapshin 5389ac4e04 tools: cmake: ignore linker RWX segment warnings 2023-02-22 05:33:03 +00:00
Peter Dragun 3e3533f918 feat(idf_monitor): move idf_monitor to separate repo 2023-02-03 11:20:15 +01:00
wuzhenghui 0cbb4227b2 feature: add build framework support 2023-02-01 17:57:25 +08:00
Angus Gratton d89652b382
build system: Add idf_component_add_link_dependency function, use for spi_flash overriding 2022-12-16 16:26:44 +01:00
Fu Hanxi 17224f3254 component manager: add build property `DEPENDENCIES_LOCK`
closes https://github.com/espressif/esp-idf/issues/9394
2022-12-13 15:25:19 +08:00
Marius Vikhammer 4ddbaa4166 linux target: add support for building esp_hw_support, soc and hal components for linux target 2022-12-09 13:59:39 +08:00
Marius Vikhammer 36cb08c379 heap: add linux target support
Add wrappers for public heap API for the linux target.
2022-12-06 10:49:59 +08:00
C.S.M 28b2deaf24 Merge branch 'feature/add_target_esp32h2' into 'master'
ESP32-H2: Introduce new target for ESP32H2

See merge request espressif/esp-idf!21190
2022-11-24 18:31:19 +08:00
Alexey Gerenkov 47c2c13de5 build: Adds support for universal Clang toolchain 2022-11-23 13:25:16 +03:00
Cao Sen Miao 86aa4df5b5 ESP32-H2: Introduce new target for ESP32H2 2022-11-23 14:38:05 +08:00
Ivan Grokhotkov 7a298f98ae
cmake: fix the linker type check for --whole-archive option
Checking that the host is macOS is not sufficient here, since the
linker is still a GNU linker when cross-compiling for a chip.
Instead, use the linker_type variable introduced in the previous
commit.
2022-11-21 13:08:05 +01:00
Ivan Grokhotkov b47155a70b
cmake: fix the map file not generated when compiling with Clang
When compiling for a chip target with Clang,
CMAKE_C_COMPILER_ID="Clang" but the linker is still a GNU linker.
Therefore we can still generate the map file.
2022-11-21 13:06:17 +01:00
Radek Tandler aad600c9ca Merge branch 'feature/storage_host_test_nvs' into 'master'
nvs_flash: Migrate host tests to CMake build system, use Linux partition API

Closes IDF-4697

See merge request espressif/esp-idf!20671
2022-11-17 02:05:35 +08:00
Jakob Hasse c381fee319 Merge branch 'feature/esp_system_linux' into 'master'
esp_system partially buildable on Linux

Closes IDF-5983

See merge request espressif/esp-idf!21055
2022-11-16 22:38:48 +08:00
radek.tandler ca7f073e7b nvs_flash/host_test: migrated to the CMake build system and nvs flash Linux implementation
Host tests of nvs_flash eligible to run in Linux implementation of nvs flash were migrated. Remaining test cases
were left in original folder. Migrated test cases use CMake instead of make.
2022-11-16 14:15:23 +01:00
Fu Hanxi fbef416c36 Merge branch 'bugfix/env_var_SDKCONFIG_DEFAULTS_fail_with_bootloader_subproject' into 'master'
build_system: stop looking for env var `SDKCONFIG_DEFAULTS` in bootloader subproject

See merge request espressif/esp-idf!21091
2022-11-16 19:14:11 +08:00
Fu Hanxi b5d9df8b6f build_system: stop looking for sdkconfig file specified by env var `SDKCONFIG_DEFAULTS` in bootloader subproject 2022-11-16 16:52:54 +08:00
Jakob Hasse 5b3a645813 feat(esp_system): Partially buildable on Linux now 2022-11-16 09:03:09 +01:00
Djordje Nedic ebb6c2e77b tools: Move out kconfig_new in favour of using the esp-idf-kconfig package
This commit removes all kconfig_new files and references to them and adds esp-idf-kconfig as a dependency and adequate wrappers to avoid breaking changes.
2022-11-15 21:19:51 +01:00
morris 7758c0c65b Merge branch 'gcc/tmp_hack_toolchain_libatomic' into 'master'
tools: bypass atomic instruction variant for esp32c6 temporarily

See merge request espressif/esp-idf!21087
2022-11-15 11:19:32 +08:00
Zim Kalinowski 04595966f3 Merge branch 'doc/api_guides_cplusplus' into 'master'
docs: add C++ support chapter to the API guides

See merge request espressif/esp-idf!20182
2022-11-14 20:20:31 +08:00
morris 08f05420c0 tools: bypass atomic instruction variant for esp32c6 temporarily
Current riscv32-esp-elf-gcc can't provide the atomic intrinsic
functions.

Bypass it for now. Will revert this commit when a new toolchain is
ready.
2022-11-14 19:44:03 +08:00
laokaiyao 8677216576 esp32h2: renaming esp32h2 to esp32h4 2022-11-08 17:05:33 +08:00
Ivan Grokhotkov 80d3dc9ac5 docs: add C++ support chapter to the API guides 2022-11-04 18:37:03 +01:00
KonstantinKondrashov 1f9260d790 all: Apply new version logic (major * 100 + minor) 2022-11-03 08:36:23 +00:00
Roland Dobai 40b48a5393 Merge branch 'tools/idf_py_size_output_file_opt' into 'master'
tools: Add --output-file argument to idf.py size commands

Closes IDF-5954

See merge request espressif/esp-idf!20354
2022-10-10 15:54:00 +08:00
Alexey Lapshin e6f7b1a3a0 tools: cmake: check tool supported version with idf_tools.py 2022-10-03 19:01:32 +04:00
Djordje Nedic 09e61e8a23 tools: Add --output-file argument to idf.py size commands
This commit ads the corresponding --output-file option from idf_size.py to idf.py.

This is needed because piping the idf.py size output to a file would result in CMake output being present in the file as well.
2022-09-27 15:41:36 +02:00
Roland Dobai d08898aabc Merge branch 'fix/tools-gdbinit-with-elf-symbols' into 'master'
tools: fixed elf symbols load if gdbinit specified

Closes IDF-4991 and GCC-246

See merge request espressif/esp-idf!18089
2022-09-26 16:20:19 +08:00
Alexey Lapshin 29655fe22a tools: fixed elf symbols load if gdbinit specified
ROM and bootloader symbols add to use in GDB (via 'idf.py gdb')
2022-09-21 22:39:03 +04:00
Rocha Euripedes 819dae8008 Merge branch 'feature/mqtt_cmakefile_cleanup' into 'master'
Mqtt:  Cmakelists.txt file simplification.

See merge request espressif/esp-idf!19966
2022-09-21 15:21:07 +08:00