Skip to content

Commit

Permalink
check 0 idf version first
Browse files Browse the repository at this point in the history
  • Loading branch information
elcritch committed Aug 27, 2024
1 parent 8dd44f7 commit ecc1b1d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/nesper/consts.nim
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,11 @@ const
template ESP_IDF_VERSION_STR*: string = $ESP_IDF_MAJOR & "." & $ESP_IDF_MINOR & "." & $ESP_IDF_PATCH

static:
if ESP_IDF_MAJOR notin [4, 5]:
error("Incorrect esp-idf major version: " & $ESP_IDF_MAJOR)
if ESP_IDF_VERSION == ESP_IDF_VERSION_VAL(0, 0, 0):
warning("ESP_IDF_VERSION: " & ESP_IDF_VERSION_STR)
error("Must set esp-idf version using `-d:ESP_IDF_VERSION=4.4` or using an environment variable `export ESP_IDF_VERSION=4.4`")
if ESP_IDF_MAJOR notin [4, 5]:
error("Incorrect esp-idf major version: " & $ESP_IDF_MAJOR)


## Definitions for error constants.
Expand Down

0 comments on commit ecc1b1d

Please sign in to comment.