mirror of
https://github.com/espressif/esp-idf.git
synced 2024-10-05 20:47:46 -04:00
cmake: Handle ESPPORT environment variable correctly
Closes https://github.com/espressif/esp-idf/issues/2553
This commit is contained in:
parent
1ee2bc46ed
commit
897670b0ab
@ -17,10 +17,11 @@ endif()
|
||||
# Note: we can't expand these environment variables in the main IDF CMake build,
|
||||
# because we want to expand them at flashing time not at CMake runtime (so they can change
|
||||
# without needing a CMake re-run)
|
||||
if(NOT ENV{ESPPORT})
|
||||
set(ESPPORT $ENV{ESPPORT})
|
||||
if(NOT ESPPORT)
|
||||
message("Note: esptool.py will search for a serial port. To specify a port, set the ESPPORT environment variable.")
|
||||
else()
|
||||
set(port_arg "-p $ENV{ESPPORT}")
|
||||
set(port_arg "-p ${ESPPORT}")
|
||||
endif()
|
||||
|
||||
set(ESPBAUD $ENV{ESPBAUD})
|
||||
|
Loading…
Reference in New Issue
Block a user