zephyr/cmake
Nicolas Pitre f57ba2d30c cmake: toolchain_cc_imacros: don't use space separated arguments
Because CMake explicitly deduplicates arguments, it is not possible
to use toolchain_cc_imacros() multiple times as the later "-imacros"
are stripped away, leaving the associated file arguments dangling.
The documented workaround in the CMake manual involves some "SHELL:..."
construct but that doesn't get through zephyr_compile_options()
undammaged.

Let's simply remove this issue altogether by replacing "-imacros x.h"
with the joined form "--imacros=x.h" instead. Both gcc and clang
support this syntax.

FYI, this joined form is also available for other arguments such as:

	-include x.h   -->   --include=x.h
	-A foo         -->   --assert=foo
	-D foo         -->   --define-macro=foo
	-U foo         -->   --undefine-macro=foo

Etc.

Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
2019-06-25 23:29:22 -04:00
..
app cmake: warn if inconsistency between CMAKE_SOURCE_DIR and ZEPHYR_BASE 2019-06-11 12:57:18 -04:00
backports cmake: Fixed python detection bug 2018-12-21 11:13:03 +01:00
compiler cmake: toolchain_cc_imacros: don't use space separated arguments 2019-06-25 23:29:22 -04:00
emu cmake: Set NO_QEMU_SERIAL_BT_SERVER when CONFIG_BT_NO_DRIVER is set 2019-06-24 22:36:59 +02:00
flash cmake: delete obsolete deprecation checks 2019-06-07 13:43:51 +02:00
ide license: cleanup: add SPDX Apache-2.0 license identifier 2019-04-07 08:45:22 -04:00
linker/ld docs: fix misspelling across the tree 2019-06-19 15:34:13 -05:00
reports license: cleanup: add SPDX Apache-2.0 license identifier 2019-04-07 08:45:22 -04:00
toolchain docs: fix misspelling across the tree 2019-06-19 15:34:13 -05:00
usage cmake: Split out board listing from usage 2019-04-25 09:14:06 -07:00
util license: cleanup: add SPDX Apache-2.0 license identifier 2019-04-07 08:45:22 -04:00
boards.cmake cmake: Split out board listing from usage 2019-04-25 09:14:06 -07:00
ccache.cmake license: cleanup: add SPDX Apache-2.0 license identifier 2019-04-07 08:45:22 -04:00
cfb.cmake generated/cfb_font_dice.h: don't leak absolute paths in comment 2019-06-19 08:40:59 -04:00
dts.cmake cmake: DT: Add support for out-of-tree binding root directories 2019-04-17 16:25:41 -05:00
extensions.cmake docs: fix misspelling across the tree 2019-06-19 15:34:13 -05:00
extra_flags.cmake license: cleanup: add SPDX Apache-2.0 license identifier 2019-04-07 08:45:22 -04:00
fpu-for-gcc-m-cpu.cmake license: cleanup: add SPDX Apache-2.0 license identifier 2019-04-07 08:45:22 -04:00
gcc-m-cpu.cmake license: cleanup: add SPDX Apache-2.0 license identifier 2019-04-07 08:45:22 -04:00
generic_toolchain.cmake cmake: Set TOOLCHAIN_HOME for Zephyr's SDK 2019-04-30 09:33:54 -04:00
git.cmake cmake: explain BUILD_VERSION and KERNEL_VERSION_* 2019-05-09 11:52:05 +02:00
hex.cmake license: cleanup: add SPDX Apache-2.0 license identifier 2019-04-07 08:45:22 -04:00
host-tools.cmake cmake: fix regex for west version check in host-tools.cmake 2019-05-21 08:19:09 -04:00
kconfig.cmake guiconfig: Add a graphical configuration interface 2019-05-30 09:54:06 -04:00
kobj.cmake cmake: Fix missing dependency 2019-05-16 07:47:18 -05:00
pristine.cmake license: cleanup: add SPDX Apache-2.0 license identifier 2019-04-07 08:45:22 -04:00
python.cmake license: cleanup: add SPDX Apache-2.0 license identifier 2019-04-07 08:45:22 -04:00
target_toolchain.cmake cmake: Toolchain abstraction: use LINKER, introduce toolchain_ld_base 2019-04-28 12:52:18 -04:00
version.cmake cmake: explain BUILD_VERSION and KERNEL_VERSION_* 2019-05-09 11:52:05 +02:00
zephyr_module.cmake cmake: zephyr_modules: Add west executable argument 2019-05-03 14:23:09 -04:00