<div dir="ltr"><div><div>Hi Michael,<br><br>Quite a few commits back, setup.py was configured by CMake to fill in the CheMPS2 version etc. from the CMake option list. Toon Verstraelen however changed it to make the python build independent from cmake as he found it unsatisfactory: <a href="https://github.com/SebWouters/CheMPS2/commit/af1870983ce1127664079c9b5f0d0f068bcce665">https://github.com/SebWouters/CheMPS2/commit/af1870983ce1127664079c9b5f0d0f068bcce665</a> .<br><br>As pkg-config is not by default installed on all systems (I don't know about mac either), I'm a bit reluctant to change it upstream.<br><br>There is however a proper way to handle both problems:<br><br>(1) HDF5_INCLUDE_DIRS for cmake can be externally specified. For example psi4 does this in <a href="https://github.com/psi4/psi4public/blob/master/cmake/ConfigChemps2.cmake">https://github.com/psi4/psi4public/blob/master/cmake/ConfigChemps2.cmake</a> .<br><br>If I give the option -DHDF5_INCLUDE_DIRS=/path/to/nowhere to cmake, and print the HDF5_INCLUDE_DIRS variable after every package is set,<br><br>    message( STATUS "HDF5_INCLUDE_DIRS = ${HDF5_INCLUDE_DIRS}" )<br><br>prints:<br><br>    HDF5_INCLUDE_DIRS = /path/to/nowhere;/usr/include<br><br>So how about we pass<br><br>    -DHDF5_INCLUDE_DIRS=/usr/include/hdf5/serial/<br><br>in the SID rules file and deprecate the hard-coded path /usr/include/hdf5/serial/ in CMakeLists.txt?<br><br>(2) Likewise include paths for python can by specified by the CPATH variable.<br><br>So how about we use<br><br>    CPATH=../CheMPS2/include:/usr/include/hdf5/serial/<br><br>instead of the current CPATH=../CheMPS2/include in debian/rules and deprecate the hard-coded path /usr/include/hdf5/serial/ in setup.py?<br><br></div><div>I will update the installation instructions in the README.md and sphinx webpage accordingly in due time for people who wish to compile and install CheMPS2 themselves and who have non-default installation directories.<br><br></div><div>Let me know if you find this option satisfactory, and then I will adjust upstream & the git repo on alioth.<br></div><div><br></div>Best wishes,<br></div>Sebastian<br><br><div><div><div><br></div></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">2015-06-18 6:34 GMT-04:00 Michael Banck <span dir="ltr"><<a href="mailto:mbanck@debian.org" target="_blank">mbanck@debian.org</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<span class=""><br>
On Thu, Jun 18, 2015 at 12:20:36PM +0200, Michael Banck wrote:<br>
> The attached patch uses pkg-config (an additional dependency, but quite<br>
> lightweight and likely already installed on a development machine) to<br>
> find HDF5, it looks a bit cleaner to me.<br>
<br>
</span>Well, it wasn't against latest git obviously. Alternatively, you can<br>
just pick the os.environ.get change and set HDF5_INCLUDE_DIRS in<br>
debian/rules accordingly.<br>
<br>
An even more comprehensive change would be to set HDF5_INCLUDE_DIRS via<br>
cmake, by using configure_file or similar.  Then the person building<br>
PyCheMPS2 would not need to set an environment variable at all.<br>
<span class="HOEnZb"><font color="#888888"><br>
<br>
Michael<br>
</font></span></blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><span style="font-family:courier new,monospace"></span><font style="font-family:courier new,monospace" face="courier new,monospace">****************************************************</font><br style="font-family:courier new,monospace"><br style="font-family:courier new,monospace"><span style="font-family:courier new,monospace">  dr. ir. Sebastian Wouters</span><br style="font-family:courier new,monospace"><span style="font-family:courier new,monospace">  Fellow of the Belgian American Educational Foundation</span><br style="font-family:courier new,monospace"></div><font style="font-family:courier new,monospace" face="courier new,monospace">  Princeton University<br></font><div><font style="font-family:courier new,monospace" face="courier new,monospace">  (address) </font><span style="font-family:courier new,monospace">Department of Chemistry</span><br style="font-family:courier new,monospace"><span style="font-family:courier new,monospace">            Frick Laboratory 351<br>            Princeton, NJ 08544, USA<br>
  (e-mail)  <a href="mailto:sebastianwouters@gmail.com" target="_blank">sebastianwouters@gmail.com</a><br><br></span><font style="font-family:courier new,monospace" face="courier new,monospace">****************************************************</font><br style="font-family:courier new,monospace"><span style="font-family:courier new,monospace"></span></div></div></div></div></div>
</div>