Add input files/libs and reloc_output switch to TCCState
commita919a373da07305e763d1cb4ecb3a5a44bdebb2a
authorKirill Smelkov <kirr@mns.spb.ru>
Sun, 20 Jun 2010 15:49:58 +0000 (20 19:49 +0400)
committerKirill Smelkov <kirr@mns.spb.ru>
Sun, 20 Jun 2010 16:30:01 +0000 (20 20:30 +0400)
treedad54d6faec588493d81d3f2b57f2d186da751d8
parent66b54af8ea8a2277e5d6b8a0c1661d42fea4a639
Add input files/libs and reloc_output switch to TCCState

files[0], and reloc_outpu will be needed for (upcoming in the next
patch) "compute default outfile name" refactored into libtcc function.

Also, since for symmetry and from libification point of view, it makes
some sense to also put all information about what was given as input to
compilation into TCCState, let's not only put files[0], but all
files and all libraries given explicitely by user.

One point: I've used bitfield for reloc_output & trimmed down
output_type to 8 bits so that TCCState stays the same in size, and also
access to output_type is (hopefully) is not slower.

By the way -- as of today, sizeof(TCCState) on i686-pc-linux-gnu is 2884
bytes...
libtcc.c
libtcc.h
tcc.c
tcc.h