<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Windows-1252">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
font-size:10.0pt;
font-family:"Calibri",sans-serif;}
span.EmailStyle19
{mso-style-type:personal-reply;
font-family:"Calibri",sans-serif;
color:windowtext;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
{page:WordSection1;}
--></style>
</head>
<body lang="en-RU" link="#0563C1" vlink="#954F72" style="word-wrap:break-word">
<div class="WordSection1">
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt">Hi Satish,<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt">Thanks for the reply, I am afraid it produces the same error still.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"><o:p> </o:p></span></p>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal" style="margin-bottom:12.0pt"><b><span style="font-size:12.0pt;color:black">From:
</span></b><span style="font-size:12.0pt;color:black">Satish Balay <balay@mcs.anl.gov><br>
<b>Date: </b>Thursday, 3 February 2022, 19:39<br>
<b>To: </b>Evstafyeva,Tamara <te307@cam.ac.uk><br>
<b>Cc: </b>petsc-users <petsc-users@mcs.anl.gov><br>
<b>Subject: </b>Re: [petsc-users] cannot open source file "petsc.h"<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt">You an try the following:<br>
<br>
- remove<br>
PETSC_INCLUDE=/cosma/home/dp092/dc-evst1/petsc/include<br>
PETSC_LIB=/cosma/home/dp092/dc-evst1/petsc/lib<br>
<br>
- remove<br>
include ${PETSC_DIR}/lib/petsc/conf/rules<br>
include ${PETSC_DIR}/lib/petsc/conf/test<br>
<br>
- remove<br>
petsc.pc := $(PETSC_DIR)/$(PETSC_ARCH)/lib/pkgconfig/petsc.pc<br>
<br>
i.e only keep:<br>
include ${PETSC_DIR}/lib/petsc/conf/variables<br>
<br>
You have:<br>
<br>
LINK += $(PETSC_LIB)<br>
<br>
Similarly you need:<br>
cxxcppflags += $(PETSC_CXXCPPFLAGS)<br>
<br>
Satish<br>
<br>
On Thu, 3 Feb 2022, Evstafyeva,Tamara wrote:<br>
<br>
> Dear Satish,<br>
> <br>
> Thank you for getting back!<br>
> <br>
> I am attaching mu current GNUmakefile and the logs for it and the ex19.<br>
> <br>
> Let me know if anything else is needed and thanks in advance,<br>
> <br>
> Tamara<br>
> <br>
> From: Satish Balay <balay@mcs.anl.gov><br>
> Date: Thursday, 3 February 2022, 18:53<br>
> To: Evstafyeva,Tamara <te307@cam.ac.uk><br>
> Cc: petsc-users@mcs.anl.gov <petsc-users@mcs.anl.gov><br>
> Subject: Re: [petsc-users] cannot open source file "petsc.h"<br>
> Can you send your current makefile?<br>
> <br>
> Also send compile log [including errors] when building with this makefile.<br>
> <br>
> Also send us compile log from:<br>
> <br>
> cd src/snes/tutorials<br>
> make ex19<br>
> <br>
> Satish<br>
> <br>
> On Thu, 3 Feb 2022, Evstafyeva,Tamara wrote:<br>
> <br>
> > To whom it may concern,<br>
> ><br>
> > I am using a code that utilizes some of the PETSC capabilities. After configuring and installing PETSC on a cluster, I have set my environment variables $PETSC_DIR and $PETSC_ARCH. The code using PETSC compiles using GNUMakefile and so using instructions
on the website and in Makefile.user I added the following lines to the make file:<br>
> ><br>
> ><br>
> > include ${PETSC_DIR}/lib/petsc/conf/variables<br>
> ><br>
> > include ${PETSC_DIR}/lib/petsc/conf/rules<br>
> ><br>
> > include ${PETSC_DIR}/lib/petsc/conf/test<br>
> ><br>
> ><br>
> > petsc.pc := $(PETSC_DIR)/$(PETSC_ARCH)/lib/pkgconfig/petsc.pc<br>
> ><br>
> > When compiling the code I get that the head files of PETSC are not recognized:<br>
> ><br>
> > catastrophic error: cannot open source file "petsc.h"<br>
> ><br>
> > This seems like a trivial problem, however I cannot seem to figure out what exactly went wrong. I’d expect this cannot be installation problem, and most likely the linking? I would really appreciate some direction on this problem.<br>
> ><br>
> > Thank you,<br>
> ><br>
> > Tamara<br>
> ><br>
> ><br>
> ><br>
> <o:p></o:p></span></p>
</div>
</div>
</body>
</html>