.i as file extension
Add a ".i" extension as alias for ".c" GCC and file extensions: .i C source code which should not be preprocessed. Before a patch: ./tcc -E tccasm.c -o tccasm.i ./tcc -c tccasm.i -o tccasm.o tccasm.i:1: error: unrecognized file type
This commit is contained in:
2
libtcc.c
2
libtcc.c
@ -1154,7 +1154,7 @@ ST_FUNC int tcc_add_file_internal(TCCState *s1, const char *filename, int flags)
|
|||||||
goto the_end;
|
goto the_end;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!ext[0] || !PATHCMP(ext, "c")) {
|
if (!ext[0] || !PATHCMP(ext, "c") || !PATHCMP(ext, "i")) {
|
||||||
/* C file assumed */
|
/* C file assumed */
|
||||||
ret = tcc_compile(s1);
|
ret = tcc_compile(s1);
|
||||||
goto the_end;
|
goto the_end;
|
||||||
|
|||||||
Reference in New Issue
Block a user