Small Surprise in IDF Project Example: Purposeful or Typographical Error?

Halfnium
Posts: 11
Joined: Thu Jul 02, 2020 10:38 pm

Small Surprise in IDF Project Example: Purposeful or Typographical Error?

Postby Halfnium » Fri Jul 17, 2020 2:42 am

New to the ESP32, IDF I carefully watched the application build process. I was surprised to note that building the "hello_world" example in "../esp/esp_idf/examples/get-started" generates files named "hello-world" (of types .bin, .elf and .map). That's right, a dash crept into the file names in place of the expected underscore.

Simple to understand: Both the "CMakeLists.txt" and "Makefile" at the project's top level give the project's name as "hello-world" for some reason. That is easy to change and produces the desired result.

As a new user, I would like to understand if this is a subtle, purposeful matter of style in naming projects and intermediate files or a minor typographical error.

Thanks!

ESP_Angus
Posts: 2344
Joined: Sun May 08, 2016 4:11 am

Re: Small Surprise in IDF Project Example: Purposeful or Typographical Error?

Postby ESP_Angus » Fri Jul 17, 2020 7:03 am

Hi Halfnium,

Sorry for the confusion caused. This is a typographical error. There are a few places in ESP-IDF where the path uses hyphens, and a few where it uses underscores. And the underscores/hyphens in the project names are similarly inconsistent.

We haven't gotten around to fixing/standardizing this yet, but it doesn't exist for any predetermined reason. If you're creating your own project then you can use hyphens or underscores in both the directory name and the project name, in whatever way suits.

Angus

Who is online

Users browsing this forum: No registered users and 424 guests