[Distutils] More questions on distutils...

Lyle Johnson jlj@cfdrc.com
Mon, 8 May 2000 17:31:57 -0500


Greg,

While working out the stuff for supporting Borland's C/C++ compiler under
the Distutils, I've gotten a little confused about the division of
responsbilities for the various command and compiler classes. The specific
case I'm studying right now is the "built_ext" command (implemented in
distutils/command/built_ext.py).

If you take a look at the build_extensions() function defined in this class,
it appears that he "knows" some things about the "msvc" compiler. It seems
like you'd want to avoid letting the various commands know these kinds of
details about specific implementations of the CCompiler class. Ideally, they
would stick to the basic CCompiler interface, no?

I'm not attacking the current implementation -- I know that the primary goal
to this point is to get things working. But now I'm faced with the decision
about where to put certain Borland-specific flags and so forth -- do they
come in solely through the new BCPPCompiler class, or do some of them also
filter in through the build_ext command (and his siblings)?

Please clue me in ;) I've got the Borland stuff basically working now but
I'd like to get it a little cleaner before submitting my proposed patches,
etc.

Thanks,

Lyle