But there is a problem with linking. I can't write a unit test program and
link it to log_flags.C alone, because it uses the global CLIENT_STATE gstate
variable, so I need to link client_state.C too. Once I do that, I get a
zillion undefined references, and to solve them I end up bringing in 90% of
the core client code.
What do you think about putting all of the core client code except main.C in
a static library, and synecd having main.C and linking the static library?
This way I can have the unit test link to the same static library, and it
could test most of it.
--
Nicolas
(I read mailing lists through Gmane. Please don't Cc me on replies; it makes
me get one message on my newsreader and another on email.)
On absence of comments, I have done this in r1339 (split client into library
and app with main()).
However, I haven't added the actual unit tests yet.