Comment 2 for bug 1079184

Revision history for this message
Johan Hake (johan-hake) wrote : Re: [Bug 1079184] Re: plot-qt does not compile

On 11/15/2012 03:17 PM, Joachim Haga wrote:
> I believe HAS_FOO are defined at preprocessor level, not at cmake level.

Yes, but they are stored in the dolfin config cmake file which get
picked up in the local CMakeList file for that demo.

> DOLFIN_ENABLE_FOO should be set if you compile as "make demo_plot-qt" in
> the tree, but perhaps not if you compile stand-alone? Is that the issue?

Yes, that is what I did. I most often never compile all cpp demos from
the build directory. When I do that it do indeed compile the demo.

> It is possible to use FOO_FOUND instead, but that will fail if the
> libraries are installed, but disabled in the DOLFIN build. I guess that
> could be resolved by suitable #ifdefs.

But HAS_FOO does not get defined if ENABLE_FOO is False, so wouldn't it
be better to use the former?

Johan

> ** Changed in: dolfin
> Assignee: (unassigned) => Joachim Haga (jobh)
>