Merge branch 'bugfix/cmake_generators_v4.1' into 'release/v4.1'

tools: Force the order of cmake generators (v4.1)

See merge request espressif/esp-idf!7848
This commit is contained in:
Ivan Grokhotkov 2020-03-05 20:17:32 +08:00
commit a66955b36a

View file

@ -1,3 +1,4 @@
import collections
import multiprocessing import multiprocessing
import os import os
import platform import platform
@ -16,23 +17,23 @@ else:
MAKE_CMD = "make" MAKE_CMD = "make"
MAKE_GENERATOR = "Unix Makefiles" MAKE_GENERATOR = "Unix Makefiles"
GENERATORS = { GENERATORS = collections.OrderedDict([
# - command: build command line # - command: build command line
# - version: version command line # - version: version command line
# - dry_run: command to run in dry run mode # - dry_run: command to run in dry run mode
# - verbose_flag: verbose flag # - verbose_flag: verbose flag
"Ninja": { ("Ninja", {
"command": ["ninja"], "command": ["ninja"],
"version": ["ninja", "--version"], "version": ["ninja", "--version"],
"dry_run": ["ninja", "-n"], "dry_run": ["ninja", "-n"],
"verbose_flag": "-v" "verbose_flag": "-v"
}, }),
MAKE_GENERATOR: { (MAKE_GENERATOR, {
"command": [MAKE_CMD, "-j", str(multiprocessing.cpu_count() + 2)], "command": [MAKE_CMD, "-j", str(multiprocessing.cpu_count() + 2)],
"version": [MAKE_CMD, "--version"], "version": [MAKE_CMD, "--version"],
"dry_run": [MAKE_CMD, "-n"], "dry_run": [MAKE_CMD, "-n"],
"verbose_flag": "VERBOSE=1", "verbose_flag": "VERBOSE=1",
} })
} ])
SUPPORTED_TARGETS = ["esp32", "esp32s2beta"] SUPPORTED_TARGETS = ["esp32", "esp32s2beta"]