Hi Ryo,

Thanks for the reply.

1) Initially those two fields were blank in the CMakeCache.txt but I put in those paths by hand because without that, the 'make' error had earlier come up as 'Fatal error: hdf5.h: No such file or directory', which was located in /usr/include. After applying your changes the same error comes up as below:

<SNIP>
[ 81%] Built target detailedbinning
Scanning dependencies of target dumpbench
[ 81%] Building CXX object test/alea/CMakeFiles/dumpbench.dir/dumpbench.C.o
In file included from /afs/ictp.it/home/v/vvarma/Desktop/alps-2.2.b1-r7195-src-with-boost/boost/boost/python/detail/wrap_python.hpp:50:0,
                 from /afs/ictp.it/home/v/vvarma/Desktop/alps-2.2.b1-r7195-src-with-boost/boost/boost/python/detail/prefix.hpp:13,
                 from /afs/ictp.it/home/v/vvarma/Desktop/alps-2.2.b1-r7195-src-with-boost/boost/boost/python/args.hpp:8,
                 from /afs/ictp.it/home/v/vvarma/Desktop/alps-2.2.b1-r7195-src-with-boost/boost/boost/python.hpp:11,
                 from /afs/ictp.it/home/v/vvarma/Desktop/alps-2.2.b1-r7195-src-with-boost/alps/src/alps/alea/mcdata.hpp:79,
                 from /afs/ictp.it/home/v/vvarma/Desktop/alps-2.2.b1-r7195-src-with-boost/alps/src/alps/alea.h:34,
                 from /afs/ictp.it/home/v/vvarma/Desktop/alps-2.2.b1-r7195-src-with-boost/alps/test/alea/dumpbench.C:28:
/usr/include/python2.7/pyconfig.h:1161:0: warning: "_POSIX_C_SOURCE" redefined [enabled by default]
/usr/include/features.h:164:0: note: this is the location of the previous definition
/usr/include/python2.7/pyconfig.h:1183:0: warning: "_XOPEN_SOURCE" redefined [enabled by default]
/usr/include/features.h:166:0: note: this is the location of the previous definition
/afs/ictp.it/home/v/vvarma/Desktop/alps-2.2.b1-r7195-src-with-boost/alps/test/alea/dumpbench.C:39:18: fatal error: hdf5.h: No such file or directory
compilation terminated.
make[2]: *** [test/alea/CMakeFiles/dumpbench.dir/dumpbench.C.o] Error 1
make[1]: *** [test/alea/CMakeFiles/dumpbench.dir/all] Error 2
make: *** [all] Error 2

<SNIP>

2) The comparison between the FindHDF5.cmake files is as below:
The working ALPS on Ubuntu is version 2.1 whereas on Linux Mint I am trying to install ALPS 2.2. So I presume the differences between the FindHDF5.cmake files (present in the alps/config/ directory) are because of the version change; the differences are as below

COMMAND LINE>    diff LinuxMint_ALPS2.2_FindHDF5.cmake Ubuntu_ALPS2.1_FindHDF5.cmake

<SNIP: Linux Mint>
    IF(Hdf5_INCLUDE_DIRS)
      FIND_PATH(HDF5_INCLUDE_DIR NAMES hdf5.h PATHS ${Hdf5_INCLUDE_DIRS} NO_DEFAULT_PATH)
      FIND_LIBRARY(HDF5_LIBRARIES hdf5 ${Hdf5_LIBRARY_DIRS} NO_DEFAULT_PATH)
<SNIP: Linux Mint>

<SNIP: Ubuntu>
   IF(Hdf5_INCLUDE_DIRS)
      FIND_PATH(HDF5_INCLUDE_DIR NAMES hdf5.h PATHS ${Hdf5_INCLUDE_DIRS})
      FIND_LIBRARY(HDF5_LIBRARIES hdf5 ${Hdf5_LIBRARY_DIRS})
<SNIP: Ubuntu>

Then in 3 instances of the #ALPS ADDITION sections in the Linux Mint ALPS 2.2 version of the FindHDF5.cmake file, the following settings are present, but are not present in the Ubuntu ALPS 2.1 file:
<               ENV
<                     HDF5_DIR
<                     PHDF5_HOME
<                     HDF5_HOME
<                     HDF_HOME
348,352d342
<                 ENV
<                     HDF5_DIR
<                     PHDF5_HOME
<                     HDF5_HOME
<                     HDF_HOME
378,382d367
<                 ENV
<                     HDF5_DIR
<                     PHDF5_HOME
<                     HDF5_HOME
<                     HDF_HOME

But the global /usr/share/cmake-2.8/Modules/FindHDF5.cmake files in the Linux Mint and Ubuntu are the same.

Suggestions and inputs are greatly appreciated.

Best,
Vipin

On 03/07/2014 12:33 PM, Ryo IGARASHI wrote:
Hi, Vipin,

On Fri, Mar 7, 2014 at 7:49 PM,  <vvarma@ictp.it> wrote:
After cmake and ccmake, I am trying to 'make' the ALPS 2.2b1 files on my
computer (running on Linux Mint 13 Maya, which is in turn based on Ubuntu
12.04); however I get the following error message:
...snipped...
make[2]: *** No rule to make target `/usr/lib/libhdf5.so', needed by
`applications/mc/spins/spinmc'.  Stop.
make[1]: *** [applications/mc/spins/CMakeFiles/spinmc.dir/all] Error 2
make: *** [all] Error 2
This is strange. HDF5 detection code of the ALPS seems broken.

I have tried reinstalling hdf5 (libhdf5-serial-dev) and the ALPS multiple
times on this computer but there is always some error related to the hdf5
files, either during the make process or the cmake configuration. If you
could please help me debug this particular error, that would be greatly
appreciated. A few technical notes are appended at the end.
The problem I believe comes from the CMake. What is the CMake version
of Linux Mint?
If your CMake comes from the Linux Mint, what is the difference between the file
/usr/share/cmake-2.8/Modules/FindHDF5.cmake of Linux Mint and Ubuntu?

3) Snippet of CMakeCache.txt
...snipped...
//The HDF5_hdf5 library
HDF5_hdf5_LIBRARY:FILEPATH=/usr/include
...snipped...
//The HDF5_hdf5_hl library
HDF5_hdf5_hl_LIBRARY:FILEPATH=/usr/include
Something wrong with the above 2 lines.
When everything goes well, the snippet of CMakeCache.txt will be like following:

//The HDF5_hdf5 library
HDF5_hdf5_LIBRARY:FILEPATH=optimized;/opt/nano/alps/lib/libhdf5.so;debug;/opt/nano/alps/lib/libhdf5.so

...snipped...

//The HDF5_hdf5_hl library
HDF5_hdf5_hl_LIBRARY:FILEPATH=optimized;/opt/nano/alps/lib/libhdf5_hl.so;debug;/opt/nano/alps/lib/libhdf5_hl.so

If you change the 2 lines of CMakeCache.txt, then things might change.

Best regards,