iscsi-initiator-utils: check file existence before moving

Check the file existence before moving to avoid the error:
| mv: cannot stat /<build_dir>/git/utils/fwparam_ibft/prom_lex.l:
| No such file or directory

Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
Signed-off-by: Joe MacDonald <joe_macdonald@mentor.com>
This commit is contained in:
Jackie Huang
2017-11-09 19:04:52 +08:00
committed by Joe MacDonald
parent b55738ef8d
commit 5bb1957667
@@ -59,7 +59,9 @@ do_configure () {
do_compile () { do_compile () {
# Make sure we DO NOT regenerate prom_lex.c. # Make sure we DO NOT regenerate prom_lex.c.
mv ${S}/utils/fwparam_ibft/prom_lex.l ${S}/utils/fwparam_ibft/prom_lex.l.unused if [ -f ${S}/utils/fwparam_ibft/prom_lex.l ]; then
mv ${S}/utils/fwparam_ibft/prom_lex.l ${S}/utils/fwparam_ibft/prom_lex.l.unused
fi
oe_runmake -C ${S} ${EXTRA_OEMAKE} user oe_runmake -C ${S} ${EXTRA_OEMAKE} user
} }