Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[cdt-dev] Re: New build paradigms

JDT has a built-in Java compiler. I'm not suggesting that for CDT - I don't
think it is possible since there is no common binary output. What I have in
mind is a C builder preference page that gives the external commands and
options for building and linking. For example, it might say to compile a C
file into an object file you use the command "cc -c ${sourcefilename} -o
${objectfilename}". Plus maybe a combo box that would switch all the
settings between gnu, visual studio, K&R C, etc. (and probably a way to save
a custom configuration/target).

When a source file changes, it's easy to recompile the source and then
relink. When you change a header file, well that's a little harder. For each
source file the code would have to automatically maintain a list of headers
it depends on, and then when one of the headers changes it would rebuild all
the sources that include it. I've used systems that didn't do this and it
was not ideal but ok because I could do a full rebuild if I wanted. I've
also used systems that *do* do this and occasionally they get it wrong so I
don't 100% trust it - first odd bug I see I rebuild everything and see if
that helps and it often does. So I'm not convinced header file dependencies
have to be handled for it to be useful.

There are many small-ish types of projects where a make or ant file is
overkill and having to generate one (by hand or by command) wastes time. So
I think having the capability to build without one would make the easy cases
easier, while still making the hard cases possible.

"Chris Songer" <songer=66fqrpuXKgGB+jHODAdFcQ@xxxxxxxxxxxxxxxx> wrote in
message news:5.1.0.14.2.20021213094326.0217db78@xxxxxxxxxxxxxxxxxxxxxxxx...
>
> I think that 1 is hard for C/C++. In particular, the C-preprocessor makes
> it open season on what things change when header files change. If 1 is
> going to happen, it is going to come out of an amazing piece of work from
> the folks working on the CDOM.







Back to the top