windres: add quotes around preprocessor cmd if needed
authorClément Chigot <chigot@adacore.com>
Thu, 16 Jun 2022 11:43:26 +0000 (13:43 +0200)
committerClément Chigot <chigot@adacore.com>
Tue, 28 Jun 2022 14:53:23 +0000 (16:53 +0200)
commitfadaf8f7f99f8fe81aa8403c5d90c95cae5bd2ec
tree4b038d634af1070ec944354a2979b8cab0622bb1
parentdbcbf67ca565ec29f13a2302dcdf9b01ef7832ca
windres: add quotes around preprocessor cmd if needed

This patch ensures that the gcc binary called by windres is quoted if
needed. Otherwise, errors can occur if the gcc is under a folder having
a name containing a space (eg "Program Files").

binutils/
* resrc.c (DEFAULT_PREPROCESSOR): Split into...
(DEFAULT_PREPROCESSOR_CMD): that...
(DEFAULT_PREPROCESSOR_ARGS): and that.
(look_for_default): Add quotes around the command if needed.
(read_rc_file): Adapt to new defines.
binutils/resrc.c