QMCPACK / qmcpack

Main repository for QMCPACK, an open-source production level many-body ab initio Quantum Monte Carlo code for computing the electronic structure of atoms, molecules, and solids with full performance portable GPU support
http://www.qmcpack.org
Other
300 stars 139 forks source link

Drop FindBoost module which is deprecated in CMake 3.30 and raise minimum version to 1.70. #5227

Closed ye-luo closed 4 days ago

ye-luo commented 1 week ago

Proposed changes

Boost 1.70 was release in 2019.

Instead of the CMake shipped module file, upstream Boost's BoostConfig.cmake package configuration file will be used. This change requires installing boost properly but we only need the "headers" library. Untaring a boost archive won't work.

Installation of boost headers is very simple and quick

./bootstrap.sh --prefix=<location of your installation> --with-libraries=headers
./b2 install

QMCPACK CMake takes -DBOOST_ROOT=<location of your installation> as usual.

What type(s) of changes does this code introduce?

Does this introduce a breaking change?

What systems has this change been tested on?

laptop

Checklist

ye-luo commented 1 week ago

Test this please

PDoakORNL commented 1 week ago

I don't think I've touched a boost tarball for a decade. Either it is a distro package or I use spack. And at least for spack I had to pull a newer version of spack and reinstall boost. My old install did not include the cmake config files for any version of spack. I can see the recipe for boost has been updated. So I think that's probably a possible issue here.

Once I've done that it works fine. I don't think spack was ever correct to leave these files out.

PDoakORNL commented 1 week ago

I'd add I'm using cmake@3.29.2 was using boost@1.86.0 installed months ago and reinstalled after a pull of spack develop today. So this works with older cmake's but maybe not if you have a old spack install of boost even if its far newer that 1.70

On osx homebrew looks to be installing boost properly.

prckent commented 6 days ago

(Not changing my view here - needs updating to use the new find_package mechanisms for cmake >=3.30.0 otherwise use the old scheme. This is the least disruptive approach.)

ye-luo commented 6 days ago

@PDoakORNL boost issue fixed by https://github.com/spack/spack/pull/46281 and https://github.com/spack/spack/pull/46062 Aug/Sep 2024. So only recently.

ye-luo commented 6 days ago

For CMake version < 3.30, keep using the boost module.

ye-luo commented 6 days ago

Test this please

ye-luo commented 4 days ago

Test this please

prckent commented 4 days ago

Thanks Ye!

prckent commented 4 days ago

Test this please