<div dir="ltr"><div dir="ltr">On Tue, Feb 16, 2021 at 9:39 AM Jacob Faibussowitsch <<a href="mailto:jacob.fai@gmail.com">jacob.fai@gmail.com</a>> wrote:<br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div style="overflow-wrap: break-word;">Swarnava,<div><br></div><div>Perhaps try CXXFLAGS instead of CPPFLAGS. Alternatively, you may explicitly declare a %.o: %.cc target and force it to include your CPPFLAGS.</div></div></blockquote><div><br></div><div>No, do not do either of these things. We just need to figure out why it is not working for you. I will make a small example as soon as possible.</div><div><br></div><div>  Thanks,</div><div><br></div><div>     Matt</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div style="overflow-wrap: break-word;"><div><div>
<div dir="auto" style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;text-decoration:none"><div>Best regards,<br><br>Jacob Faibussowitsch<br>(Jacob Fai - booss - oh - vitch)<br>Cell: (312) 694-3391</div></div>

</div>
<div><br><blockquote type="cite"><div>On Feb 16, 2021, at 08:42, Matthew Knepley <<a href="mailto:knepley@gmail.com" target="_blank">knepley@gmail.com</a>> wrote:</div><br><div><div dir="ltr" style="font-family:Helvetica;font-size:12px;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;text-decoration:none"><div dir="ltr">On Mon, Feb 15, 2021 at 10:50 PM Barry Smith <<a href="mailto:bsmith@petsc.dev" target="_blank">bsmith@petsc.dev</a>> wrote:<br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Swarnava,<br><br>sddft.h is not a PETSc include file, nor is it used by PETSc so I think the issue is not directly to PETSc it is related to where sddft is on the machine and how it is found by your makefile.<br></blockquote><div><br></div><div>Barry,</div><div><br></div><div>His problem is that he is trying to put extra include flags on the compile line, but it is not working. I am wondering if his make is malfunctioning.</div><div><br></div><div>  Thanks,</div><div><br></div><div>     Matt</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">  Barry<br><br><br><br>> On Feb 15, 2021, at 7:47 PM, Swarnava Ghosh <<a href="mailto:swarnava89@gmail.com" target="_blank">swarnava89@gmail.com</a>> wrote:<br>><span> </span><br>> Dear Petsc developers and users,<br>><span> </span><br>> I am having some issue with building my code with the following makefile. I was earlier able to build this with the same makefile on a different machine. Would you please help me out on this issue?<br>><span> </span><br>> Contents of makefile:<br>> ==============================================<br>> all:sparc<br>><span> </span><br>> CPPFLAGS = -I ./inc -I ${MKLROOT}/include -L ${MKLROOT}/lib/ -llapack-addons -lmkl_intel_lp64 -lmkl_sequential -lmkl_core -lpthread<br>><span> </span><br>> SOURCECPP = ./src/<a href="http://main.cc" target="_blank">main.cc</a> ./src/<a href="http://initObjs.cc" target="_blank">initObjs.cc</a> ./src/<a href="http://readfiles.cc" target="_blank">readfiles.cc</a> ./src/<a href="http://energy.cc" target="_blank">energy.cc</a> ./src/<a href="http://ExchangeCorrelation.cc" target="_blank">ExchangeCorrelation.cc</a> ./src/<a href="http://occupation.cc" target="_blank">occupation.cc</a> ./src/<a href="http://poisson.cc" target="_blank">poisson.cc</a> ./src/<a href="http://chebyshev.cc" target="_blank">chebyshev.cc</a> ./src/<a href="http://scf.cc" target="_blank">scf.cc</a> ./src/<a href="http://mixing.cc" target="_blank">mixing.cc</a> ./src/<a href="http://forces.cc" target="_blank">forces.cc</a> ./src/<a href="http://relaxatoms.cc" target="_blank">relaxatoms.cc</a> ./src/<a href="http://multipole.cc" target="_blank">multipole.cc</a> ./src/<a href="http://electrostatics.cc" target="_blank">electrostatics.cc</a> ./src/<a href="http://tools.cc" target="_blank">tools.cc</a><br>><span> </span><br>> SOURCEH = ./inc/sddft.h ./inc/isddft.h<br>><span> </span><br>> OBJSC = ./src/main.o ./src/initObjs.o ./src/readfiles.o ./src/energy.o ./src/ExchangeCorrelation.o ./src/occupation.o ./src/poisson.o ./src/chebyshev.o ./src/scf.o ./src/mixing.o ./src/forces.o ./src/relaxatoms.o ./src/multipole.o ./src/electrostatics.o ./src/tools.o<br>><span> </span><br>> LIBBASE = ./lib/sparc<br>><span> </span><br>> CLEANFILES = ./lib/sparc<span> </span><br>><span> </span><br>> include ${PETSC_DIR}/lib/petsc/conf/variables<br>> include ${PETSC_DIR}/lib/petsc/conf/rules<br>><span> </span><br>> sparc: ${OBJSC} chkopts<br>> ${CLINKER} -Wall -o ${LIBBASE} ${OBJSC} ${PETSC_LIB}<br>> ${RM} $(SOURCECPP:%.cc=%.o)<br>><span> </span><br>> ===========================================<br>> Error:<br>> /home/swarnava/petsc/linux-gnu-intel/bin/mpicxx -o src/main.o -c -g     -I/home/swarnava/petsc/include -I/home/swarnava/petsc/linux-gnu-intel/include    `pwd`/src/<a href="http://main.cc" target="_blank">main.cc</a><br>> /home/swarnava/Research/Codes/SPARC/src/<a href="http://main.cc" target="_blank">main.cc</a>(24): catastrophic error: cannot open source file "sddft.h"<br>>   #include "sddft.h"<br>>                     ^<br>> ====================================================<br>><span> </span><br>> It's not able to see the header file though I have -I ./inc in  CPPFLAGS. The directory containing makefile has the directory "inc" with the headers and "src" with the .cc files.<br>><span> </span><br>> Thank you,<br>> Swarnava<br>><span> </span><br>><span> </span><br><br></blockquote></div><br clear="all"><div><br></div>--<span> </span><br><div dir="ltr"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div>What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>-- Norbert Wiener</div><div><br></div><div><a href="http://www.cse.buffalo.edu/~knepley/" target="_blank">https://www.cse.buffalo.edu/~knepley/</a></div></div></div></div></div></div></div></div></div></blockquote></div><br></div></div></blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div>What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>-- Norbert Wiener</div><div><br></div><div><a href="http://www.cse.buffalo.edu/~knepley/" target="_blank">https://www.cse.buffalo.edu/~knepley/</a><br></div></div></div></div></div></div></div></div>