<div dir="auto">Hi Amneet,<div dir="auto"><br></div><div dir="auto">Without libmesh, even for PETSc with MATLAB is not working. It is showing error for both 3.13.4 and 3.17.5 versions.</div><div dir="auto"><br></div><div dir="auto">I am trying to install IBAMR in HPC cluster with libmesh and this is for general usage not only for WEC. This I tried without linking Matlab with PETSc. Here also I got the error while configuring libmesh 1.6.2 that PETSc was not found but --enable-petsc-required is specified.</div><div dir="auto"><br></div><div dir="auto">The reason for specifically asking for libmesh with PETSc and Matlab is in the cfd-mpc-wecs application for complicated geometries it is mentioned to build cfd-mpc-wecs with libmesh construct.</div><div dir="auto"><br></div><div dir="auto">For the past 10 days I am trying these various things and ended up with errors. </div><div dir="auto">I want to solve this and proceed further to do my research work.</div><div dir="auto"><br></div><div dir="auto">Please help me to solve this as soon as possible.</div><div dir="auto"><br></div><div dir="auto"><br></div><div dir="auto">Thanks and Regards</div><div dir="auto">Srinivas</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Sep 1, 2023, 19:48 Amneet Bhalla <<a href="mailto:mail2amneet@gmail.com">mail2amneet@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto">Hi Srinivas,</div><div dir="auto"><br></div><div dir="auto">As discussed earlier you don’t need libMesh for the WEC application. You can just work with PETSc <span style="color:rgb(49,49,49);font-family:-apple-system,"Helvetica Neue";word-spacing:1px">3.17.5 that builds with Matlab. </span></div><div dir="auto"><span style="color:rgb(49,49,49);font-family:-apple-system,"Helvetica Neue";word-spacing:1px"><br></span></div><div dir="auto"><span style="color:rgb(49,49,49);font-family:-apple-system,"Helvetica Neue";word-spacing:1px">Do you have a specific reason for wanting to build libMesh?</span></div><div dir="auto"><span style="color:rgb(49,49,49);font-family:-apple-system,"Helvetica Neue";word-spacing:1px"><br></span></div><div dir="auto"><span style="color:rgb(49,49,49);font-family:-apple-system,"Helvetica Neue";word-spacing:1px">Thanks,</span></div><div dir="auto"><font color="#313131" face="-apple-system, Helvetica Neue"><span style="word-spacing:1px">—Amneet</span></font></div><div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Aug 31, 2023 at 10:16 PM INTURU SRINIVAS 20PHD0548 via petsc-users <<a href="mailto:petsc-users@mcs.anl.gov" target="_blank" rel="noreferrer">petsc-users@mcs.anl.gov</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>Hi,</div><div><br></div><div>I ran "make all" for petsc 3.13.4 by removing all occurrences of "-lut -licudata -licui18n -licuuc". When I ran "make test" got the following errors</div><div>in petsc/3.13.4/linux-debug:<br></div><div>TEST linux-debug/tests/counts/tao_leastsquares_tutorials_matlab-matlab_ls_test.counts<br>not ok tao_leastsquares_tutorials_matlab-matlab_ls_test # Error code: 124<br># Running problem 5<br># [0]PETSC ERROR: --------------------- Error Message --------------------------------------------------------------<br># [0]PETSC ERROR: Error in external library<br># [0]PETSC ERROR: Unable to start MATLAB engine on <br># [0]PETSC ERROR: See <a href="https://www.mcs.anl.gov/petsc/documentation/faq.html" target="_blank" rel="noreferrer">https://www.mcs.anl.gov/petsc/documentation/faq.html</a> for trouble shooting.<br># [0]PETSC ERROR: Petsc Release Version 3.13.4, Aug 01, 2020 <br># [0]PETSC ERROR: ../matlab_ls_test on a linux-debug named MB108SMEC028 by vit Fri Sep 1 10:01:11 2023<br># [0]PETSC ERROR: Configure options --CC=/home/vit/sfw/linux/openmpi/4.1.4/bin/mpicc --CXX=/home/vit/sfw/linux/openmpi/4.1.4/bin/mpicxx --FC=/home/vit/sfw/linux/openmpi/4.1.4/bin/mpif90 --with-debugging=1 --download-hypre=1 --download-fblaslapack=1 --with-x=0 --with-matlab-dir=/usr/local/MATLAB/R2020b/ --with-matlab-engine=1 --with-matlab-engine-dir=/usr/local/MATLAB/R2020b/extern/engines/<br># [0]PETSC ERROR: #1 PetscMatlabEngineCreate() line 67 in /home/vit/sfw/petsc/3.13.4/src/sys/classes/matlabengine/matlab.c<br># [0]PETSC ERROR: #2 main() line 126 in /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c<br># [0]PETSC ERROR: PETSc Option Table entries:<br># [0]PETSC ERROR: -prob_id 5<br># [0]PETSC ERROR: -tao_smonitor<br># [0]PETSC ERROR: ----------------End of Error Message -------send entire error message to petsc-maint@mcs.anl.gov----------<br># --------------------------------------------------------------------------<br># MPI_ABORT was invoked on rank 0 in communicator MPI_COMM_SELF<br># with errorcode 126076.<br># <br># NOTE: invoking MPI_ABORT causes Open MPI to kill all MPI processes.<br># You may or may not see output from other processes, depending on<br># exactly when Open MPI kills them.<br># --------------------------------------------------------------------------<br> ok tao_leastsquares_tutorials_matlab-matlab_ls_test # SKIP Command failed so no diff</div><div><br></div><div>in petsc/3.13.4/linux-opt</div><div> TEST linux-opt/tests/counts/tao_leastsquares_tutorials_matlab-matlab_ls_test.counts<br>not ok tao_leastsquares_tutorials_matlab-matlab_ls_test # Error code: 124<br># Running problem 5<br># [0]PETSC ERROR: --------------------- Error Message --------------------------------------------------------------<br># [0]PETSC ERROR: Error in external library<br># [0]PETSC ERROR: Unable to start MATLAB engine on <br># [0]PETSC ERROR: See <a href="https://www.mcs.anl.gov/petsc/documentation/faq.html" target="_blank" rel="noreferrer">https://www.mcs.anl.gov/petsc/documentation/faq.html</a> for trouble shooting.<br># [0]PETSC ERROR: Petsc Release Version 3.13.4, Aug 01, 2020 <br># [0]PETSC ERROR: ../matlab_ls_test on a linux-opt named MB108SMEC028 by vit Fri Sep 1 10:34:12 2023<br># [0]PETSC ERROR: Configure options --CC=/home/vit/sfw/linux/openmpi/4.1.4/bin/mpicc --CXX=/home/vit/sfw/linux/openmpi/4.1.4/bin/mpicxx --FC=/home/vit/sfw/linux/openmpi/4.1.4/bin/mpif90 --COPTFLAGS=-O3 --CXXOPTFLAGS=-O3 --FOPTFLAGS=-O3 --PETSC_ARCH=linux-opt --with-debugging=0 --download-hypre=1 --with-x=0 --download-fblaslapack=1 --with-matlab-dir=/usr/local/MATLAB/R2020b/ --with-matlab-engine=1 --with-matlab-engine-dir=/usr/local/MATLAB/R2020b/extern/engines/<br># [0]PETSC ERROR: #1 PetscMatlabEngineCreate() line 67 in /home/vit/sfw/petsc/3.13.4/src/sys/classes/matlabengine/matlab.c<br># [0]PETSC ERROR: #2 main() line 126 in /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c<br># [0]PETSC ERROR: PETSc Option Table entries:<br># [0]PETSC ERROR: -prob_id 5<br># [0]PETSC ERROR: -tao_smonitor<br># [0]PETSC ERROR: ----------------End of Error Message -------send entire error message to petsc-maint@mcs.anl.gov----------<br># --------------------------------------------------------------------------<br># MPI_ABORT was invoked on rank 0 in communicator MPI_COMM_SELF<br># with errorcode 126076.<br># <br># NOTE: invoking MPI_ABORT causes Open MPI to kill all MPI processes.<br># You may or may not see output from other processes, depending on<br># exactly when Open MPI kills them.<br># --------------------------------------------------------------------------<br> ok tao_leastsquares_tutorials_matlab-matlab_ls_test # SKIP Command failed so no diff.</div><div><br></div><div>The same errors occurred for petsc 3.17.5 version. I am sharing the config.log and make.log for both petsc 3.13.4 and petsc 3.17.5. Please find the attachment and do the needful.</div><div><br></div><div>Thanks and regards</div></div><div dir="ltr"><div>Srinivas<br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Aug 29, 2023 at 10:56 PM Satish Balay <<a href="mailto:balay@mcs.anl.gov" target="_blank" rel="noreferrer">balay@mcs.anl.gov</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Well - you sent in libmesh log not petsc's configure.log/make.log for petsc-3.17<br>
<br>
Anyway - with petsc-3.13 - you have:<br>
<br>
>>>><br>
<br>
Matlab:<br>
Includes: -I/usr/local/MATLAB/R2020b/extern/include<br>
/usr/local/MATLAB/R2020b<br>
MatlabEngine:<br>
Library: -Wl,-rpath,/usr/local/MATLAB/R2020b/sys/os/glnxa64:/usr/local/MATLAB/R2020b/bin/glnxa64:/usr/local/MATLAB/R2020b/extern/lib/glnxa64 -L/usr/local/MATLAB/R2020b/bin/glnxa64 -L/usr/local/MATLAB/R2020b/extern/lib/glnxa64 -leng -lmex -lmx -lmat -lut -licudata -licui18n -licuuc<br>
Language used to compile PETSc: C<br>
<<<<<<br>
<br>
With petsc-3.19 (and matlab-R2022a) - we are seeing:<br>
<br>
<a href="https://gitlab.com/petsc/petsc/-/jobs/4904566768" rel="noreferrer noreferrer" target="_blank">https://gitlab.com/petsc/petsc/-/jobs/4904566768</a><br>
<br>
>>><br>
Matlab:<br>
Includes: -I/nfs/gce/software/custom/linux-ubuntu22.04-x86_64/matlab/R2022a/extern/include<br>
Libraries: -Wl,-rpath,/nfs/gce/software/custom/linux-ubuntu22.04-x86_64/matlab/R2022a/bin/glnxa64 -L/nfs/gce/software/custom/linux-ubuntu22.04-x86_64/matlab/R2022a/bin/glnxa64 -leng -lmex -lmx -lmat<br>
Executable: /nfs/gce/software/custom/linux-ubuntu22.04-x86_64/matlab/R2022a<br>
mex: /nfs/gce/software/custom/linux-ubuntu22.04-x86_64/matlab/R2022a/bin/mex<br>
matlab: /nfs/gce/software/custom/linux-ubuntu22.04-x86_64/matlab/R2022a/bin/matlab -glnxa64<br>
<<<<br>
<br>
I.e "-lut -licudata -licui18n -licuuc" are not preset here. This might be a change wrt newer matlab versions.<br>
<br>
You can:<br>
<br>
- edit /home/vit/sfw/petsc/3.13.4/linux-opt/lib/petsc/conf/petscvariables and remove all occurrences of "-lut -licudata -licui18n -licuuc"<br>
- now run 'make all' in '/home/vit/sfw/petsc/3.13.4'<br>
<br>
And see if the build works now.<br>
<br>
Satish<br>
<br>
On Tue, 29 Aug 2023, INTURU SRINIVAS 20PHD0548 via petsc-users wrote:<br>
<br>
> I am sharing the log files while building petsc3.13.4 with matlab and also<br>
> the log file while building libmesh with petsc3.17.5 and matlab. Building<br>
> petsc 3.17.5 with matlab was done successfully. But libmesh is not able to<br>
> find the petsc<br>
> Please find the attachments.<br>
> <br>
> On Tue, Aug 29, 2023 at 7:31 PM Satish Balay <<a href="mailto:balay@mcs.anl.gov" target="_blank" rel="noreferrer">balay@mcs.anl.gov</a>> wrote:<br>
> <br>
> > Send configure.log, make.log from both petsc-3.13 and 3.17 [or 3.19].<br>
> ><br>
> > [you can gzip them to make the logs friendly to mailing list - or send<br>
> > them to petsc-maint]<br>
> ><br>
> > And does test suite work with 3.17? [or 3.19?]<br>
> ><br>
> > Satish<br>
> ><br>
> > On Tue, 29 Aug 2023, INTURU SRINIVAS 20PHD0548 via petsc-users wrote:<br>
> ><br>
> > > I am sharing the make.log file while building petsc-3.13.4 with Matlab.<br>
> > > Please find the attachment and do the needful.<br>
> > ><br>
> > > On Tue, Aug 29, 2023 at 10:19 AM INTURU SRINIVAS 20PHD0548 <<br>
> > > <a href="mailto:inturu.srinivas2020@vitstudent.ac.in" target="_blank" rel="noreferrer">inturu.srinivas2020@vitstudent.ac.in</a>> wrote:<br>
> > ><br>
> > > > I tried with petsc-3.17.5. During building of libmesh, the error shows<br>
> > > > petsc was not found<br>
> > > ><br>
> > > > On Mon, Aug 28, 2023 at 9:43 PM Satish Balay <<a href="mailto:balay@mcs.anl.gov" target="_blank" rel="noreferrer">balay@mcs.anl.gov</a>><br>
> > wrote:<br>
> > > ><br>
> > > >> <a href="https://ibamr.github.io/linux" rel="noreferrer noreferrer" target="_blank">https://ibamr.github.io/linux</a> says petsc-3.17<br>
> > > >><br>
> > > >> Here you are using 3.13<br>
> > > >><br>
> > > >> Can you retry with petsc-3.17.5?<br>
> > > >><br>
> > > >> Satish<br>
> > > >><br>
> > > >> On Mon, 28 Aug 2023, INTURU SRINIVAS 20PHD0548 via petsc-users wrote:<br>
> > > >><br>
> > > >> > Hello,<br>
> > > >> ><br>
> > > >> > I want to build PETSc with MATLAB for working on the simulation<br>
> > using<br>
> > > >> IBAMR<br>
> > > >> > open software. While building the PETSc, using the following<br>
> > > >> ><br>
> > > >> > export PETSC_DIR=$PWD<br>
> > > >> > export PETSC_ARCH=linux-debug<br>
> > > >> > ./configure \<br>
> > > >> > --CC=$HOME/sfw/linux/openmpi/4.1.4/bin/mpicc \<br>
> > > >> > --CXX=$HOME/sfw/linux/openmpi/4.1.4/bin/mpicxx \<br>
> > > >> > --FC=$HOME/sfw/linux/openmpi/4.1.4/bin/mpif90 \<br>
> > > >> > --with-debugging=1 \<br>
> > > >> > --download-hypre=1 \<br>
> > > >> > --download-fblaslapack=1 \<br>
> > > >> > --with-x=0 \<br>
> > > >> > --with-matlab-dir=/usr/local/MATLAB/R2020b/<br>
> > > >> > --with-matlab-engine=1<br>
> > > >> > --with-matlab-engine-dir=/usr/local/MATLAB/R2020b/extern/engines/<br>
> > > >> ><br>
> > > >> > make -j4<br>
> > > >> > make -j4 test<br>
> > > >> ><br>
> > > >> > I got the following error<br>
> > > >> > CLINKER<br>
> > > >> linux-debug/tests/tao/leastsquares/tutorials/matlab/matlab_ls_test<br>
> > > >> > /usr/bin/ld:<br>
> > > >> ><br>
> > linux-debug/tests/tao/leastsquares/tutorials/matlab/matlab_ls_test.o: in<br>
> > > >> > function `EvaluateResidual':<br>
> > > >> ><br>
> > > >><br>
> > /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c:32:<br>
> > > >> > undefined reference to `PetscMatlabEnginePut'<br>
> > > >> > /usr/bin/ld:<br>
> > > >> ><br>
> > > >><br>
> > /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c:33:<br>
> > > >> > undefined reference to `PetscMatlabEngineEvaluate'<br>
> > > >> > /usr/bin/ld:<br>
> > > >> ><br>
> > > >><br>
> > /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c:35:<br>
> > > >> > undefined reference to `PetscMatlabEngineGet'<br>
> > > >> > /usr/bin/ld:<br>
> > > >> ><br>
> > linux-debug/tests/tao/leastsquares/tutorials/matlab/matlab_ls_test.o: in<br>
> > > >> > function `EvaluateJacobian':<br>
> > > >> ><br>
> > > >><br>
> > /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c:46:<br>
> > > >> > undefined reference to `PetscMatlabEnginePut'<br>
> > > >> > /usr/bin/ld:<br>
> > > >> ><br>
> > > >><br>
> > /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c:47:<br>
> > > >> > undefined reference to `PetscMatlabEngineEvaluate'<br>
> > > >> > /usr/bin/ld:<br>
> > > >> ><br>
> > > >><br>
> > /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c:49:<br>
> > > >> > undefined reference to `PetscMatlabEngineGet'<br>
> > > >> > /usr/bin/ld:<br>
> > > >> ><br>
> > linux-debug/tests/tao/leastsquares/tutorials/matlab/matlab_ls_test.o: in<br>
> > > >> > function `TaoPounders':<br>
> > > >> ><br>
> > > >><br>
> > /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c:75:<br>
> > > >> > undefined reference to `PetscMatlabEngineGet'<br>
> > > >> > /usr/bin/ld:<br>
> > > >> ><br>
> > linux-debug/tests/tao/leastsquares/tutorials/matlab/matlab_ls_test.o: in<br>
> > > >> > function `main':<br>
> > > >> ><br>
> > > >><br>
> > /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c:126:<br>
> > > >> > undefined reference to `PetscMatlabEngineCreate'<br>
> > > >> > /usr/bin/ld:<br>
> > > >> ><br>
> > > >><br>
> > /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c:127:<br>
> > > >> > undefined reference to `PetscMatlabEngineEvaluate'<br>
> > > >> > /usr/bin/ld:<br>
> > > >> ><br>
> > > >><br>
> > /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c:139:<br>
> > > >> > undefined reference to `PetscMatlabEngineEvaluate'<br>
> > > >> > /usr/bin/ld:<br>
> > > >> ><br>
> > > >><br>
> > /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c:140:<br>
> > > >> > undefined reference to `PetscMatlabEngineGetArray'<br>
> > > >> > /usr/bin/ld:<br>
> > > >> ><br>
> > > >><br>
> > /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c:142:<br>
> > > >> > undefined reference to `PetscMatlabEngineGetArray'<br>
> > > >> > /usr/bin/ld:<br>
> > > >> ><br>
> > > >><br>
> > /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c:144:<br>
> > > >> > undefined reference to `PetscMatlabEngineGetArray'<br>
> > > >> > /usr/bin/ld:<br>
> > > >> ><br>
> > > >><br>
> > /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c:146:<br>
> > > >> > undefined reference to `PetscMatlabEngineGetArray'<br>
> > > >> > /usr/bin/ld:<br>
> > > >> ><br>
> > > >><br>
> > /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c:148:<br>
> > > >> > undefined reference to `PetscMatlabEngineGetArray'<br>
> > > >> > /usr/bin/ld:<br>
> > > >> ><br>
> > > >><br>
> > /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c:154:<br>
> > > >> > undefined reference to `PetscMatlabEngineEvaluate'<br>
> > > >> > /usr/bin/ld:<br>
> > > >> ><br>
> > > >><br>
> > /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c:157:<br>
> > > >> > undefined reference to `PetscMatlabEngineEvaluate'<br>
> > > >> > /usr/bin/ld:<br>
> > > >> ><br>
> > > >><br>
> > /home/vit/sfw/petsc/3.13.4/src/tao/leastsquares/tutorials/matlab/matlab_ls_test.c:158:<br>
> > > >> > undefined reference to `PetscMatlabEngineDestroy'<br>
> > > >> ><br>
> > > >> > collect2: error: ld returned 1 exit status<br>
> > > >> > make: *** [gmakefile.test:185:<br>
> > > >> > linux-debug/tests/tao/leastsquares/tutorials/matlab/matlab_ls_test]<br>
> > > >> Error 1<br>
> > > >> > make: *** Waiting for unfinished jobs....<br>
> > > >> ><br>
> > > >> > Please help me to solve this issue<br>
> > > >> ><br>
> > > >> > Thank you<br>
> > > >> > Srinivas<br>
> > > >> ><br>
> > > >> ><br>
> > > >><br>
> > > >><br>
> > ><br>
> > ><br>
> ><br>
> <br>
> <br>
</blockquote></div>
<br>
<i><span><b>Disclaimer:</b><br>This message was sent from Vellore Institute of Technology. The contents of this email may contain legally protected confidential or privileged information of “Vellore Institute of Technology”. If you are not the intended recipient, you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately and destroy all copies of this message and any attachments. If you have received this email in error, please promptly notify the sender by reply email and delete the original email and any backup copies without reading them.</span></i><br></blockquote></div></div>
</blockquote></div>
<br>
<i><span><b>Disclaimer:</b><br>This message was sent from Vellore Institute of Technology. The contents of this email may contain legally protected confidential or privileged information of “Vellore Institute of Technology”. If you are not the intended recipient, you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately and destroy all copies of this message and any attachments. If you have received this email in error, please promptly notify the sender by reply email and delete the original email and any backup copies without reading them.</span></i><br>