<div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Feb 15, 2013 at 12:38 PM, Barry Smith <span dir="ltr"><<a href="mailto:bsmith@mcs.anl.gov" target="_blank">bsmith@mcs.anl.gov</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div id=":911"> How does one prevent this problem?<br>
<br>
[ 15%] Building C object CMakeFiles/petsc.dir/src/ksp/pc/impls/is/nn/nn.c.o<br>
In file included from /Users/barrysmith/Src/petsc-dev/src/ksp/pc/impls/bjacobi/bjacobi.c:184:<br>
/Users/barrysmith/Src/petsc-dev/include/petscdraw.h:283: error: redefinition of typedef ‘PetscDrawLG’<br>
/Users/barrysmith/Src/petsc-dev/include/petscksp.h:598: error: previous declaration of ‘PetscDrawLG’ was here</div></blockquote></div><br>Heh, I thought I remembered that duplicate typedefs were invalid in C, but gcc happily compiled it without a warning. In fact, they _are_ allowed in C11, but not in our old, crusty version of C.</div>
<div class="gmail_extra"><br></div><div class="gmail_extra" style>I guess the reliable way to do this would be to have petsc-private/${pkg}types.h that were included internally by those headers that depend on the types, like petscksp.h. It wouldn't be user-visible, but I'm not sure it's worthwhile.</div>
</div>