1 RcB - rofl0r's C builder.
2 =========================
4 builds a C file holding a main method, by checking the headers it includes for RcB tags.
5 such a tag might look like
9 this tells RcB that the symbols defined in this header can be found in the listed C files.
10 after gathering all dependencies, it starts trying to compile the main file, and analyses the
11 compiler output for which dependencies are not fulfilled.
12 it then starts multiple passes in which it compiles each referenced C file into an object file,
13 and scans the symbols it defines. if those match the missing ones, the file will be added to
14 the list of final dependencies.
16 finally if there are no missing deps left, it will link them all together and create a simple
17 text file containing a list of the required compilation units.
18 on the next invocation, it will compile the target by simply passing all required C files to
19 the compiler in one turn. this is much faster than compiling every C file on its own, and
20 allows to use the same CFLAGS on all of them, and do nice optimization stuff like -flto and
21 -fwhole-program, which only work really nicely if the compiler gets all C files in exactly
28 "//RcB:" tells rcb that a rcb command starts here, and is treated by the C compiler as a
31 currently DEP is the only command recognized by rcb. it tells rcb to add param to the
36 RcB uses the following environment variables:
43 if you need to link to a specific library, you can pass it to rcb after the name of the main
44 C file. just run rcb without arguments to see a list of options.