<div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Mar 5, 2013 at 5:49 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:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div id=":359">From the below I am assuming that PETSC_USE_EXTERN_CXX is equivalent to --with-c-support   Is this correct?<br>
</div></blockquote><div><br></div><div style>Yes,</div><div style><br></div><div style><div>config/PETSc/utilities/languages.py-    '''Check c-support c++-support and other misc tests'''</div><div>
config/PETSc/utilities/languages.py-    if self.clanguage == 'Cxx' and self.framework.argDB['with-c-support']:</div><div>config/PETSc/utilities/languages.py-      self.cSupport = 1</div><div>config/PETSc/utilities/languages.py:      self.addDefine('USE_EXTERN_CXX', '1')</div>
<div>config/PETSc/utilities/languages.py-      self.framework.logPrint('Turning off C++ name mangling')</div><div>config/PETSc/utilities/languages.py-    else:</div><div>config/PETSc/utilities/languages.py-      self.cSupport = 0</div>
<div><br></div><div style><br></div><div style>Matt, what is this about?</div><div><br></div><div>config/PETSc/utilities/languages.py-  def configureExternC(self):</div><div>config/PETSc/utilities/languages.py-    '''Protect C bindings from C++ mangling'''</div>
<div>config/PETSc/utilities/languages.py-    if self.clanguage == 'C':</div><div>config/PETSc/utilities/languages.py:      self.addDefine('USE_EXTERN_CXX',' ')</div><div>config/PETSc/utilities/languages.py-    return</div>
<div>config/PETSc/utilities/languages.py-</div><div>config/PETSc/utilities/languages.py-  def configureFortranLanguage(self):</div><div> <br></div></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<div id=":359">
<br>
   And I assume that --with-c-support means that PETSc is compiled with C++ but does not use name mangling   Is this correct?<br></div></blockquote><div><br></div><div style>Yes</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<div id=":359">
<br>
   If the above two are correct does the name PETSC_USE_EXTERN_CXX actually correlate to what it means? Could it be changed to something meaningful?<br></div></blockquote><div><br></div><div style>--with-extern-c-interface (or --with-c-interface) and PETSC_USE_EXTERN_C_INTERFACE?</div>
<div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div id=":359">
<br>
    Please explain,<br>
<br>
     Barry<br>
<br>
<br>
#if defined(PETSC_CLANGUAGE_CXX) && !defined(PETSC_USE_EXTERN_CXX) && !defined(__cplusplus)<br>
#error "PETSc configured with --with-clanguage=c++ and NOT --with-c-support - it can be used only with a C++ compiler"<br>
#endif</div></blockquote></div><br><br></div></div>