tcc -E: Let output_default be <file>.o instead of a.out
commit120334830231763bd3cb84fe6fb671142161f6de
authorKirill Smelkov <kirr@mns.spb.ru>
Sun, 20 Jun 2010 16:42:16 +0000 (20 20:42 +0400)
committerKirill Smelkov <kirr@mns.spb.ru>
Mon, 21 Jun 2010 16:49:46 +0000 (21 20:49 +0400)
treecb14706e29fe5b5cac6a6b92eb2ef0f770c64734
parent0c928da96d5fb8fe8f929db40b2d807053113f35
tcc -E: Let output_default be <file>.o instead of a.out

This affectes where `tcc -E -MD file.c` will place generated dependency
information -- previously, for `tcc -E` output_default was a.out, and so
deps were put into a.d .

Avoid this behaviour, by treating `tcc -E` as `tcc -c` with respect to
output_default computation.

This will not hurt anything else (preprocessor outputs to either stdout,
or to explicitely given (-o <file>) destination, so no default filename
is used here), and on the other hand `tcc -E -MD file.c` now puts
dependencies into file.d (the same behaviour as for gcc -E).

v2:

- restructured condition a bit to make it more clear
libtcc.c