Thanks Barry. That fixed the problem, i.e. adding --download-hdf5<div><br></div><div>-M<br><br><div class="gmail_quote">On Tue, Sep 6, 2011 at 6:16 PM, Barry Smith <span dir="ltr">&lt;<a href="mailto:bsmith@mcs.anl.gov">bsmith@mcs.anl.gov</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><br>
  Did you ./configure PETSc with the option --download-hdf5 or the option --with-hdf5-dir=directoryname ?<br>
<br>
   PETSc must be configured with hdf5 in a similar way to that it needs to be configured with hypre to use hypre<br>
<font color="#888888"><br>
   Barry<br>
</font><div><div></div><div class="h5"><br>
On Sep 6, 2011, at 7:13 PM, Mohamad M. Nasr-Azadani wrote:<br>
<br>
&gt; Hi guys,<br>
&gt;<br>
&gt; I was trying to run the example on HDF5,<br>
&gt; <a href="http://www.mcs.anl.gov/petsc/petsc-as/snapshots/petsc-3.1/src/dm/da/examples/tutorials/ex10.c.html" target="_blank">http://www.mcs.anl.gov/petsc/petsc-as/snapshots/petsc-3.1/src/dm/da/examples/tutorials/ex10.c.html</a><br>

&gt;<br>
&gt; But I could not.<br>
&gt; This is what I get:<br>
&gt; ***************<br>
&gt; &gt;&gt;make PETSC_DIR=/home/mmnasr/Softwares/petsc-3.1-p7 PETSC_ARCH=linux-gnu-c-opt ex10<br>
&gt;<br>
&gt; /home/mmnasr/Softwares/petsc-3.1-p7/linux-gnu-c-opt/bin/mpicc -o ex10.o -c -Wall -Wwrite-strings -Wno-strict-aliasing -O -I/home/mmnasr/Softwares/petsc-3.1-p7/linux-gnu-c-opt/include -I/home/mmnasr/Softwares/petsc-3.1-p7/include -I/home/mmnasr/Softwares/petsc-3.1-p7/linux-gnu-c-opt/include -D__INSDIR__=src/dm/da/examples/tutorials/ ex10.c<br>

&gt; /home/mmnasr/Softwares/petsc-3.1-p7/linux-gnu-c-opt/bin/mpicc -Wall -Wwrite-strings -Wno-strict-aliasing -O  -o ex10 ex10.o  -Wl,-rpath,/home/mmnasr/Softwares/petsc-3.1-p7/linux-gnu-c-opt/lib -L/home/mmnasr/Softwares/petsc-3.1-p7/linux-gnu-c-opt/lib -lpetsc    -Wl,-rpath,/home/mmnasr/Softwares/petsc-3.1-p7/linux-gnu-c-opt/lib -L/home/mmnasr/Softwares/petsc-3.1-p7/linux-gnu-c-opt/lib -lml -lmpichcxx -lstdc++ -lHYPRE -lmpichcxx -lstdc++ -lflapack -lfblas -lnsl -lrt -L/home/mmnasr/Softwares/petsc-3.1-p7/linux-gnu-c-opt/lib -L/usr/lib/gcc/x86_64-linux-gnu/4.4.5 -L/usr/lib/x86_64-linux-gnu -ldl -lmpich -lpthread -lrt -lgcc_s -lmpichf90 -lgfortran -lm -lm -lmpichcxx -lstdc++ -lmpichcxx -lstdc++ -ldl -lmpich -lpthread -lrt -lgcc_s -ldl<br>

&gt; ex10.o: In function `main&#39;:<br>
&gt; ex10.c:(.text+0x3b7): undefined reference to `PetscViewerHDF5Open&#39;<br>
&gt; collect2: ld returned 1 exit status<br>
&gt; make: [ex10] Error 1 (ignored)<br>
&gt; /bin/rm -f -f ex10.o<br>
&gt;<br>
&gt; ************<br>
&gt; It seems that it does not find the compiled library and/or header files for it. Any ideas?<br>
&gt;<br>
&gt; Thanks,<br>
&gt; Mohamad<br>
&gt;<br>
<br>
</div></div></blockquote></div><br></div>