From b9c24ad11309efa8ecaa619e36a4f37af1f87286 Mon Sep 17 00:00:00 2001 From: Tobias Wolf Date: Thu, 23 Jul 2026 00:25:19 -0500 Subject: [PATCH 1/7] chore: consolidate build config into cmake/ and prune legacy root Relocate the CMake modules and build helpers from config/ to cmake/ (git-tracked renames, contents unchanged) and drop dead legacy: - remove Debian sid packaging (SVN/wheezy-era, unreferenced; superseded by the wheel + CPack packaging paths) - remove SVN-era license-header tooling (preamble*.in, update_preamble*) - remove stale root files (README.txt, README-package.txt, Welcome.txt, CTestConfig.cmake) - add CITATION.md and CMakePresets.json The config/ directory is now gone; cmake/ is the single home for build configuration. No functional/build behavior change. Co-Authored-By: Claude Opus 4.8 (1M context) --- .gitignore | 25 +++- CITATION.md | 29 ++++ CMakeLists.txt | 18 +-- CMakePresets.json | 33 +++++ CONTRIBUTING.md | 15 +- CTestConfig.cmake | 14 -- README-package.txt | 127 ---------------- README.md | 52 ++++++- README.txt | 1 - Welcome.txt | 4 - {config => cmake}/ALPSBuildname.cmake | 0 {config => cmake}/ALPSConfig.cmake.in | 0 {config => cmake}/ALPSCore.cmake | 0 {config => cmake}/ALPSTesting.cmake | 0 {config => cmake}/BoostUtils.cmake | 0 {config => cmake}/CMakeLists.txt | 0 {config => cmake}/Compilers.cmake | 0 {config => cmake}/Distribution.xml.in | 0 {config => cmake}/FindBoostForALPS.cmake | 0 {config => cmake}/FindBoostSrc.cmake | 0 {config => cmake}/FindDocbookDtd.cmake | 0 {config => cmake}/FindDocbookXsl.cmake | 0 {config => cmake}/FindFop.cmake | 0 {config => cmake}/FindLPSolve.cmake | 0 {config => cmake}/FindLapack.cmake | 0 {config => cmake}/FindMPIForALPS.cmake | 0 {config => cmake}/FindPythonMod.cmake | 0 {config => cmake}/FindSQLite.cmake | 0 {config => cmake}/FindSZIP.cmake | 0 {config => cmake}/FindSphinx.cmake | 0 {config => cmake}/FindXsltproc.cmake | 0 {config => cmake}/UseALPS.cmake | 0 {config => cmake}/add_alps_test.cmake | 16 +-- {config => cmake}/alps_logo.png | Bin {config => cmake}/include.mk.in | 0 {config => cmake}/make_package.sh.in | 0 {config => cmake}/passthru.py | 0 {config => cmake}/py-compile | 0 {config => cmake}/run_test.cmake | 0 {config => cmake}/run_test_mpi.cmake | 0 config/debian/sid/.bzr-builddeb/default.conf | 3 - config/debian/sid/.bzrignore | 1 - config/debian/sid/README.source | 6 - config/debian/sid/alps-applications.install | 17 --- config/debian/sid/alps-tutorials.install | 1 - config/debian/sid/changelog | 61 -------- config/debian/sid/compat | 1 - config/debian/sid/control | 121 ---------------- config/debian/sid/copyright | 29 ---- config/debian/sid/libalps-bin.install | 36 ----- config/debian/sid/libalps-dev.install | 5 - config/debian/sid/libalps-dev.links | 1 - config/debian/sid/libalps.install | 2 - .../sid/libboost-numeric-bindings-dev.install | 1 - config/debian/sid/python-pyalps.install | 3 - config/debian/sid/rules | 23 --- config/debian/sid/source/format | 1 - config/preamble-light.in | 39 ----- config/preamble.in | 28 ---- config/preamble_py.in | 28 ---- config/update_preamble | 136 ------------------ config/update_preamble_py | 136 ------------------ 62 files changed, 155 insertions(+), 858 deletions(-) create mode 100644 CITATION.md create mode 100644 CMakePresets.json delete mode 100644 CTestConfig.cmake delete mode 100644 README-package.txt delete mode 100644 README.txt delete mode 100644 Welcome.txt rename {config => cmake}/ALPSBuildname.cmake (100%) rename {config => cmake}/ALPSConfig.cmake.in (100%) rename {config => cmake}/ALPSCore.cmake (100%) rename {config => cmake}/ALPSTesting.cmake (100%) rename {config => cmake}/BoostUtils.cmake (100%) rename {config => cmake}/CMakeLists.txt (100%) rename {config => cmake}/Compilers.cmake (100%) rename {config => cmake}/Distribution.xml.in (100%) rename {config => cmake}/FindBoostForALPS.cmake (100%) rename {config => cmake}/FindBoostSrc.cmake (100%) rename {config => cmake}/FindDocbookDtd.cmake (100%) rename {config => cmake}/FindDocbookXsl.cmake (100%) rename {config => cmake}/FindFop.cmake (100%) rename {config => cmake}/FindLPSolve.cmake (100%) rename {config => cmake}/FindLapack.cmake (100%) rename {config => cmake}/FindMPIForALPS.cmake (100%) rename {config => cmake}/FindPythonMod.cmake (100%) rename {config => cmake}/FindSQLite.cmake (100%) rename {config => cmake}/FindSZIP.cmake (100%) rename {config => cmake}/FindSphinx.cmake (100%) rename {config => cmake}/FindXsltproc.cmake (100%) rename {config => cmake}/UseALPS.cmake (100%) rename {config => cmake}/add_alps_test.cmake (91%) rename {config => cmake}/alps_logo.png (100%) rename {config => cmake}/include.mk.in (100%) rename {config => cmake}/make_package.sh.in (100%) rename {config => cmake}/passthru.py (100%) rename {config => cmake}/py-compile (100%) rename {config => cmake}/run_test.cmake (100%) rename {config => cmake}/run_test_mpi.cmake (100%) delete mode 100644 config/debian/sid/.bzr-builddeb/default.conf delete mode 100644 config/debian/sid/.bzrignore delete mode 100644 config/debian/sid/README.source delete mode 100644 config/debian/sid/alps-applications.install delete mode 100644 config/debian/sid/alps-tutorials.install delete mode 100644 config/debian/sid/changelog delete mode 100644 config/debian/sid/compat delete mode 100644 config/debian/sid/control delete mode 100644 config/debian/sid/copyright delete mode 100644 config/debian/sid/libalps-bin.install delete mode 100644 config/debian/sid/libalps-dev.install delete mode 100644 config/debian/sid/libalps-dev.links delete mode 100644 config/debian/sid/libalps.install delete mode 100644 config/debian/sid/libboost-numeric-bindings-dev.install delete mode 100644 config/debian/sid/python-pyalps.install delete mode 100755 config/debian/sid/rules delete mode 100644 config/debian/sid/source/format delete mode 100644 config/preamble-light.in delete mode 100644 config/preamble.in delete mode 100644 config/preamble_py.in delete mode 100755 config/update_preamble delete mode 100755 config/update_preamble_py diff --git a/.gitignore b/.gitignore index 34c84c5a4..97e8c171d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,8 +1,21 @@ -# Build directories -*build*/ - -# IDE directories -.idea/* +# Build and generated directories +/build/ +/_build/ +CMakeFiles/ +CMakeCache.txt +cmake_install.cmake +compile_commands.json + +# Editors and operating systems +.idea/ +.vscode/ +.DS_Store + +# Python tooling +.pytest_cache/ +.ruff_cache/ +__pycache__/ +*.py[cod] # Prerequisites *.d @@ -36,5 +49,3 @@ *.exe *.out *.app - -__pycache__ diff --git a/CITATION.md b/CITATION.md new file mode 100644 index 000000000..5d81cfa04 --- /dev/null +++ b/CITATION.md @@ -0,0 +1,29 @@ +# Citing ALPS + +If ALPS contributes to published research, please cite the framework papers below and any method-specific paper relevant to the application you used. Citation is requested as scholarly acknowledgement; it is not a condition of the MIT license in [`LICENSE.txt`](LICENSE.txt). + +## Framework papers + +Please cite both ALPS framework papers: + +1. A. F. Albuquerque *et al.*, “The ALPS project release 1.3: Open-source software for strongly correlated systems,” *Journal of Magnetism and Magnetic Materials* **310**, 1187–1193 (2007). [doi:10.1016/j.jmmm.2006.10.304](https://doi.org/10.1016/j.jmmm.2006.10.304) +2. B. Bauer *et al.*, “The ALPS project release 2.0: Open source software for strongly correlated systems,” *Journal of Statistical Mechanics: Theory and Experiment* **2011**, P05001 (2011). [doi:10.1088/1742-5468/2011/05/P05001](https://doi.org/10.1088/1742-5468/2011/05/P05001) + +## Method-specific papers + +Add the applicable paper from this table. Application names match directories or executables in this repository. + +| Application or component | Additional citation | +| --- | --- | +| `applications/qmc/looper` (`loop`, `loop_mpi`) | S. Todo and K. Kato, “Cluster Algorithms for General-S Quantum Spin Systems,” *Physical Review Letters* **87**, 047203 (2001). [doi:10.1103/PhysRevLett.87.047203](https://doi.org/10.1103/PhysRevLett.87.047203) | +| `applications/qmc/qwl` | M. Troyer, S. Wessel, and F. Alet, “Flat Histogram Methods for Quantum Systems,” *Physical Review Letters* **90**, 120201 (2003). [doi:10.1103/PhysRevLett.90.120201](https://doi.org/10.1103/PhysRevLett.90.120201) | +| Continuous-time QMC impurity solvers and the DMFT framework | E. Gull, P. Werner, S. Fuchs, B. Surer, T. Pruschke, and M. Troyer, “Continuous-time quantum Monte Carlo impurity solvers,” *Computer Physics Communications* **182**, 1078–1082 (2011). [doi:10.1016/j.cpc.2010.12.050](https://doi.org/10.1016/j.cpc.2010.12.050) | +| DMRG/MPS applications | M. Dolfi *et al.*, “Matrix product state applications for the ALPS project,” *Computer Physics Communications* **185**, 3430–3440 (2014). [doi:10.1016/j.cpc.2014.08.019](https://doi.org/10.1016/j.cpc.2014.08.019) | + +The framework papers are sufficient for `sse`, `spinmc`, `fulldiag`, `sparsediag`, and `worm` unless a publication describes a more specific algorithmic reference. For specialized models or algorithms, also cite the primary scientific source on which the calculation is based. + +## Citation metadata + +Use the DOI links above to obtain current BibTeX, RIS, or other citation metadata from the publishers. This avoids maintaining duplicate hand-written records that can drift from the authoritative metadata. + +When describing reproducibility, also record the ALPS release or Git commit used in the calculation. diff --git a/CMakeLists.txt b/CMakeLists.txt index 4a7995efd..8b202cf49 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -122,7 +122,7 @@ message(STATUS "Build type: " ${CMAKE_BUILD_TYPE}) ###################################################################### # CMAKE_MODULE_PATH ###################################################################### -list(APPEND CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/config) +list(APPEND CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake) ###################################################################### # set default CMAKE_INSTALL_PREFIX @@ -436,8 +436,8 @@ if(PYTHON_LIBRARY) list(APPEND ALPS_EXTRA_LIBRARIES ${PYTHON_LIBRARY}) endif(PYTHON_LIBRARY) -configure_file(config/ALPSConfig.cmake.in ${PROJECT_BINARY_DIR}/config/ALPSConfig.cmake @ONLY) -configure_file(config/include.mk.in ${PROJECT_BINARY_DIR}/config/include.mk) +configure_file(cmake/ALPSConfig.cmake.in ${PROJECT_BINARY_DIR}/config/ALPSConfig.cmake @ONLY) +configure_file(cmake/include.mk.in ${PROJECT_BINARY_DIR}/config/include.mk) # installation @@ -474,17 +474,17 @@ endif() install(DIRECTORY ${PROJECT_BINARY_DIR}/lib/xml DESTINATION ${ALPS_XML_PATH} COMPONENT xml) -add_subdirectory(config) +add_subdirectory(cmake) -install(FILES config/UseALPS.cmake +install(FILES cmake/UseALPS.cmake ${PROJECT_BINARY_DIR}/config/ALPSConfig.cmake ${PROJECT_BINARY_DIR}/config/include.mk - config/run_test.cmake - config/run_test_mpi.cmake - config/add_alps_test.cmake + cmake/run_test.cmake + cmake/run_test_mpi.cmake + cmake/add_alps_test.cmake DESTINATION share/alps COMPONENT build) -install(FILES LICENSE.txt README.md +install(FILES CITATION.md LICENSE.txt README.md DESTINATION share/alps COMPONENT libraries) if(ALPS_BUILD_PYTHON AND ALPS_PYTHON_LIB_DEST_ROOT) string(CONFIGURE [[ diff --git a/CMakePresets.json b/CMakePresets.json new file mode 100644 index 000000000..693c0c554 --- /dev/null +++ b/CMakePresets.json @@ -0,0 +1,33 @@ +{ + "version": 3, + "cmakeMinimumRequired": { + "major": 3, + "minor": 21, + "patch": 0 + }, + "configurePresets": [ + { + "name": "default", + "displayName": "Default release build", + "binaryDir": "${sourceDir}/_build/default", + "cacheVariables": { + "CMAKE_BUILD_TYPE": "Release" + } + } + ], + "buildPresets": [ + { + "name": "default", + "configurePreset": "default" + } + ], + "testPresets": [ + { + "name": "default", + "configurePreset": "default", + "output": { + "outputOnFailure": true + } + } + ] +} diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index a6565acac..c64d68452 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -52,9 +52,9 @@ Before opening a new issue, please search existing issues to avoid duplicates. - CMake ≥ 3.18 - A C++17-capable compiler (GCC, Clang, Intel, or Fujitsu) -- Boost (bundled copy included; or provide your own with `-DALPS_USE_SYSTEM_BOOST=ON`) +- Boost (downloaded automatically during configuration; or use a system install with `-DALPS_USE_SYSTEM_BOOST=ON`) - For Fortran bindings: gfortran (or compatible Fortran compiler) -- For Python bindings: Python ≥ 3.9, plus `numpy` and `scipy` +- For Python bindings: Python ≥ 3.10, plus `numpy` and `scipy` See the [installation page](https://alps.comp-phys.org/documentation/install/) for full platform-specific instructions. @@ -79,12 +79,17 @@ cmake .. -DCMAKE_BUILD_TYPE=Release make -j$(nproc) ``` -To build with Python bindings: +Alternatively, use the bundled CMake preset (requires CMake ≥ 3.21, which is +newer than the 3.18 minimum for a plain configure): ```bash -pip install scikit-build-core numpy scipy -pip install --no-build-isolation -e . +cmake --preset default +cmake --build --preset default ``` +The Python bindings are a separate `scikit-build-core` project that builds +against an installed ALPS C++ SDK; see the +[`pyalps` build instructions](bindings/python/pyalps/README.md). + ### Run the tests From the build directory: diff --git a/CTestConfig.cmake b/CTestConfig.cmake deleted file mode 100644 index 16bb958cd..000000000 --- a/CTestConfig.cmake +++ /dev/null @@ -1,14 +0,0 @@ -## This file should be placed in the root directory of your project. -## Then modify the CMakeLists.txt file in the root directory of your -## project to incorporate the testing dashboard. -## # The following are required to uses Dart and the Cdash dashboard -## ENABLE_TESTING() -## INCLUDE(CTest) - -set(CTEST_PROJECT_NAME "ALPS") -set(CTEST_NIGHTLY_START_TIME "01:00:00 UTC") - -set(CTEST_DROP_METHOD "http") -set(CTEST_DROP_SITE "alps.comp-phys.org") -set(CTEST_DROP_LOCATION "/cdash/submit.php?project=ALPS") -set(CTEST_DROP_SITE_CDASH TRUE) diff --git a/README-package.txt b/README-package.txt deleted file mode 100644 index e52b7432c..000000000 --- a/README-package.txt +++ /dev/null @@ -1,127 +0,0 @@ -The ALPS project (Algorithms and Libraries for Physics Simulations) aims at providing generic parallel algorithms for classical and quantum lattice models and provides utility classes and algorithm for many other problems. It strives to increase software reuse in the physics community. - -The ALPS Libraries are published under the ALPS Application License; you can use, redistribute it and/or modify it under the terms of the license, either version 1 or (at your option) any later version. - -You should have received a copy of the ALPS Library License along with the ALPS Libraries; see the file LICENSE.txt. If not, the license is also available from http://alps.comp-phys.org/. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Any publication for which one of the following libraries are used has to -acknowledge the use of the ALPS libraries, and the papers listed below: - -When alps/model.h or any header in alps/model was used: -reference the web page http://alps.comp-phys.org/ and cite the publication: -A.F. Albuquerque et al., J. of Magn. and Magn. Materials 310, 1187 (2007) -B. Bauer et al., J. Stat. Mech. (2011) P05001 - -When alps/lattice.h or any header in alps/lattice was used: -reference the web page http://alps.comp-phys.org/ and cite the publication: -A.F. Albuquerque et al., J. of Magn. and Magn. Materials 310, 1187 (2007) -B. Bauer et al., J. Stat. Mech. (2011) P05001 - -When alps/alea.h or any header in alps/alea was used: -reference the web page http://alps.comp-phys.org/ and cite the publications: -A.F. Albuquerque et al., J. of Magn. and Magn. Materials 310, 1187 (2007) -B. Bauer et al., J. Stat. Mech. (2011) P05001 - -When alps/scheduler.h or any header in alps/scheduler was used: -reference the web page http://alps.comp-phys.org/ and cite the publications: -A.F. Albuquerque et al., J. of Magn. and Magn. Materials 310, 1187 (2007) -B. Bauer et al., J. Stat. Mech. (2011) P05001 -M. Troyer et al., Lecture Notes in Computer Science, Vol. 1505, p. 191 (1998). - -The use of any other library, in particular those with headers in the -subdirectories alps/parser, alps/osiris, alps/random do not carry any -citation requirement but acknowledgment of the ALPS project is encouraged. - -* When the SSE quantum Monte Carlo program sse or sse_mpi was used: - - reference the ALPS web page http://alps.comp-phys.org/ - - and cite the publications: - A.F. Albuquerque et al., J. of Magn. and Magn. Materials 310, 1187 (2007). - B. Bauer et al., J. Stat. Mech. (2011) P05001 - -* When the loop quantum Monte Carlo program loop or loop_mpi was used: - - reference the ALPS and ALPS/looper web pages - http://alps.comp-phys.org/ - http://wistaria.comp-phys.org/alps-looper/ - - and cite the publications: - S. Todo and K. Kato, Phys. Rev. Lett. 87 047203 (2001). - A.F. Albuquerque et al., J. of Magn. and Magn. Materials 310, 1187 (2007). - B. Bauer et al., J. Stat. Mech. (2011) P05001 - -* When the classical Monte Carlo program spinmc or spinmc_mpi was - used: - - reference the ALPS web page http://alps.comp-phys.org/ - - and cite the publications: - A.F. Albuquerque et al., J. of Magn. and Magn. Materials 310, 1187 (2007). - B. Bauer et al., J. Stat. Mech. (2011) P05001 - -* When the diagonalization programs fulldiag, sparsediag or fulldiag_mpi was - used: - - reference the ALPS web page http://alps.comp-phys.org/ - - and cite the publications: - A.F. Albuquerque et al., J. of Magn. and Magn. Materials 310, 1187 (2007). - B. Bauer et al., J. Stat. Mech. (2011) P05001 - -* When the worm quantum Monte Carlo program is used: - - reference the ALPS web page http://alps.comp-phys.org/ - - and cite the publications: - A.F. Albuquerque et al., J. of Magn. and Magn. Materials 310, 1187 (2007). - B. Bauer et al., J. Stat. Mech. (2011) P05001 - -* When the quantum Wang-Landau program is used: - - reference the ALPS web page http://alps.comp-phys.org/ - - and cite the publications: - M. Troyer, S. Wessel, and F. Alet, Phys. Rev. Lett. 90, 120201 (2003). - A.F. Albuquerque et al., J. of Magn. and Magn. Materials 310, 1187 (2007). - B. Bauer et al., J. Stat. Mech. (2011) P05001 - -* When the Continuous-Time quantum Monte Carlo impurity solver programs or the DMFT framework are used: - - cite the publication: - A.F. Albuquerque et al., J. of Magn. and Magn. Materials 310, 1187 (2007). - B. Bauer et al., J. Stat. Mech. (2011) P05001 - - cite the ALPS DMFT publication (contact the authors for a current reference): - E. Gull, P. Werner, S. Fuchs, B. Surer, T. Pruschke, and M. Troyer, submitted to Computer Physics Communications. - - Copyright ALPS collaboration 2002 - 2010 - Distributed under the Boost Software License, Version 1.0. - (See accompanying file LICENSE_1_0.txt or copy at - http://www.boost.org/LICENSE_1_0.txt) - -Since some of the references are to preprints we would like to ask you -to check the ALPS web page http://alps.comp-phys.org/ for updates. - ------------------------------------- -This binary installer package comes with other libraries distributed under their own license terms: - -The version of Szip distributed with HDF products is free for non-commercial use. - -lp_solve is distributed under the LPGL, shown on the license page. - -------------------------------------- - -HDF5 (Hierarchical Data Format 5) Software Library and Utilities -Copyright 2006-2009 by The HDF Group. - -NCSA HDF5 (Hierarchical Data Format 5) Software Library and Utilities -Copyright 1998-2006 by the Board of Trustees of the University of Illinois. - -All rights reserved. - -Redistribution and use in source and binary forms, with or without modification, are permitted for any purpose (including commercial purposes) provided that the following conditions are met: - -Redistributions of source code must retain the above copyright notice, this list of conditions, and the following disclaimer. -Redistributions in binary form must reproduce the above copyright notice, this list of conditions, and the following disclaimer in the documentation and/or materials provided with the distribution. -In addition, redistributions of modified forms of the source or binary code must carry prominent notices stating that the original code was changed and the date of the change. -All publications or advertising materials mentioning features or use of this software are asked, but not required, to acknowledge that it was developed by The HDF Group and by the National Center for Supercomputing Applications at the University of Illinois at Urbana-Champaign and credit the contributors. -Neither the name of The HDF Group, the name of the University, nor the name of any Contributor may be used to endorse or promote products derived from this software without specific prior written permission from The HDF Group, the University, or the Contributor, respectively. -DISCLAIMER: THIS SOFTWARE IS PROVIDED BY THE HDF GROUP AND THE CONTRIBUTORS "AS IS" WITH NO WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED. In no event shall The HDF Group or the Contributors be liable for any damages suffered by the users arising out of the use of this software, even if advised of the possibility of such damage. - - -Portions of HDF5 were developed with support from the University of California, Lawrence Livermore National Laboratory (UC LLNL). The following statement applies to those portions of the product and must be retained in any redistribution of source code, binaries, documentation, and/or accompanying materials: - -This work was partially produced at the University of California, Lawrence Livermore National Laboratory (UC LLNL) under contract no. W-7405-ENG-48 (Contract 48) between the U.S. Department of Energy (DOE) and The Regents of the University of California (University) for the operation of UC LLNL. -DISCLAIMER: This work was prepared as an account of work sponsored by an agency of the United States Government. Neither the United States Government nor the University of California nor any of their employees, makes any warranty, express or implied, or assumes any liability or responsibility for the accuracy, completeness, or usefulness of any information, apparatus, product, or process disclosed, or represents that its use would not infringe privately- owned rights. Reference herein to any specific commercial products, process, or service by trade name, trademark, manufacturer, or otherwise, does not necessarily constitute or imply its endorsement, recommendation, or favoring by the United States Government or the University of California. The views and opinions of authors expressed herein do not necessarily state or reflect those of the United States Government or the University of California, and shall not be used for advertising or product endorsement purposes. - -------------------------------------- - diff --git a/README.md b/README.md index b49b867bf..852cac70e 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,53 @@ -[![ALPS CI/CD](https://github.com/ALPSim/legacy/actions/workflows/build.yml/badge.svg)](https://github.com/ALPSim/legacy/actions/workflows/build.yml) +[![Build](https://github.com/ALPSim/ALPS/actions/workflows/build.yml/badge.svg)](https://github.com/ALPSim/ALPS/actions/workflows/build.yml) +[![Python wheels](https://github.com/ALPSim/ALPS/actions/workflows/build_wheels.yml/badge.svg)](https://github.com/ALPSim/ALPS/actions/workflows/build_wheels.yml) +[![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE.txt) -## Algorithms and Libraries for Physics Simulations (ALPS) +# ALPS — Algorithms and Libraries for Physics Simulations The ALPS software package aims to provide a set of well tested, robust, and standardized components for numerical simulations of condensed matter systems, including bosonic, fermionic, and spin systems. They consist of a set of components that are used in state-of-the-art high performance codes. -## Installation Instruction +**Project website:** [alps.comp-phys.org](https://alps.comp-phys.org/) -We support both binary and source installations. For details, please check out our [installation webpage](https://alps.comp-phys.org/documentation/install/). +## Installation + +### Python + +Binary `pyalps` wheels are available for supported Linux and macOS systems: + +```sh +python -m pip install pyalps +``` + +Plotting with `pyalps` requires Matplotlib, which can be installed together with the package: + +```sh +python -m pip install "pyalps[plot]" +``` + +### Build from source + +A native build requires CMake 3.18 or newer, a C++14 compiler, HDF5, and BLAS/LAPACK. MPI is enabled by default when available. The legacy Fortran interface is disabled by default. If a Boost source tree is not supplied, configuration downloads one and therefore requires network access. + +Configure a release build with an explicit installation prefix, then build and install it: + +```sh +cmake -S . -B _build/release \ + -DCMAKE_BUILD_TYPE=Release \ + -DCMAKE_INSTALL_PREFIX=/path/to/alps +cmake --build _build/release --parallel +cmake --install _build/release +``` + +Add `-DALPS_ENABLE_MPI=OFF` to the configure command for a serial-only build. To build the legacy Fortran interface and its examples, add `-DALPS_BUILD_FORTRAN=ON`; this requires a Fortran compiler and the HDF5 Fortran component. + +Building the Python bindings from source is a separate step against an installed ALPS C++ SDK; see the [`pyalps` build instructions](bindings/python/pyalps/README.md). + +Platform-specific binary, source, and Spack instructions are available on the [ALPS installation website](https://alps.comp-phys.org/documentation/install/). + +## Contributing + +See [CONTRIBUTING.md](CONTRIBUTING.md) for development and contribution guidance. + +## License and citations + +ALPS is distributed under the terms in [LICENSE.txt](LICENSE.txt). See [CITATION.md](CITATION.md) for citation guidance. diff --git a/README.txt b/README.txt deleted file mode 100644 index b0c6280be..000000000 --- a/README.txt +++ /dev/null @@ -1 +0,0 @@ -The ALPS software package aims to provide a set of well tested, robust, and standardized components for numerical simulations of condensed matter systems, including bosonic, fermionic, and spin systems. They consist of a set of components that are used in state-of-the-art high performance codes. diff --git a/Welcome.txt b/Welcome.txt deleted file mode 100644 index bf440f686..000000000 --- a/Welcome.txt +++ /dev/null @@ -1,4 +0,0 @@ -ALPS Project - -The ALPS project (Algorithms and Libraries for Physics Simulations) aims at providing generic parallel algorithms for classical and quantum lattice models and provides utility classes and algorithm for many other problems. It strives to increase software reuse in the physics community. - diff --git a/config/ALPSBuildname.cmake b/cmake/ALPSBuildname.cmake similarity index 100% rename from config/ALPSBuildname.cmake rename to cmake/ALPSBuildname.cmake diff --git a/config/ALPSConfig.cmake.in b/cmake/ALPSConfig.cmake.in similarity index 100% rename from config/ALPSConfig.cmake.in rename to cmake/ALPSConfig.cmake.in diff --git a/config/ALPSCore.cmake b/cmake/ALPSCore.cmake similarity index 100% rename from config/ALPSCore.cmake rename to cmake/ALPSCore.cmake diff --git a/config/ALPSTesting.cmake b/cmake/ALPSTesting.cmake similarity index 100% rename from config/ALPSTesting.cmake rename to cmake/ALPSTesting.cmake diff --git a/config/BoostUtils.cmake b/cmake/BoostUtils.cmake similarity index 100% rename from config/BoostUtils.cmake rename to cmake/BoostUtils.cmake diff --git a/config/CMakeLists.txt b/cmake/CMakeLists.txt similarity index 100% rename from config/CMakeLists.txt rename to cmake/CMakeLists.txt diff --git a/config/Compilers.cmake b/cmake/Compilers.cmake similarity index 100% rename from config/Compilers.cmake rename to cmake/Compilers.cmake diff --git a/config/Distribution.xml.in b/cmake/Distribution.xml.in similarity index 100% rename from config/Distribution.xml.in rename to cmake/Distribution.xml.in diff --git a/config/FindBoostForALPS.cmake b/cmake/FindBoostForALPS.cmake similarity index 100% rename from config/FindBoostForALPS.cmake rename to cmake/FindBoostForALPS.cmake diff --git a/config/FindBoostSrc.cmake b/cmake/FindBoostSrc.cmake similarity index 100% rename from config/FindBoostSrc.cmake rename to cmake/FindBoostSrc.cmake diff --git a/config/FindDocbookDtd.cmake b/cmake/FindDocbookDtd.cmake similarity index 100% rename from config/FindDocbookDtd.cmake rename to cmake/FindDocbookDtd.cmake diff --git a/config/FindDocbookXsl.cmake b/cmake/FindDocbookXsl.cmake similarity index 100% rename from config/FindDocbookXsl.cmake rename to cmake/FindDocbookXsl.cmake diff --git a/config/FindFop.cmake b/cmake/FindFop.cmake similarity index 100% rename from config/FindFop.cmake rename to cmake/FindFop.cmake diff --git a/config/FindLPSolve.cmake b/cmake/FindLPSolve.cmake similarity index 100% rename from config/FindLPSolve.cmake rename to cmake/FindLPSolve.cmake diff --git a/config/FindLapack.cmake b/cmake/FindLapack.cmake similarity index 100% rename from config/FindLapack.cmake rename to cmake/FindLapack.cmake diff --git a/config/FindMPIForALPS.cmake b/cmake/FindMPIForALPS.cmake similarity index 100% rename from config/FindMPIForALPS.cmake rename to cmake/FindMPIForALPS.cmake diff --git a/config/FindPythonMod.cmake b/cmake/FindPythonMod.cmake similarity index 100% rename from config/FindPythonMod.cmake rename to cmake/FindPythonMod.cmake diff --git a/config/FindSQLite.cmake b/cmake/FindSQLite.cmake similarity index 100% rename from config/FindSQLite.cmake rename to cmake/FindSQLite.cmake diff --git a/config/FindSZIP.cmake b/cmake/FindSZIP.cmake similarity index 100% rename from config/FindSZIP.cmake rename to cmake/FindSZIP.cmake diff --git a/config/FindSphinx.cmake b/cmake/FindSphinx.cmake similarity index 100% rename from config/FindSphinx.cmake rename to cmake/FindSphinx.cmake diff --git a/config/FindXsltproc.cmake b/cmake/FindXsltproc.cmake similarity index 100% rename from config/FindXsltproc.cmake rename to cmake/FindXsltproc.cmake diff --git a/config/UseALPS.cmake b/cmake/UseALPS.cmake similarity index 100% rename from config/UseALPS.cmake rename to cmake/UseALPS.cmake diff --git a/config/add_alps_test.cmake b/cmake/add_alps_test.cmake similarity index 91% rename from config/add_alps_test.cmake rename to cmake/add_alps_test.cmake index 36e7c79cc..8c8d459bf 100644 --- a/config/add_alps_test.cmake +++ b/cmake/add_alps_test.cmake @@ -53,15 +53,15 @@ macro(add_alps_test) if(RUN_TEST_DIR AND EXISTS ${RUN_TEST_DIR}/run_test.cmake) set(RUN_TEST ${RUN_TEST_DIR}/run_test.cmake) else(RUN_TEST_DIR AND EXISTS ${RUN_TEST_DIR}/run_test.cmake) - if(EXISTS ${PROJECT_SOURCE_DIR}/config/run_test.cmake) - set(RUN_TEST ${PROJECT_SOURCE_DIR}/config/run_test.cmake) - else(EXISTS ${PROJECT_SOURCE_DIR}/config/run_test.cmake) + if(EXISTS ${PROJECT_SOURCE_DIR}/cmake/run_test.cmake) + set(RUN_TEST ${PROJECT_SOURCE_DIR}/cmake/run_test.cmake) + else(EXISTS ${PROJECT_SOURCE_DIR}/cmake/run_test.cmake) if(EXISTS ${ALPS_ROOT_DIR}/share/alps/run_test.cmake) set(RUN_TEST ${ALPS_ROOT_DIR}/share/alps/run_test.cmake) else(EXISTS ${ALPS_ROOT_DIR}/share/alps/run_test.cmake) set(RUN_TEST ${CMAKE_INSTALL_PREFIX}/share/alps/run_test.cmake) endif(EXISTS ${ALPS_ROOT_DIR}/share/alps/run_test.cmake) - endif(EXISTS ${PROJECT_SOURCE_DIR}/config/run_test.cmake) + endif(EXISTS ${PROJECT_SOURCE_DIR}/cmake/run_test.cmake) endif(RUN_TEST_DIR AND EXISTS ${RUN_TEST_DIR}/run_test.cmake) add_test(${name} @@ -138,15 +138,15 @@ macro(add_alps_test_mpi) if(RUN_TEST_DIR AND EXISTS ${RUN_TEST_DIR}/run_test_mpi.cmake) set(RUN_TEST ${RUN_TEST_DIR}/run_test_mpi.cmake) else(RUN_TEST_DIR AND EXISTS ${RUN_TEST_DIR}/run_test_mpi.cmake) - if(EXISTS ${PROJECT_SOURCE_DIR}/config/run_test_mpi.cmake) - set(RUN_TEST ${PROJECT_SOURCE_DIR}/config/run_test_mpi.cmake) - else(EXISTS ${PROJECT_SOURCE_DIR}/config/run_test_mpi.cmake) + if(EXISTS ${PROJECT_SOURCE_DIR}/cmake/run_test_mpi.cmake) + set(RUN_TEST ${PROJECT_SOURCE_DIR}/cmake/run_test_mpi.cmake) + else(EXISTS ${PROJECT_SOURCE_DIR}/cmake/run_test_mpi.cmake) if(EXISTS ${ALPS_ROOT_DIR}/share/alps/run_test_mpi.cmake) set(RUN_TEST ${ALPS_ROOT_DIR}/share/alps/run_test_mpi.cmake) else(EXISTS ${ALPS_ROOT_DIR}/share/alps/run_test_mpi.cmake) set(RUN_TEST ${CMAKE_INSTALL_PREFIX}/share/alps/run_test_mpi.cmake) endif(EXISTS ${ALPS_ROOT_DIR}/share/alps/run_test_mpi.cmake) - endif(EXISTS ${PROJECT_SOURCE_DIR}/config/run_test_mpi.cmake) + endif(EXISTS ${PROJECT_SOURCE_DIR}/cmake/run_test_mpi.cmake) endif(RUN_TEST_DIR AND EXISTS ${RUN_TEST_DIR}/run_test_mpi.cmake) add_test(${name}-np${procs} diff --git a/config/alps_logo.png b/cmake/alps_logo.png similarity index 100% rename from config/alps_logo.png rename to cmake/alps_logo.png diff --git a/config/include.mk.in b/cmake/include.mk.in similarity index 100% rename from config/include.mk.in rename to cmake/include.mk.in diff --git a/config/make_package.sh.in b/cmake/make_package.sh.in similarity index 100% rename from config/make_package.sh.in rename to cmake/make_package.sh.in diff --git a/config/passthru.py b/cmake/passthru.py similarity index 100% rename from config/passthru.py rename to cmake/passthru.py diff --git a/config/py-compile b/cmake/py-compile similarity index 100% rename from config/py-compile rename to cmake/py-compile diff --git a/config/run_test.cmake b/cmake/run_test.cmake similarity index 100% rename from config/run_test.cmake rename to cmake/run_test.cmake diff --git a/config/run_test_mpi.cmake b/cmake/run_test_mpi.cmake similarity index 100% rename from config/run_test_mpi.cmake rename to cmake/run_test_mpi.cmake diff --git a/config/debian/sid/.bzr-builddeb/default.conf b/config/debian/sid/.bzr-builddeb/default.conf deleted file mode 100644 index 99317c03e..000000000 --- a/config/debian/sid/.bzr-builddeb/default.conf +++ /dev/null @@ -1,3 +0,0 @@ -[BUILDDEB] -merge = True -export-upstream = https://rigarash@alps.comp-phys.org/svn/alps1/trunk/alps diff --git a/config/debian/sid/.bzrignore b/config/debian/sid/.bzrignore deleted file mode 100644 index 2dee1753e..000000000 --- a/config/debian/sid/.bzrignore +++ /dev/null @@ -1 +0,0 @@ -debian diff --git a/config/debian/sid/README.source b/config/debian/sid/README.source deleted file mode 100644 index d2958fe42..000000000 --- a/config/debian/sid/README.source +++ /dev/null @@ -1,6 +0,0 @@ -This package uses quilt to manage all modifications to the upstream source. -Changes are stored in the source package as diffs in debian/patches and -applied during the build. - -See /usr/share/doc/quilt/README.source for a detailed explanation. - diff --git a/config/debian/sid/alps-applications.install b/config/debian/sid/alps-applications.install deleted file mode 100644 index e4c894bcb..000000000 --- a/config/debian/sid/alps-applications.install +++ /dev/null @@ -1,17 +0,0 @@ -debian/tmp/usr/bin/dirloop_sse usr/bin/ -debian/tmp/usr/bin/dmft usr/bin/ -debian/tmp/usr/bin/dmrg usr/bin/ -debian/tmp/usr/bin/dwa usr/bin/ -debian/tmp/usr/bin/fulldiag usr/bin/ -debian/tmp/usr/bin/fulldiag_evaluate usr/bin/ -debian/tmp/usr/bin/hirschfye usr/bin/ -debian/tmp/usr/bin/hybridization usr/bin/ -debian/tmp/usr/bin/interaction usr/bin/ -debian/tmp/usr/bin/loop usr/bin/ -debian/tmp/usr/bin/qwl usr/bin/ -debian/tmp/usr/bin/qwl_evaluate usr/bin/ -debian/tmp/usr/bin/sparsediag usr/bin/ -debian/tmp/usr/bin/spinmc usr/bin/ -debian/tmp/usr/bin/spinmc_evaluate usr/bin/ -debian/tmp/usr/bin/worm usr/bin/ -debian/tmp/usr/bin/worm_evaluate usr/bin/ diff --git a/config/debian/sid/alps-tutorials.install b/config/debian/sid/alps-tutorials.install deleted file mode 100644 index faf00cddc..000000000 --- a/config/debian/sid/alps-tutorials.install +++ /dev/null @@ -1 +0,0 @@ -debian/tmp/usr/tutorials usr/share/alps/ diff --git a/config/debian/sid/changelog b/config/debian/sid/changelog deleted file mode 100644 index 9280183b7..000000000 --- a/config/debian/sid/changelog +++ /dev/null @@ -1,61 +0,0 @@ -alps (1:20150402~r7566-1) wheezy; urgency=low - - * New upstream snapshot (20150402-r7566). - - -- Synge Todo Thu, 02 Apr 2015 16:43:40 +0900 - -alps (1:20140623~r7482-1) wheezy; urgency=low - - * New upstream snapshot (20140623-r7482). - - -- Synge Todo Fri, 04 Jul 2014 09:18:02 +0900 - -alps (1:20140309~r7370-1) wheezy; urgency=low - - * New upstream snapshot (20140309-r7370). - - -- Synge Todo Sun, 09 Mar 2014 19:24:10 +0900 - -alps (1:20130626~r6962-1) wheezy; urgency=low - - * New upstream snapshot (20130626-r6962). - * Renamed alps2* as alps*. - * Introduced task-alps meta package. - - -- Synge Todo Mon, 01 Jul 2013 21:24:31 +0900 - -alps (2.0.0~rc4-1) unstable; urgency=low - - * New upstream release (2.0.0rc4). - * Add dirloop_sse to build. - * Remove "-Wl,--no-undefined" flag, since it causes build failure. - - -- Ryo IGARASHI Mon, 13 Dec 2010 17:21:37 +0900 - -alps (2.0.0~rc3-1) unstable; urgency=low - - * New upstream release (2.0.0rc3). - * Add "-Wl,--no-undefined" and "-Wl,--as-needed" option - for reducing binary size. - - -- Ryo IGARASHI Mon, 29 Nov 2010 10:17:44 +0900 - -alps (2.0.0~rc2-2) unstable; urgency=low - - * Add TEBD application to build. - - -- Ryo IGARASHI Thu, 25 Nov 2010 20:23:13 +0900 - -alps (2.0.0~rc2-1) unstable; urgency=low - - * New upstream release (2.0.0rc2). - * Switch to dpkg-source 3.0 (quilt) format. - - -- Ryo IGARASHI Thu, 25 Nov 2010 09:54:24 +0900 - -alps (2.0.0~b4-1) unstable; urgency=low - - * Initial release for 2.0.0b4. (Closes: #317973) - * lintian-clean (except for binary-without-manpage). - - -- Ryo IGARASHI Tue, 02 Nov 2010 16:42:13 +0900 diff --git a/config/debian/sid/compat b/config/debian/sid/compat deleted file mode 100644 index 7ed6ff82d..000000000 --- a/config/debian/sid/compat +++ /dev/null @@ -1 +0,0 @@ -5 diff --git a/config/debian/sid/control b/config/debian/sid/control deleted file mode 100644 index 4bf945e1d..000000000 --- a/config/debian/sid/control +++ /dev/null @@ -1,121 +0,0 @@ -Source: alps -Section: non-free -Priority: extra -Maintainer: Ryo IGARASHI and Synge Todo -Build-Depends: cdbs, debhelper (>= 7.0.50~), cmake, - libboost-date-time-dev (>= 1.47.0), libboost-filesystem-dev (>= - 1.47.0), libboost-mpi-dev (>= 1.47.0), libboost-program-options-dev - (>= 1.47.0), libboost-python-dev (>= 1.47.0), libboost-regex-dev (>= - 1.47.0), libboost-serialization-dev (>= 1.47.0), libboost-system-dev - (>= 1.47.0), libboost-thread-dev (>= 1.47.0), libhdf5-serial-dev | - libhdf5-dev, mpi-default-dev, libsqlite3-dev, python-matplotlib, - liblapack-dev, gfortran -Standards-Version: 3.9.1 -Homepage: http://alps.comp-phys.org/ -Vcs-Svn: https://rigarash@alps.comp-phys.org/svn/alps1/trunk/alps -Vcs-Browser: https://alps.comp-phys.org/trac/browser - -Package: task-alps -Architecture: any -Depends: ${shlibs:Depends}, ${misc:Depends}, alps-applications, alps-tutorials, libalps, libalps-bin, libalps-dbg, libalps-dev, libboost-numeric-bindings-dev, python-pyalps -Description: The ALPS project - Libraries, Applications, and Tutorials - The ALPS project (Algorithms and Libraries for Physics Simulations) - is an open source effort aiming at providing high-end simulation - codes for strongly correlated quantum mechanical systems as well as - C++ libraries for simplifying the development of such code. ALPS - strives to increase software reuse in the physics community. - This package installs all the ALPS libraries, applications, and tutorials. - -Package: libalps -Architecture: any -Depends: ${shlibs:Depends}, ${misc:Depends} -Description: The ALPS project - Library - The ALPS project (Algorithms and Libraries for Physics Simulations) - is an open source effort aiming at providing high-end simulation - codes for strongly correlated quantum mechanical systems as well as - C++ libraries for simplifying the development of such code. ALPS - strives to increase software reuse in the physics community. - This package contains shared library of ALPS Library. - -Package: libalps-dbg -Architecture: any -Depends: libalps (= ${binary:Version}), ${misc:Depends} -Description: The ALPS project - Library with debugging symbols - The ALPS project (Algorithms and Libraries for Physics Simulations) - is an open source effort aiming at providing high-end simulation - codes for strongly correlated quantum mechanical systems as well as - C++ libraries for simplifying the development of such code. ALPS - strives to increase software reuse in the physics community. - This package contains debugging symbols of ALPS Library. - -Package: libalps-dev -Architecture: any -Depends: libalps (= ${binary:Version}), - libboost-numeric-bindings-dev, ${misc:Depends} -Recommends: libalps-bin (= ${binary:Version}) -Description: The ALPS project - Development files - The ALPS project (Algorithms and Libraries for Physics Simulations) - is an open source effort aiming at providing high-end simulation - codes for strongly correlated quantum mechanical systems as well as - C++ libraries for simplifying the development of such code. ALPS - strives to increase software reuse in the physics community. - This package contains development files of ALPS Library. - -Package: libboost-numeric-bindings-dev -Architecture: any -Depends: ${misc:Depends} -Description: Numeric Bindings Library for Linear Algebra - This package forms part of the Boost C++ Libraries (Sandbox) - collections. - -Package: libalps-bin -Architecture: any -Depends: libalps (= ${binary:Version}), ${shlibs:Depends}, - ${misc:Depends} -Description: The ALPS project - Miscellaneous tools - The ALPS project (Algorithms and Libraries for Physics Simulations) - is an open source effort aiming at providing high-end simulation - codes for strongly correlated quantum mechanical systems as well as - C++ libraries for simplifying the development of such code. ALPS - strives to increase software reuse in the physics community. - This package contains miscellaneous tools of ALPS Library. - -Package: alps-applications -Architecture: any -Depends: libalps (= ${binary:Version}), ${shlibs:Depends}, - ${misc:Depends} -Recommends: libalps-bin (= ${binary:Version}), python-pyalps (= - ${binary:Version}) -Description: The ALPS project - Application binaries - The ALPS project (Algorithms and Libraries for Physics Simulations) - is an open source effort aiming at providing high-end simulation - codes for strongly correlated quantum mechanical systems as well as - C++ libraries for simplifying the development of such code. ALPS - strives to increase software reuse in the physics community. - This package contains application binary. - -Package: python-pyalps -Architecture: any -Depends: libalps (= ${binary:Version}), python2.7, python-numpy, - python-matplotlib, ${shlibs:Depends}, - ${misc:Depends} -Description: The ALPS project - python modules - The ALPS project (Algorithms and Libraries for Physics Simulations) - is an open source effort aiming at providing high-end simulation - codes for strongly correlated quantum mechanical systems as well as - C++ libraries for simplifying the development of such code. ALPS - strives to increase software reuse in the physics community. - This package contains python module. - -Package: alps-tutorials -Architecture: any -Depends: alps-applications (= ${binary:Version}), python-pyalps (= - ${binary:Version}), libalps-bin (= ${binary:Version}), - ${misc:Depends} -Description: The ALPS project - tutorials - The ALPS project (Algorithms and Libraries for Physics Simulations) - is an open source effort aiming at providing high-end simulation - codes for strongly correlated quantum mechanical systems as well as - C++ libraries for simplifying the development of such code. ALPS - strives to increase software reuse in the physics community. - This package contains tutorials for applications. diff --git a/config/debian/sid/copyright b/config/debian/sid/copyright deleted file mode 100644 index 2016f1c7b..000000000 --- a/config/debian/sid/copyright +++ /dev/null @@ -1,29 +0,0 @@ -This work was packaged for Debian by: - - Ryo IGARASHI on Sun, 02 May 2010 12:17:02 +0900 - Synge Todo Mon, 01 Jul 2013 21:24:31 +0900 - -It was downloaded from: - - - -Upstream Author(s): - - ALPS Collaboration - -Copyright: - - Copyright (C) 1994-2015 ALPS Collaboration - -License: - - ALPS LIBRARY LICENSE version 1.1 - see LICENCE.txt. - ALPS APPLICATION LICENCE version 1.0 - see LICENCE-package.txt. - -The Debian packaging is: - - Copyright (C) 2010-2015 Ryo IGARASHI and - Synge Todo - and is licensed under the ALPS LIBRARY LICENCE version 1.1. diff --git a/config/debian/sid/libalps-bin.install b/config/debian/sid/libalps-bin.install deleted file mode 100644 index f106c2355..000000000 --- a/config/debian/sid/libalps-bin.install +++ /dev/null @@ -1,36 +0,0 @@ -debian/tmp/usr/bin/archive usr/bin/ -debian/tmp/usr/bin/archivecat usr/bin/ -debian/tmp/usr/bin/checksign usr/bin/ -debian/tmp/usr/bin/compactrun usr/bin/ -debian/tmp/usr/bin/convert2html usr/bin/ -debian/tmp/usr/bin/convert2text usr/bin/ -debian/tmp/usr/bin/convert2xml usr/bin/ -debian/tmp/usr/bin/extractgp usr/bin/ -debian/tmp/usr/bin/extracthtml usr/bin/ -debian/tmp/usr/bin/extractmpl usr/bin/ -debian/tmp/usr/bin/extracttext usr/bin/ -debian/tmp/usr/bin/extractxmgr usr/bin/ -debian/tmp/usr/bin/fleas_correlated usr/bin/ -debian/tmp/usr/bin/fleas_direct usr/bin/ -debian/tmp/usr/bin/fleas_independent usr/bin/ -debian/tmp/usr/bin/fleas_simpleminded usr/bin/ -debian/tmp/usr/bin/fleas_uncorrelated usr/bin/ -debian/tmp/usr/bin/lattice2xml usr/bin/ -debian/tmp/usr/bin/lattice-preview usr/bin/ -debian/tmp/usr/bin/maxent usr/bin/ -debian/tmp/usr/bin/p2h5 usr/bin/ -debian/tmp/usr/bin/parameter2hdf5 usr/bin/ -debian/tmp/usr/bin/parameter2xml usr/bin/ -debian/tmp/usr/bin/pconfig usr/bin/ -debian/tmp/usr/bin/pevaluate usr/bin/ -debian/tmp/usr/bin/plot2gp usr/bin/ -debian/tmp/usr/bin/plot2html usr/bin/ -debian/tmp/usr/bin/plot2mpl usr/bin/ -debian/tmp/usr/bin/plot2text usr/bin/ -debian/tmp/usr/bin/plot2xmgr usr/bin/ -debian/tmp/usr/bin/poutput usr/bin/ -debian/tmp/usr/bin/printgraph usr/bin/ -debian/tmp/usr/bin/txt2archive usr/bin/ -debian/tmp/usr/bin/use_local_stylesheet usr/bin/ -debian/tmp/usr/bin/xml2archive usr/bin/ -debian/tmp/usr/bin/xslttransform usr/bin/ diff --git a/config/debian/sid/libalps-dev.install b/config/debian/sid/libalps-dev.install deleted file mode 100644 index 43bf07321..000000000 --- a/config/debian/sid/libalps-dev.install +++ /dev/null @@ -1,5 +0,0 @@ -debian/tmp/usr/include/alps/* usr/include/alps/ -debian/tmp/usr/include/ietl/* usr/include/ietl/ -debian/tmp/usr/include/boost/*.hpp usr/include/boost/ -debian/tmp/usr/lib/libalps.so usr/lib/ -debian/tmp/usr/share/alps/* usr/share/alps/ diff --git a/config/debian/sid/libalps-dev.links b/config/debian/sid/libalps-dev.links deleted file mode 100644 index 69fa28ff6..000000000 --- a/config/debian/sid/libalps-dev.links +++ /dev/null @@ -1 +0,0 @@ -usr/share/alps usr/share/cmake-2.8/ALPS diff --git a/config/debian/sid/libalps.install b/config/debian/sid/libalps.install deleted file mode 100644 index 20660f2e0..000000000 --- a/config/debian/sid/libalps.install +++ /dev/null @@ -1,2 +0,0 @@ -debian/tmp/usr/lib/libalps.so.* usr/lib/ -debian/tmp/usr/lib/xml/* usr/lib/xml/ diff --git a/config/debian/sid/libboost-numeric-bindings-dev.install b/config/debian/sid/libboost-numeric-bindings-dev.install deleted file mode 100644 index c4ba43e72..000000000 --- a/config/debian/sid/libboost-numeric-bindings-dev.install +++ /dev/null @@ -1 +0,0 @@ -debian/tmp/usr/include/boost/numeric/* usr/include/boost/numeric/ diff --git a/config/debian/sid/python-pyalps.install b/config/debian/sid/python-pyalps.install deleted file mode 100644 index 5e9b297bb..000000000 --- a/config/debian/sid/python-pyalps.install +++ /dev/null @@ -1,3 +0,0 @@ -debian/tmp/usr/lib/pyalps/*.py usr/lib/python2.7/dist-packages/pyalps/ -debian/tmp/usr/lib/pyalps/*.so usr/lib/python2.7/dist-packages/pyalps/ -debian/tmp/usr/lib/python/alps usr/lib/python2.7/dist-packages/ diff --git a/config/debian/sid/rules b/config/debian/sid/rules deleted file mode 100755 index 61935cd9a..000000000 --- a/config/debian/sid/rules +++ /dev/null @@ -1,23 +0,0 @@ -#!/usr/bin/make -f - -include /usr/share/cdbs/1/rules/debhelper.mk -include /usr/share/cdbs/1/class/cmake.mk - -# Add here any variable or target overrides you need. - -# Extra flags passed to cmake. -# ALPS specific options -DEB_CMAKE_EXTRA_FLAGS = \ - -DALPS_BUILD_APPLICATIONS:BOOL=ON \ - -DALPS_ENABLE_OPENMP:BOOL=ON \ - -DALPS_BUILD_FORTRAN:BOOL=OFF \ - -DCMAKE_Fortran_FLAGS:STRING=-fopenmp - -# Linker flags for reduce binary size -DEB_CMAKE_EXTRA_FLAGS += \ - -DCMAKE_SHARED_LINKER_FLAGS="-Wl,--as-needed" \ - -DCMAKE_MODULE_LINKER_FLAGS="-Wl,--as-needed" \ - -DCMAKE_EXE_LINKER_FLAGS="-Wl,--as-needed" - -# Allow parallel builds -DEB_BUILD_PARALLEL = yes diff --git a/config/debian/sid/source/format b/config/debian/sid/source/format deleted file mode 100644 index 163aaf8d8..000000000 --- a/config/debian/sid/source/format +++ /dev/null @@ -1 +0,0 @@ -3.0 (quilt) diff --git a/config/preamble-light.in b/config/preamble-light.in deleted file mode 100644 index 3203dab12..000000000 --- a/config/preamble-light.in +++ /dev/null @@ -1,39 +0,0 @@ -/***************************************************************************** -* -* ALPS Project: Algorithms and Libraries for Physics Simulations -* -* ALPS Light Libraries -* -* @COPYRIGHT@ -* -* This software is part of the "ALPS Light" Libraries, public-domain -* part of the ALPS Libraries. If you need the full functionality of -* the ALPS Libraries, such as Lattice, Model, Scheduler, etc, please -* use the full version of ALPS Libraries, which is available from -* http://alps.comp-phys.org/. -* -* Permission is hereby granted, free of charge, to any person or organization -* obtaining a copy of the software and accompanying documentation covered by -* this license (the "Software") to use, reproduce, display, distribute, -* execute, and transmit the Software, and to prepare derivative works of the -* Software, and to permit third-parties to whom the Software is furnished to -* do so, all subject to the following: -* -* The copyright notices in the Software and this entire statement, including -* the above license grant, this restriction and the following disclaimer, -* must be included in all copies of the Software, in whole or in part, and -* all derivative works of the Software, unless such copies or derivative -* works are solely in the form of machine-executable object code generated by -* a source language processor. -* -* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -* FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT -* SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE -* FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE, -* ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER -* DEALINGS IN THE SOFTWARE. -* -*****************************************************************************/ - -/* @ID@ */ diff --git a/config/preamble.in b/config/preamble.in deleted file mode 100644 index d6cbb782c..000000000 --- a/config/preamble.in +++ /dev/null @@ -1,28 +0,0 @@ -/***************************************************************************** -* -* ALPS Project: Algorithms and Libraries for Physics Simulations -* -* ALPS Libraries -* -* @COPYRIGHT@ -* -* This software is part of the ALPS libraries, published under the ALPS -* Library License; you can use, redistribute it and/or modify it under -* the terms of the license, either version 1 or (at your option) any later -* version. -* -* You should have received a copy of the ALPS Library License along with -* the ALPS Libraries; see the file LICENSE.txt. If not, the license is also -* available from http://alps.comp-phys.org/. -* -* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -* FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT -* SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE -* FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE, -* ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER -* DEALINGS IN THE SOFTWARE. -* -*****************************************************************************/ - -/* @ID@ */ diff --git a/config/preamble_py.in b/config/preamble_py.in deleted file mode 100644 index 226831af7..000000000 --- a/config/preamble_py.in +++ /dev/null @@ -1,28 +0,0 @@ -############################################################################## -# -# ALPS Project: Algorithms and Libraries for Physics Simulations -# -# ALPS Libraries -# -# @COPYRIGHT@ -# -# This software is part of the ALPS libraries, published under the ALPS -# Library License; you can use, redistribute it and/or modify it under -# the terms of the license, either version 1 or (at your option) any later -# version. -# -# You should have received a copy of the ALPS Library License along with -# the ALPS Libraries; see the file LICENSE.txt. If not, the license is also -# available from http://alps.comp-phys.org/. -# -# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -# FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT -# SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE -# FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE, -# ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER -# DEALINGS IN THE SOFTWARE. -# -############################################################################## - -# @ID@ diff --git a/config/update_preamble b/config/update_preamble deleted file mode 100755 index 95c4b2522..000000000 --- a/config/update_preamble +++ /dev/null @@ -1,136 +0,0 @@ -#!/usr/bin/perl - -# Script for updating preamble of *.h and *.C -# -# Usage: -# update_preamble.pl [-l] [files] -# Options: -# -l : use preamble for light version instead of full version - -# written by Synge Todo - -$basedir = $0; -$basedir =~ s/[a-zA-Z\_\.]+$//; - -if (@ARGV[0] ne '-l') { - # ALPS full version - $skel = join('', $basedir, "preamble.in"); -} else { - # ALPS-light - shift @ARGV; - $skel = join('', $basedir, "preamble-light.in"); -} -if (!-f $skel) { - die "Couldn't find $skel."; -} - -foreach $file (@ARGV) { - if (-f $file) { - $file_new = "$file.$$.tmp"; - - # scan - $year0 = ""; - $year1 = ""; - $id = ""; - @authors = (); - @emails = (); - $finish_preamble = 0; - $skip = 0; - $print_id = 0; - open(ORIG, "< $file") || die "Couldn't open $file"; - open(NEW, "> $file_new") || die "Couldn't open $file_new"; - foreach $line () { - chomp($line); - $line =~ s/\t/ /g; - $line =~ s/\s+$//g; - if ($finish_preamble == 0) { - if ($line =~ /^\s*\*\s+Copyright.+([0-9]{4})-([0-9]{4})\s+by\s+(\S\C+)\s+\<([a-zA-Z0-9\.\-_]+@[a-zA-Z0-9\.\-_]+)\>/) { - $year0 = $1; - $year1 = $2; - @authors[$#authors+1] = $3; - @emails[$#emails+1] = $4; - } elsif ($line =~ /^\s*\*\s+Copyright.+([0-9]{4})\s+by\s+(\S\C+)\s+\<([a-zA-Z0-9\.\-_]+@[a-zA-Z0-9\.\-_]+)\>/) { - $year0 = $1; - @authors[$#authors+1] = $2; - @emails[$#emails+1] = $3; - } elsif ($line =~ /^\s*\*\s+(\S\C+)\s+\<([a-zA-Z0-9\.\-_]+@[a-zA-Z0-9\.\-_]+)\>/) { - @authors[$#authors + 1] = $1; - @emails[$#emails + 1] = $2; - } elsif ($line =~ /(\$Id\:\C+\$)/) { - $id = $1; - } elsif ($line =~ /(^\s*$)|(^$)|(^\*)|(^ \*)|(^\/\*)/) { - ## nothing to do - } else { - $finish_preamble = 1; - } - - if ($finish_preamble == 1) { - if ($year0 eq "" || @authors[0] eq "") { - ## Year and authors not found. Skip this file. - $skip = 1; - } else { - if ($year1 eq $year0) { $year1 = ""; } - # if ($id eq "") { $id = join("", "\$I", "d: \$"); } - - ## print out preamble - open(SKEL, "< $skel") || die "Couldn't open $skel"; - foreach $sk () { - chomp($sk); - if ($sk =~ /\@COPYRIGHT\@/) { - if ($year1) { - print NEW "* Copyright (C) $year0-$year1 by @authors[0] <@emails[0]>"; - } else { - print NEW "* Copyright (C) $year0 by @authors[0] <@emails[0]>"; - } - if ($#authors > 0) { print NEW ","; } - print NEW "\n"; - for ($i = 1; $i <= $#authors; $i++) { - if ($year1) { - print NEW "* @authors[$i] <@emails[$i]>"; - } else { - print NEW "* @authors[$i] <@emails[$i]>"; - } - if ($i < $#authors) { print NEW ","; } - print NEW "\n"; - } - } elsif ($sk =~ /\@ID\@/) { - if ($id ne "") { - $sk =~ s/\@ID\@/$id/; - print NEW "$sk\n"; - $print_id=1; - } - } else { - print NEW "$sk\n"; - } - } - if ($print_id == 1) { - print NEW "\n"; - } - } - } - } - - if ($skip == 0 && $finish_preamble == 1) { - print NEW "$line\n"; - } - } - close(ORIG); - close(NEW); - - if ($skip ==0) { - system("diff $file $file_new > /dev/null"); - if ($? == 256) { - unlink $file; - rename $file_new, $file; - print "$file is updated.\n"; - } else { - unlink $file_new; - } - } else { - print "$file does not obey ALPS standard. Skipped.\n"; - unlink $file_new; - } - } else { - print "Couldn't open $file. Skipped.\n"; - } -} diff --git a/config/update_preamble_py b/config/update_preamble_py deleted file mode 100755 index 046da2949..000000000 --- a/config/update_preamble_py +++ /dev/null @@ -1,136 +0,0 @@ -#!/usr/bin/perl - -# Script for updating preamble of *.h and *.C -# -# Usage: -# update_preamble.pl [-l] [files] -# Options: -# -l : use preamble for light version instead of full version - -# written by Synge Todo - -$basedir = $0; -$basedir =~ s/[a-zA-Z\_\.]+$//; - -if (@ARGV[0] ne '-l') { - # ALPS full version - $skel = join('', $basedir, "preamble_py.in"); -} else { - # ALPS-light - shift @ARGV; - $skel = join('', $basedir, "preamble-light.in"); -} -if (!-f $skel) { - die "Couldn't find $skel."; -} - -foreach $file (@ARGV) { - if (-f $file) { - $file_new = "$file.$$.tmp"; - - # scan - $year0 = ""; - $year1 = ""; - $id = ""; - @authors = (); - @emails = (); - $finish_preamble = 0; - $skip = 0; - $print_id = 0; - open(ORIG, "< $file") || die "Couldn't open $file"; - open(NEW, "> $file_new") || die "Couldn't open $file_new"; - foreach $line () { - chomp($line); - $line =~ s/\t/ /g; - $line =~ s/\s+$//g; - if ($finish_preamble == 0) { - if ($line =~ /^\s*\#\s+Copyright.+([0-9]{4})-([0-9]{4})\s+by\s+(\S\C+)\s+\<([a-zA-Z0-9\.\-_]+@[a-zA-Z0-9\.\-_]+)\>/) { - $year0 = $1; - $year1 = $2; - @authors[$#authors+1] = $3; - @emails[$#emails+1] = $4; - } elsif ($line =~ /^\s*\#\s+Copyright.+([0-9]{4})\s+by\s+(\S\C+)\s+\<([a-zA-Z0-9\.\-_]+@[a-zA-Z0-9\.\-_]+)\>/) { - $year0 = $1; - @authors[$#authors+1] = $2; - @emails[$#emails+1] = $3; - } elsif ($line =~ /^\s*\#\s+(\S\C+)\s+\<([a-zA-Z0-9\.\-_]+@[a-zA-Z0-9\.\-_]+)\>/) { - @authors[$#authors + 1] = $1; - @emails[$#emails + 1] = $2; - } elsif ($line =~ /(\$Id\:\C+\$)/) { - $id = $1; - } elsif ($line =~ /(^\s*$)|(^$)|(^\#)|(^ \#)|(^\/\#)/) { - ## nothing to do - } else { - $finish_preamble = 1; - } - - if ($finish_preamble == 1) { - if ($year0 eq "" || @authors[0] eq "") { - ## Year and authors not found. Skip this file. - $skip = 1; - } else { - if ($year1 eq $year0) { $year1 = ""; } - # if ($id eq "") { $id = join("", "\$I", "d: \$"); } - - ## print out preamble - open(SKEL, "< $skel") || die "Couldn't open $skel"; - foreach $sk () { - chomp($sk); - if ($sk =~ /\@COPYRIGHT\@/) { - if ($year1) { - print NEW "# Copyright (C) $year0-$year1 by @authors[0] <@emails[0]>"; - } else { - print NEW "# Copyright (C) $year0 by @authors[0] <@emails[0]>"; - } - if ($#authors > 0) { print NEW ","; } - print NEW "\n"; - for ($i = 1; $i <= $#authors; $i++) { - if ($year1) { - print NEW "# @authors[$i] <@emails[$i]>"; - } else { - print NEW "# @authors[$i] <@emails[$i]>"; - } - if ($i < $#authors) { print NEW ","; } - print NEW "\n"; - } - } elsif ($sk =~ /\@ID\@/) { - if ($id ne "") { - $sk =~ s/\@ID\@/$id/; - print NEW "$sk\n"; - $print_id=1; - } - } else { - print NEW "$sk\n"; - } - } - if ($print_id == 1) { - print NEW "\n"; - } - } - } - } - - if ($skip == 0 && $finish_preamble == 1) { - print NEW "$line\n"; - } - } - close(ORIG); - close(NEW); - - if ($skip ==0) { - system("diff $file $file_new > /dev/null"); - if ($? == 256) { - unlink $file; - rename $file_new, $file; - print "$file is updated.\n"; - } else { - unlink $file_new; - } - } else { - print "$file does not obey ALPS standard. Skipped.\n"; - unlink $file_new; - } - } else { - print "Couldn't open $file. Skipped.\n"; - } -} From d694119dbe9bfd219a53a74f462e2f4e49bca73b Mon Sep 17 00:00:00 2001 From: Tobias Wolf Date: Fri, 24 Jul 2026 11:37:31 -0500 Subject: [PATCH 2/7] build: align CMake floors and generated paths --- CMakeLists.txt | 8 ++++---- CONTRIBUTING.md | 8 ++++---- README.md | 9 ++++++++- tutorials/alpsize-01-cmake/CMakeLists.txt | 2 +- tutorials/alpsize-02-original-c/CMakeLists.txt | 2 +- tutorials/alpsize-03-basic-cpp/CMakeLists.txt | 2 +- tutorials/alpsize-04-stl/CMakeLists.txt | 2 +- tutorials/alpsize-05-boost/CMakeLists.txt | 2 +- tutorials/alpsize-06-parameters/CMakeLists.txt | 2 +- tutorials/alpsize-07-alea/CMakeLists.txt | 2 +- tutorials/alpsize-08-lattice/CMakeLists.txt | 2 +- tutorials/alpsize-09-scheduler/CMakeLists.txt | 2 +- tutorials/alpsize-10-fortran-scheduler/CMakeLists.txt | 2 +- tutorials/alpsize-11-fortran-ising/CMakeLists.txt | 2 +- tutorials/code-06-mcmain-c++/CMakeLists.txt | 2 +- tutorials/code-07-mcmain-mcbase/CMakeLists.txt | 2 +- .../heisenberg/1d_lattice/CMakeLists.txt | 2 +- .../heisenberg/nd_lattice/CMakeLists.txt | 4 +--- .../heisenberg/o_n_model/CMakeLists.txt | 2 +- 19 files changed, 32 insertions(+), 27 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 8b202cf49..49c52dcca 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -436,8 +436,8 @@ if(PYTHON_LIBRARY) list(APPEND ALPS_EXTRA_LIBRARIES ${PYTHON_LIBRARY}) endif(PYTHON_LIBRARY) -configure_file(cmake/ALPSConfig.cmake.in ${PROJECT_BINARY_DIR}/config/ALPSConfig.cmake @ONLY) -configure_file(cmake/include.mk.in ${PROJECT_BINARY_DIR}/config/include.mk) +configure_file(cmake/ALPSConfig.cmake.in ${PROJECT_BINARY_DIR}/cmake/ALPSConfig.cmake @ONLY) +configure_file(cmake/include.mk.in ${PROJECT_BINARY_DIR}/cmake/include.mk) # installation @@ -477,8 +477,8 @@ install(DIRECTORY ${PROJECT_BINARY_DIR}/lib/xml DESTINATION ${ALPS_XML_PATH} COM add_subdirectory(cmake) install(FILES cmake/UseALPS.cmake - ${PROJECT_BINARY_DIR}/config/ALPSConfig.cmake - ${PROJECT_BINARY_DIR}/config/include.mk + ${PROJECT_BINARY_DIR}/cmake/ALPSConfig.cmake + ${PROJECT_BINARY_DIR}/cmake/include.mk cmake/run_test.cmake cmake/run_test_mpi.cmake cmake/add_alps_test.cmake diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index c64d68452..3fd052873 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -50,7 +50,7 @@ Before opening a new issue, please search existing issues to avoid duplicates. ### Prerequisites -- CMake ≥ 3.18 +- CMake ≥ 3.18 for normal configuration; CMake ≥ 3.21 for presets - A C++17-capable compiler (GCC, Clang, Intel, or Fujitsu) - Boost (downloaded automatically during configuration; or use a system install with `-DALPS_USE_SYSTEM_BOOST=ON`) - For Fortran bindings: gfortran (or compatible Fortran compiler) @@ -79,8 +79,7 @@ cmake .. -DCMAKE_BUILD_TYPE=Release make -j$(nproc) ``` -Alternatively, use the bundled CMake preset (requires CMake ≥ 3.21, which is -newer than the 3.18 minimum for a plain configure): +Alternatively, use the bundled CMake preset (requires CMake ≥ 3.21): ```bash cmake --preset default cmake --build --preset default @@ -178,7 +177,8 @@ If you are contributing a new simulation application or library, the Governing C ### CMake -- CMake ≥ 3.18 features are acceptable. +- CMake ≥ 3.18 features are acceptable. Preset files may use features available + in CMake ≥ 3.21. - Use target-based linking (`target_link_libraries`, `target_include_directories`) rather than directory-level commands. --- diff --git a/README.md b/README.md index 852cac70e..35d123abb 100644 --- a/README.md +++ b/README.md @@ -26,7 +26,7 @@ python -m pip install "pyalps[plot]" ### Build from source -A native build requires CMake 3.18 or newer, a C++14 compiler, HDF5, and BLAS/LAPACK. MPI is enabled by default when available. The legacy Fortran interface is disabled by default. If a Boost source tree is not supplied, configuration downloads one and therefore requires network access. +A native build requires CMake 3.18 or newer, a C++14 compiler, HDF5, and BLAS/LAPACK. The bundled CMake presets require CMake 3.21 or newer. MPI is enabled by default when available. The legacy Fortran interface is disabled by default. If a Boost source tree is not supplied, configuration downloads one and therefore requires network access. Configure a release build with an explicit installation prefix, then build and install it: @@ -38,6 +38,13 @@ cmake --build _build/release --parallel cmake --install _build/release ``` +Alternatively, with CMake 3.21 or newer: + +```sh +cmake --preset default +cmake --build --preset default +``` + Add `-DALPS_ENABLE_MPI=OFF` to the configure command for a serial-only build. To build the legacy Fortran interface and its examples, add `-DALPS_BUILD_FORTRAN=ON`; this requires a Fortran compiler and the HDF5 Fortran component. Building the Python bindings from source is a separate step against an installed ALPS C++ SDK; see the [`pyalps` build instructions](bindings/python/pyalps/README.md). diff --git a/tutorials/alpsize-01-cmake/CMakeLists.txt b/tutorials/alpsize-01-cmake/CMakeLists.txt index 08a7f6bec..eddfdab20 100644 --- a/tutorials/alpsize-01-cmake/CMakeLists.txt +++ b/tutorials/alpsize-01-cmake/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 2.8 FATAL_ERROR) +cmake_minimum_required(VERSION 3.18) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-02-original-c/CMakeLists.txt b/tutorials/alpsize-02-original-c/CMakeLists.txt index 4f4b8a271..37b204a9f 100644 --- a/tutorials/alpsize-02-original-c/CMakeLists.txt +++ b/tutorials/alpsize-02-original-c/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 2.8 FATAL_ERROR) +cmake_minimum_required(VERSION 3.18) project(alpsize NONE) # enable C and C++ compilers diff --git a/tutorials/alpsize-03-basic-cpp/CMakeLists.txt b/tutorials/alpsize-03-basic-cpp/CMakeLists.txt index 406566506..f8896c49d 100644 --- a/tutorials/alpsize-03-basic-cpp/CMakeLists.txt +++ b/tutorials/alpsize-03-basic-cpp/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 2.8 FATAL_ERROR) +cmake_minimum_required(VERSION 3.18) project(alpsize NONE) # enable C and C++ compilers diff --git a/tutorials/alpsize-04-stl/CMakeLists.txt b/tutorials/alpsize-04-stl/CMakeLists.txt index 406566506..f8896c49d 100644 --- a/tutorials/alpsize-04-stl/CMakeLists.txt +++ b/tutorials/alpsize-04-stl/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 2.8 FATAL_ERROR) +cmake_minimum_required(VERSION 3.18) project(alpsize NONE) # enable C and C++ compilers diff --git a/tutorials/alpsize-05-boost/CMakeLists.txt b/tutorials/alpsize-05-boost/CMakeLists.txt index 461872150..f3d5ea1fa 100644 --- a/tutorials/alpsize-05-boost/CMakeLists.txt +++ b/tutorials/alpsize-05-boost/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 2.8 FATAL_ERROR) +cmake_minimum_required(VERSION 3.18) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-06-parameters/CMakeLists.txt b/tutorials/alpsize-06-parameters/CMakeLists.txt index 328b5703b..ae449f6b5 100644 --- a/tutorials/alpsize-06-parameters/CMakeLists.txt +++ b/tutorials/alpsize-06-parameters/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 2.8 FATAL_ERROR) +cmake_minimum_required(VERSION 3.18) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-07-alea/CMakeLists.txt b/tutorials/alpsize-07-alea/CMakeLists.txt index 328b5703b..ae449f6b5 100644 --- a/tutorials/alpsize-07-alea/CMakeLists.txt +++ b/tutorials/alpsize-07-alea/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 2.8 FATAL_ERROR) +cmake_minimum_required(VERSION 3.18) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-08-lattice/CMakeLists.txt b/tutorials/alpsize-08-lattice/CMakeLists.txt index ecf65578e..23c419577 100644 --- a/tutorials/alpsize-08-lattice/CMakeLists.txt +++ b/tutorials/alpsize-08-lattice/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 2.8 FATAL_ERROR) +cmake_minimum_required(VERSION 3.18) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-09-scheduler/CMakeLists.txt b/tutorials/alpsize-09-scheduler/CMakeLists.txt index cd9f8cc4e..6b1e8de07 100644 --- a/tutorials/alpsize-09-scheduler/CMakeLists.txt +++ b/tutorials/alpsize-09-scheduler/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 2.8 FATAL_ERROR) +cmake_minimum_required(VERSION 3.18) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-10-fortran-scheduler/CMakeLists.txt b/tutorials/alpsize-10-fortran-scheduler/CMakeLists.txt index 0fe965108..c32ad0ad3 100644 --- a/tutorials/alpsize-10-fortran-scheduler/CMakeLists.txt +++ b/tutorials/alpsize-10-fortran-scheduler/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 2.8 FATAL_ERROR) +cmake_minimum_required(VERSION 3.18) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-11-fortran-ising/CMakeLists.txt b/tutorials/alpsize-11-fortran-ising/CMakeLists.txt index 82950f8ba..78de7d796 100644 --- a/tutorials/alpsize-11-fortran-ising/CMakeLists.txt +++ b/tutorials/alpsize-11-fortran-ising/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 2.8 FATAL_ERROR) +cmake_minimum_required(VERSION 3.18) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/code-06-mcmain-c++/CMakeLists.txt b/tutorials/code-06-mcmain-c++/CMakeLists.txt index 10e3c8104..11055b87f 100644 --- a/tutorials/code-06-mcmain-c++/CMakeLists.txt +++ b/tutorials/code-06-mcmain-c++/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 2.8 FATAL_ERROR) +cmake_minimum_required(VERSION 3.18) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/code-07-mcmain-mcbase/CMakeLists.txt b/tutorials/code-07-mcmain-mcbase/CMakeLists.txt index 5dddd97e8..12ad7d69b 100644 --- a/tutorials/code-07-mcmain-mcbase/CMakeLists.txt +++ b/tutorials/code-07-mcmain-mcbase/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 2.8 FATAL_ERROR) +cmake_minimum_required(VERSION 3.18) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/code-07-mcmain-mcbase/heisenberg/1d_lattice/CMakeLists.txt b/tutorials/code-07-mcmain-mcbase/heisenberg/1d_lattice/CMakeLists.txt index 6546fbac7..1fc795c32 100644 --- a/tutorials/code-07-mcmain-mcbase/heisenberg/1d_lattice/CMakeLists.txt +++ b/tutorials/code-07-mcmain-mcbase/heisenberg/1d_lattice/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 2.8 FATAL_ERROR) +cmake_minimum_required(VERSION 3.18) project(heisenberg NONE) # find ALPS Library diff --git a/tutorials/code-07-mcmain-mcbase/heisenberg/nd_lattice/CMakeLists.txt b/tutorials/code-07-mcmain-mcbase/heisenberg/nd_lattice/CMakeLists.txt index 368003174..103997448 100644 --- a/tutorials/code-07-mcmain-mcbase/heisenberg/nd_lattice/CMakeLists.txt +++ b/tutorials/code-07-mcmain-mcbase/heisenberg/nd_lattice/CMakeLists.txt @@ -1,8 +1,6 @@ -cmake_minimum_required(VERSION 2.8 FATAL_ERROR) +cmake_minimum_required(VERSION 3.18) project(heisenberg NONE) -set(ALPS_ROOT_DIR /Users/ricoh/Applications/alps) - # find ALPS Library find_package(ALPS REQUIRED PATHS ${ALPS_ROOT_DIR} $ENV{ALPS_HOME} NO_SYSTEM_ENVIRONMENT_PATH) message(STATUS "Found ALPS: ${ALPS_ROOT_DIR} (revision: ${ALPS_VERSION})") diff --git a/tutorials/code-07-mcmain-mcbase/heisenberg/o_n_model/CMakeLists.txt b/tutorials/code-07-mcmain-mcbase/heisenberg/o_n_model/CMakeLists.txt index 584178bb0..4b5ea3948 100644 --- a/tutorials/code-07-mcmain-mcbase/heisenberg/o_n_model/CMakeLists.txt +++ b/tutorials/code-07-mcmain-mcbase/heisenberg/o_n_model/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 2.8 FATAL_ERROR) +cmake_minimum_required(VERSION 3.18) project(ndim_spin NONE) # find ALPS Library From 4b3399d79bb828b461609da4c95f274473849de6 Mon Sep 17 00:00:00 2001 From: Tobias Wolf Date: Fri, 24 Jul 2026 19:07:08 -0500 Subject: [PATCH 3/7] fix: stop version.h dropping zero-valued version components version.h.in declared ALPS_VERSION_MAJOR/MINOR/PATCH with cmakedefine, which emits "/* #undef NAME */" when the substituted value is false-y. CMake counts 0 as false-y, so any x.y.0 release generated a header with that component silently missing. 2.4.0 would have tripped it. Use a plain #define for every macro the build unconditionally sets. Keep cmakedefine only for ALPS_XML_ALTERNATE_DIR, which the build never sets and parser/xslt_path.C guards with #ifdef. Also add ALPS_VERSION_NUMBER/ALPS_VERSION_NUM() for preprocessor version comparisons (BOOST_VERSION packing), and drop two macros: ALPS_SVN_REVISION, which expanded a variable unset since the SVN migration and was always #undef, and ALPS_SRCDIR, which baked the build machine's source path into an installed header for one line of pconfig output. Refs #95 Co-Authored-By: Claude Opus 5 --- src/alps/version.h.in | 40 ++++++++++++++++++++++++++-------------- tool/pconfig.C | 1 - 2 files changed, 26 insertions(+), 15 deletions(-) diff --git a/src/alps/version.h.in b/src/alps/version.h.in index 6543db8b2..2035029e9 100644 --- a/src/alps/version.h.in +++ b/src/alps/version.h.in @@ -30,34 +30,46 @@ #ifndef ALPS_VERSION_H #define ALPS_VERSION_H +// Plain #define for everything the build always sets: the cmakedefine directive +// emits an "undef" when its value is false-y, and CMake counts 0 as false-y, so +// a zero component (2.4.0) would vanish. It is used below only where the macro +// is genuinely optional. (configure_file matches that directive even inside a +// comment, hence no leading '#' on it here.) + // ALPS version -#cmakedefine ALPS_VERSION "@ALPS_VERSION@" +#define ALPS_VERSION "@ALPS_VERSION@" + +#define ALPS_VERSION_MAJOR @ALPS_VERSION_MAJOR@ +#define ALPS_VERSION_MINOR @ALPS_VERSION_MINOR@ +#define ALPS_VERSION_PATCH @ALPS_VERSION_PATCH@ -#cmakedefine ALPS_VERSION_MAJOR @ALPS_VERSION_MAJOR@ -#cmakedefine ALPS_VERSION_MINOR @ALPS_VERSION_MINOR@ -#cmakedefine ALPS_VERSION_PATCH @ALPS_VERSION_PATCH@ -#cmakedefine ALPS_SVN_REVISION @ALPS_WC_REVISION@ +// ALPS version as a single integer, for preprocessor comparisons: +// #if ALPS_VERSION_NUMBER >= ALPS_VERSION_NUM(2, 3, 4) +#define ALPS_VERSION_NUM(major, minor, patch) \ + ((major) * 100000 + (minor) * 100 + (patch)) +#define ALPS_VERSION_NUMBER \ + ALPS_VERSION_NUM(ALPS_VERSION_MAJOR, ALPS_VERSION_MINOR, ALPS_VERSION_PATCH) // ALPS version (full string) -#cmakedefine ALPS_VERSION_STRING "@ALPS_VERSION_STRING@" +#define ALPS_VERSION_STRING "@ALPS_VERSION_STRING@" // latest publish year of ALPS -#cmakedefine ALPS_YEAR "@ALPS_YEAR@" +#define ALPS_YEAR "@ALPS_YEAR@" // install path of ALPS -#cmakedefine ALPS_PREFIX "@ALPS_PREFIX@" - -// source directory of ALPS -#cmakedefine ALPS_SRCDIR "@ALPS_SRCDIR@" +#define ALPS_PREFIX "@ALPS_PREFIX@" // XSLT PATH -#cmakedefine ALPS_XML_DIR "@ALPS_XML_DIR@" +#define ALPS_XML_DIR "@ALPS_XML_DIR@" + +// Optional Windows fallback for the 32/64-bit "Program Files" split. Never set +// by the build, and guarded by #ifdef in parser/xslt_path.C. #cmakedefine ALPS_XML_ALTERNATE_DIR "@ALPS_XML_ALTERNATE_DIR@" // hostname where configure script was executed -#cmakedefine ALPS_CONFIG_HOST "@ALPS_CONFIG_HOST@" +#define ALPS_CONFIG_HOST "@ALPS_CONFIG_HOST@" // username who executed configure script -#cmakedefine ALPS_CONFIG_USER "@ALPS_CONFIG_USER@" +#define ALPS_CONFIG_USER "@ALPS_CONFIG_USER@" #endif // ALPS_VERSION_H diff --git a/tool/pconfig.C b/tool/pconfig.C index 78eeefa3f..5f1787cdc 100644 --- a/tool/pconfig.C +++ b/tool/pconfig.C @@ -35,7 +35,6 @@ int main() { std::cout << "ALPS version: " << alps::version() << std::endl << "Boost version: " << BOOST_LIB_VERSION << std::endl - << "source directory: " << ALPS_SRCDIR << std::endl << "installed at: " << ALPS_PREFIX << std::endl << "configured on: " << alps::config_host() << std::endl << "configured by: " << alps::config_user() << std::endl From a03bfc3475e7408163846063e16c415d51bb7382 Mon Sep 17 00:00:00 2001 From: Tobias Wolf Date: Fri, 24 Jul 2026 19:29:49 -0500 Subject: [PATCH 4/7] build: single-source the ALPS version, add ALPSConfigVersion.cmake The version was hardcoded in CMakeLists.txt and had already drifted: CMake said 2.3.3, the newest tag is v2.3.4, and pyalps' pyproject.toml says 2.3.4b1. Put the numeric release in ALPS_VERSION.txt, read it in cmake/ALPSVersion.cmake before project(), and derive ALPS_VERSION_MAJOR/MINOR/PATCH from PROJECT_VERSION_*. The file holds MAJOR.MINOR.PATCH and nothing else, because project(VERSION) rejects non-numeric input and neither SOVERSION nor find_package() matching has any notion of prerelease ordering. A malformed file is rejected with a message naming the file, rather than CMake's bare "VERSION format invalid". Corrects the version to 2.3.4 in passing. ALPS_VERSION_BUILD, which was always empty, becomes the ALPS_VERSION_PRERELEASE cache variable: it carries "beta.2" into display strings while the numeric version stays clean. "Prerelease" because a later change adds real build metadata (a git hash), and two similarly-named slots would confuse. Generate and install ALPSConfigVersion.cmake. Without it find_package(ALPS ) accepted any version it found and silently discarded the constraint. SameMinorVersion: within 2.3.x a patch release is drop-in, a minor bump is not guaranteed to be. Note this is stricter than the SOVERSION of MAJOR alone advertises; reconciling the soname is a packaging-visible change and is left alone here. Derive ALPS_YEAR with string(TIMESTAMP), which honours SOURCE_DATE_EPOCH, so distro and conda reproducible builds still get a stable year. ALPS_SRCDIR is dropped from the installed header by the preceding commit, but two tests use it to locate reference .h5 inputs. Give those two targets a private compile definition instead: a build-tree path belongs there, not in an installed public header. Refs #95 Co-Authored-By: Claude Opus 5 --- ALPS_VERSION.txt | 1 + CMakeLists.txt | 53 ++++++++++++++++++++++++++----------- cmake/ALPSConfig.cmake.in | 7 +++-- cmake/ALPSVersion.cmake | 41 ++++++++++++++++++++++++++++ test/hdf5/CMakeLists.txt | 5 ++++ test/numeric/CMakeLists.txt | 7 +++++ 6 files changed, 97 insertions(+), 17 deletions(-) create mode 100644 ALPS_VERSION.txt create mode 100644 cmake/ALPSVersion.cmake diff --git a/ALPS_VERSION.txt b/ALPS_VERSION.txt new file mode 100644 index 000000000..3f684d2d9 --- /dev/null +++ b/ALPS_VERSION.txt @@ -0,0 +1 @@ +2.3.4 diff --git a/CMakeLists.txt b/CMakeLists.txt index 49c52dcca..c4513f28b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -83,13 +83,17 @@ if(ALPS_BUILD_LIBS_ONLY) set(ALPS_BUILD_APPLICATIONS OFF) endif() +# Sets ALPS_VERSION_CORE from ALPS_VERSION.txt. Included by full path because +# CMAKE_MODULE_PATH is not set up until after project(). +include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/ALPSVersion.cmake) + if(ALPS_BUILD_FORTRAN) - project(alps C CXX Fortran) + project(alps VERSION ${ALPS_VERSION_CORE} LANGUAGES C CXX Fortran) if (APPLE) set (CMAKE_Fortran_RUNTIME_LIBRARIES "-lgcc_s.1") endif(APPLE) else(ALPS_BUILD_FORTRAN) - project(alps C CXX) + project(alps VERSION ${ALPS_VERSION_CORE} LANGUAGES C CXX) endif(ALPS_BUILD_FORTRAN) set(CMAKE_CXX_STANDARD 14) @@ -135,25 +139,35 @@ endif (ALPS_BUILD_PYTHON) ###################################################################### # Version information ###################################################################### -set(ALPS_YEAR 2026) -set(ALPS_VERSION_MAJOR 2) -set(ALPS_VERSION_MINOR 3) -set(ALPS_VERSION_PATCH 3) -set(ALPS_VERSION_BUILD "") - -if(ALPS_VERSION_BUILD) - set(ALPS_VERSION "${ALPS_VERSION_MAJOR}.${ALPS_VERSION_MINOR}.${ALPS_VERSION_PATCH}-${ALPS_VERSION_BUILD}") -else(ALPS_VERSION_BUILD) - set(ALPS_VERSION "${ALPS_VERSION_MAJOR}.${ALPS_VERSION_MINOR}.${ALPS_VERSION_PATCH}") -endif(ALPS_VERSION_BUILD) +# The numeric components come from project() above, which took its version from +# ALPS_VERSION.txt. Do not hardcode them here. +set(ALPS_VERSION_MAJOR ${PROJECT_VERSION_MAJOR}) +set(ALPS_VERSION_MINOR ${PROJECT_VERSION_MINOR}) +set(ALPS_VERSION_PATCH ${PROJECT_VERSION_PATCH}) + +# Prerelease label, e.g. "beta.2" for the v2.3.4-beta.2 tag. Display only: it is +# deliberately kept out of the numeric version that drives SOVERSION and +# find_package() matching. Set by the release process, not checked in. +set(ALPS_VERSION_PRERELEASE "" CACHE STRING + "Prerelease label for this build, e.g. beta.2 (affects version strings only)") +mark_as_advanced(ALPS_VERSION_PRERELEASE) + +if(ALPS_VERSION_PRERELEASE) + set(ALPS_VERSION "${ALPS_VERSION_CORE}-${ALPS_VERSION_PRERELEASE}") +else() + set(ALPS_VERSION "${ALPS_VERSION_CORE}") +endif() set(ALPS_VERSION_STRING "ALPS Libraries version ${ALPS_VERSION}") -MESSAGE(STATUS "ALPS version: ${ALPS_VERSION}") +message(STATUS "ALPS version: ${ALPS_VERSION}") + +# Derived, never hardcoded. string(TIMESTAMP) honours SOURCE_DATE_EPOCH, so +# distro and conda reproducible builds still get a stable year. +string(TIMESTAMP ALPS_YEAR "%Y" UTC) set(ALPS_CONFIG_HOST unknown) set(ALPS_CONFIG_USER unknown) set(ALPS_PREFIX "${CMAKE_INSTALL_PREFIX}") -set(ALPS_SRCDIR "${CMAKE_SOURCE_DIR}") set(libdir "${CMAKE_INSTALL_PREFIX}/lib") set(bindir "${CMAKE_INSTALL_PREFIX}/bin") @@ -439,6 +453,14 @@ endif(PYTHON_LIBRARY) configure_file(cmake/ALPSConfig.cmake.in ${PROJECT_BINARY_DIR}/cmake/ALPSConfig.cmake @ONLY) configure_file(cmake/include.mk.in ${PROJECT_BINARY_DIR}/cmake/include.mk) +# Without this file find_package(ALPS ) accepts any version it finds +# and silently discards the constraint. SameMinorVersion: patch releases within +# a minor series are drop-in, a minor bump is not guaranteed to be. +include(CMakePackageConfigHelpers) +write_basic_package_version_file( + ${PROJECT_BINARY_DIR}/cmake/ALPSConfigVersion.cmake + COMPATIBILITY SameMinorVersion) + # installation ###################################################################### @@ -478,6 +500,7 @@ add_subdirectory(cmake) install(FILES cmake/UseALPS.cmake ${PROJECT_BINARY_DIR}/cmake/ALPSConfig.cmake + ${PROJECT_BINARY_DIR}/cmake/ALPSConfigVersion.cmake ${PROJECT_BINARY_DIR}/cmake/include.mk cmake/run_test.cmake cmake/run_test_mpi.cmake diff --git a/cmake/ALPSConfig.cmake.in b/cmake/ALPSConfig.cmake.in index 4436acd40..fdb794cd7 100644 --- a/cmake/ALPSConfig.cmake.in +++ b/cmake/ALPSConfig.cmake.in @@ -20,11 +20,14 @@ set(ALPS_LIBRARY_DIRS "@ALPS_LIBRARY_DIRS_CONFIG@") # of runtime binaries for each configuration type. set(ALPS_RUNTIME_LIBRARY_DIRS "@ALPS_RUNTIME_LIBRARY_DIRS_CONFIG@") -# The ALPS version number. +# The ALPS version number. ALPS_VERSION carries the prerelease label when there +# is one; ALPS_VERSION_CORE is always plain MAJOR.MINOR.PATCH and is what +# ALPSConfigVersion.cmake compares against. SET(ALPS_VERSION_MAJOR "@ALPS_VERSION_MAJOR@") SET(ALPS_VERSION_MINOR "@ALPS_VERSION_MINOR@") SET(ALPS_VERSION_PATCH "@ALPS_VERSION_PATCH@") -SET(ALPS_VERSION_BUILD "@ALPS_VERSION_BUILD@") +SET(ALPS_VERSION_PRERELEASE "@ALPS_VERSION_PRERELEASE@") +SET(ALPS_VERSION_CORE "@ALPS_VERSION_CORE@") SET(ALPS_VERSION "@ALPS_VERSION@") # The location of the UseALPS.cmake file. diff --git a/cmake/ALPSVersion.cmake b/cmake/ALPSVersion.cmake new file mode 100644 index 000000000..d14bb0fe9 --- /dev/null +++ b/cmake/ALPSVersion.cmake @@ -0,0 +1,41 @@ +# Copyright ALPS collaboration 2026. +# Distributed under the MIT licence; see LICENSE.txt. +# +# Single source of truth for the ALPS release version. +# +# ALPS_VERSION.txt holds the numeric release core (MAJOR.MINOR.PATCH) and +# nothing else. Two constraints force that: +# +# * project(VERSION ...) rejects anything non-numeric, so "2.4.0-beta.1" +# fails to configure. +# * find_package() version matching and the library SOVERSION have no notion +# of prerelease ordering. +# +# A prerelease label such as "beta.2" therefore lives in ALPS_VERSION_PRERELEASE +# (see the version block in the top-level CMakeLists.txt), where it affects the +# display string only -- never the numeric version used for ABI and +# find_package() decisions. +# +# This file is included by full path before project(), so it cannot rely on +# CMAKE_MODULE_PATH or PROJECT_SOURCE_DIR. + +set(_alps_version_file "${CMAKE_CURRENT_LIST_DIR}/../ALPS_VERSION.txt") + +if(NOT EXISTS "${_alps_version_file}") + message(FATAL_ERROR "Cannot read the ALPS version file: ${_alps_version_file}") +endif() + +file(STRINGS "${_alps_version_file}" ALPS_VERSION_CORE LIMIT_COUNT 1) +string(STRIP "${ALPS_VERSION_CORE}" ALPS_VERSION_CORE) + +# Fail loudly here rather than letting project() emit "VERSION format invalid", +# which gives no hint about which file is at fault. +if(NOT ALPS_VERSION_CORE MATCHES "^[0-9]+\\.[0-9]+\\.[0-9]+$") + message(FATAL_ERROR + "${_alps_version_file} must contain exactly MAJOR.MINOR.PATCH, but reads " + "'${ALPS_VERSION_CORE}'. Prerelease labels belong in " + "ALPS_VERSION_PRERELEASE, and the leading 'v' of a release tag is not " + "part of the version.") +endif() + +unset(_alps_version_file) diff --git a/test/hdf5/CMakeLists.txt b/test/hdf5/CMakeLists.txt index 54cd3f7dc..d6b24daae 100644 --- a/test/hdf5/CMakeLists.txt +++ b/test/hdf5/CMakeLists.txt @@ -38,6 +38,11 @@ FOREACH (name hdf5_complex hdf5_copy hdf5_real_complex_vec hdf5_real_complex_mat set_property(TEST ${name} PROPERTY LABELS hdf5) ENDFOREACH(name) +# Reads a reference .h5 file from the source tree; see the note in +# test/numeric/CMakeLists.txt. +target_compile_definitions(hdf5_fortran_string + PRIVATE ALPS_SRCDIR="${PROJECT_SOURCE_DIR}") + IF (ALPS_ENABLE_OPENMP AND OPENMP_FOUND) add_executable(hdf5_omp hdf5_omp.cpp) add_dependencies(hdf5_omp alps) diff --git a/test/numeric/CMakeLists.txt b/test/numeric/CMakeLists.txt index 32d13d304..41d9c5df8 100644 --- a/test/numeric/CMakeLists.txt +++ b/test/numeric/CMakeLists.txt @@ -30,5 +30,12 @@ if(LAPACK_FOUND) add_alps_test(${name}) set_property(TEST ${name} PROPERTY LABELS numeric) ENDFOREACH(name) + + # This test reads a reference .h5 file from the source tree. That path is a + # property of this build, not of the installed library, so it is a private + # definition on the one target that needs it rather than a macro in the + # installed alps/version.h. + target_compile_definitions(matrix_deprecated_hdf5_format_test + PRIVATE ALPS_SRCDIR="${PROJECT_SOURCE_DIR}") endif(LAPACK_FOUND) From d46a0af0604d0053e845b5bb1d0786623d97a1ec Mon Sep 17 00:00:00 2001 From: Tobias Wolf Date: Mon, 17 Aug 2026 15:07:19 -0500 Subject: [PATCH 5/7] docs: drop license disclaimer sentence from CITATION.md Co-Authored-By: Claude Fable 5 --- CITATION.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CITATION.md b/CITATION.md index 5d81cfa04..2f2ecf96c 100644 --- a/CITATION.md +++ b/CITATION.md @@ -1,6 +1,6 @@ # Citing ALPS -If ALPS contributes to published research, please cite the framework papers below and any method-specific paper relevant to the application you used. Citation is requested as scholarly acknowledgement; it is not a condition of the MIT license in [`LICENSE.txt`](LICENSE.txt). +If ALPS contributes to published research, please cite the framework papers below and any method-specific paper relevant to the application you used. ## Framework papers From 136584cb6e27ea8657144eeb63c97aba9b362102 Mon Sep 17 00:00:00 2001 From: Tobias Wolf Date: Tue, 18 Aug 2026 11:43:41 -0500 Subject: [PATCH 6/7] docs: address PR review feedback --- CITATION.md | 26 ++---------- CMakeLists.txt | 2 +- CONTRIBUTING.md | 9 ++-- README-py.md | 2 +- README.md | 41 +------------------ tutorials/alpsize-01-cmake/CMakeLists.txt | 2 +- .../alpsize-02-original-c/CMakeLists.txt | 2 +- tutorials/alpsize-03-basic-cpp/CMakeLists.txt | 2 +- tutorials/alpsize-04-stl/CMakeLists.txt | 2 +- tutorials/alpsize-05-boost/CMakeLists.txt | 2 +- .../alpsize-06-parameters/CMakeLists.txt | 2 +- tutorials/alpsize-07-alea/CMakeLists.txt | 2 +- tutorials/alpsize-08-lattice/CMakeLists.txt | 2 +- tutorials/alpsize-09-scheduler/CMakeLists.txt | 2 +- .../CMakeLists.txt | 2 +- .../alpsize-11-fortran-ising/CMakeLists.txt | 2 +- tutorials/code-06-mcmain-c++/CMakeLists.txt | 2 +- .../code-07-mcmain-mcbase/CMakeLists.txt | 2 +- .../heisenberg/1d_lattice/CMakeLists.txt | 2 +- .../heisenberg/nd_lattice/CMakeLists.txt | 2 +- .../heisenberg/o_n_model/CMakeLists.txt | 2 +- 21 files changed, 27 insertions(+), 85 deletions(-) diff --git a/CITATION.md b/CITATION.md index 2f2ecf96c..3fbfcf163 100644 --- a/CITATION.md +++ b/CITATION.md @@ -1,29 +1,11 @@ # Citing ALPS -If ALPS contributes to published research, please cite the framework papers below and any method-specific paper relevant to the application you used. +If ALPS contributes to published research, cite the latest framework paper below and any method-specific paper relevant to the application you used. -## Framework papers +## Framework paper -Please cite both ALPS framework papers: - -1. A. F. Albuquerque *et al.*, “The ALPS project release 1.3: Open-source software for strongly correlated systems,” *Journal of Magnetism and Magnetic Materials* **310**, 1187–1193 (2007). [doi:10.1016/j.jmmm.2006.10.304](https://doi.org/10.1016/j.jmmm.2006.10.304) -2. B. Bauer *et al.*, “The ALPS project release 2.0: Open source software for strongly correlated systems,” *Journal of Statistical Mechanics: Theory and Experiment* **2011**, P05001 (2011). [doi:10.1088/1742-5468/2011/05/P05001](https://doi.org/10.1088/1742-5468/2011/05/P05001) +B. Bauer *et al.*, “The ALPS project release 2.0: Open source software for strongly correlated systems,” *Journal of Statistical Mechanics: Theory and Experiment* **2011**, P05001 (2011). [doi:10.1088/1742-5468/2011/05/P05001](https://doi.org/10.1088/1742-5468/2011/05/P05001) ## Method-specific papers -Add the applicable paper from this table. Application names match directories or executables in this repository. - -| Application or component | Additional citation | -| --- | --- | -| `applications/qmc/looper` (`loop`, `loop_mpi`) | S. Todo and K. Kato, “Cluster Algorithms for General-S Quantum Spin Systems,” *Physical Review Letters* **87**, 047203 (2001). [doi:10.1103/PhysRevLett.87.047203](https://doi.org/10.1103/PhysRevLett.87.047203) | -| `applications/qmc/qwl` | M. Troyer, S. Wessel, and F. Alet, “Flat Histogram Methods for Quantum Systems,” *Physical Review Letters* **90**, 120201 (2003). [doi:10.1103/PhysRevLett.90.120201](https://doi.org/10.1103/PhysRevLett.90.120201) | -| Continuous-time QMC impurity solvers and the DMFT framework | E. Gull, P. Werner, S. Fuchs, B. Surer, T. Pruschke, and M. Troyer, “Continuous-time quantum Monte Carlo impurity solvers,” *Computer Physics Communications* **182**, 1078–1082 (2011). [doi:10.1016/j.cpc.2010.12.050](https://doi.org/10.1016/j.cpc.2010.12.050) | -| DMRG/MPS applications | M. Dolfi *et al.*, “Matrix product state applications for the ALPS project,” *Computer Physics Communications* **185**, 3430–3440 (2014). [doi:10.1016/j.cpc.2014.08.019](https://doi.org/10.1016/j.cpc.2014.08.019) | - -The framework papers are sufficient for `sse`, `spinmc`, `fulldiag`, `sparsediag`, and `worm` unless a publication describes a more specific algorithmic reference. For specialized models or algorithms, also cite the primary scientific source on which the calculation is based. - -## Citation metadata - -Use the DOI links above to obtain current BibTeX, RIS, or other citation metadata from the publishers. This avoids maintaining duplicate hand-written records that can drift from the authoritative metadata. - -When describing reproducibility, also record the ALPS release or Git commit used in the calculation. +The maintained list of implementation and algorithm papers for individual ALPS applications is available on the [ALPS documentation website](https://alps.comp-phys.org/documentation/pubs/refs/). diff --git a/CMakeLists.txt b/CMakeLists.txt index c4513f28b..4463ff351 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -17,7 +17,7 @@ # FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER # DEALINGS IN THE SOFTWARE. -cmake_minimum_required(VERSION 3.18.0) +cmake_minimum_required(VERSION 3.21) if(${CMAKE_SOURCE_DIR} STREQUAL ${CMAKE_BINARY_DIR}) message(FATAL_ERROR "In-source builds not allowed. Please make a new directory (called a build directory) and run CMake from there. You may need to remove CMakeCache.txt.") diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 3fd052873..3fb93add7 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -50,13 +50,13 @@ Before opening a new issue, please search existing issues to avoid duplicates. ### Prerequisites -- CMake ≥ 3.18 for normal configuration; CMake ≥ 3.21 for presets +- CMake ≥ 3.21 - A C++17-capable compiler (GCC, Clang, Intel, or Fujitsu) - Boost (downloaded automatically during configuration; or use a system install with `-DALPS_USE_SYSTEM_BOOST=ON`) - For Fortran bindings: gfortran (or compatible Fortran compiler) - For Python bindings: Python ≥ 3.10, plus `numpy` and `scipy` -See the [installation page](https://alps.comp-phys.org/documentation/install/) for full platform-specific instructions. +See the [installation page](https://alps.comp-phys.org/install/) for full platform-specific instructions. ### Fork and clone @@ -79,7 +79,7 @@ cmake .. -DCMAKE_BUILD_TYPE=Release make -j$(nproc) ``` -Alternatively, use the bundled CMake preset (requires CMake ≥ 3.21): +Alternatively, use the bundled CMake preset: ```bash cmake --preset default cmake --build --preset default @@ -177,8 +177,7 @@ If you are contributing a new simulation application or library, the Governing C ### CMake -- CMake ≥ 3.18 features are acceptable. Preset files may use features available - in CMake ≥ 3.21. +- CMake ≥ 3.21 features are acceptable. - Use target-based linking (`target_link_libraries`, `target_include_directories`) rather than directory-level commands. --- diff --git a/README-py.md b/README-py.md index 4bd2da976..7ef7351c6 100644 --- a/README-py.md +++ b/README-py.md @@ -16,7 +16,7 @@ pip install pyalps ### Installation instruction from sources 1. Prerequisites - - CMake > 3.18 + - CMake >= 3.21 - Boost sources >= 1.76 - BLAS/LAPACK - HDF5 diff --git a/README.md b/README.md index 35d123abb..c4eee2653 100644 --- a/README.md +++ b/README.md @@ -10,46 +10,7 @@ The ALPS software package aims to provide a set of well tested, robust, and stan ## Installation -### Python - -Binary `pyalps` wheels are available for supported Linux and macOS systems: - -```sh -python -m pip install pyalps -``` - -Plotting with `pyalps` requires Matplotlib, which can be installed together with the package: - -```sh -python -m pip install "pyalps[plot]" -``` - -### Build from source - -A native build requires CMake 3.18 or newer, a C++14 compiler, HDF5, and BLAS/LAPACK. The bundled CMake presets require CMake 3.21 or newer. MPI is enabled by default when available. The legacy Fortran interface is disabled by default. If a Boost source tree is not supplied, configuration downloads one and therefore requires network access. - -Configure a release build with an explicit installation prefix, then build and install it: - -```sh -cmake -S . -B _build/release \ - -DCMAKE_BUILD_TYPE=Release \ - -DCMAKE_INSTALL_PREFIX=/path/to/alps -cmake --build _build/release --parallel -cmake --install _build/release -``` - -Alternatively, with CMake 3.21 or newer: - -```sh -cmake --preset default -cmake --build --preset default -``` - -Add `-DALPS_ENABLE_MPI=OFF` to the configure command for a serial-only build. To build the legacy Fortran interface and its examples, add `-DALPS_BUILD_FORTRAN=ON`; this requires a Fortran compiler and the HDF5 Fortran component. - -Building the Python bindings from source is a separate step against an installed ALPS C++ SDK; see the [`pyalps` build instructions](bindings/python/pyalps/README.md). - -Platform-specific binary, source, and Spack instructions are available on the [ALPS installation website](https://alps.comp-phys.org/documentation/install/). +For current binary, source, and Spack installation instructions, see the [ALPS installation website](https://alps.comp-phys.org/install/). ## Contributing diff --git a/tutorials/alpsize-01-cmake/CMakeLists.txt b/tutorials/alpsize-01-cmake/CMakeLists.txt index eddfdab20..b5f6a349c 100644 --- a/tutorials/alpsize-01-cmake/CMakeLists.txt +++ b/tutorials/alpsize-01-cmake/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.18) +cmake_minimum_required(VERSION 3.21) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-02-original-c/CMakeLists.txt b/tutorials/alpsize-02-original-c/CMakeLists.txt index 37b204a9f..4470f1ea4 100644 --- a/tutorials/alpsize-02-original-c/CMakeLists.txt +++ b/tutorials/alpsize-02-original-c/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.18) +cmake_minimum_required(VERSION 3.21) project(alpsize NONE) # enable C and C++ compilers diff --git a/tutorials/alpsize-03-basic-cpp/CMakeLists.txt b/tutorials/alpsize-03-basic-cpp/CMakeLists.txt index f8896c49d..1ebc80f4d 100644 --- a/tutorials/alpsize-03-basic-cpp/CMakeLists.txt +++ b/tutorials/alpsize-03-basic-cpp/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.18) +cmake_minimum_required(VERSION 3.21) project(alpsize NONE) # enable C and C++ compilers diff --git a/tutorials/alpsize-04-stl/CMakeLists.txt b/tutorials/alpsize-04-stl/CMakeLists.txt index f8896c49d..1ebc80f4d 100644 --- a/tutorials/alpsize-04-stl/CMakeLists.txt +++ b/tutorials/alpsize-04-stl/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.18) +cmake_minimum_required(VERSION 3.21) project(alpsize NONE) # enable C and C++ compilers diff --git a/tutorials/alpsize-05-boost/CMakeLists.txt b/tutorials/alpsize-05-boost/CMakeLists.txt index f3d5ea1fa..cdd7214a5 100644 --- a/tutorials/alpsize-05-boost/CMakeLists.txt +++ b/tutorials/alpsize-05-boost/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.18) +cmake_minimum_required(VERSION 3.21) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-06-parameters/CMakeLists.txt b/tutorials/alpsize-06-parameters/CMakeLists.txt index ae449f6b5..9500a5d21 100644 --- a/tutorials/alpsize-06-parameters/CMakeLists.txt +++ b/tutorials/alpsize-06-parameters/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.18) +cmake_minimum_required(VERSION 3.21) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-07-alea/CMakeLists.txt b/tutorials/alpsize-07-alea/CMakeLists.txt index ae449f6b5..9500a5d21 100644 --- a/tutorials/alpsize-07-alea/CMakeLists.txt +++ b/tutorials/alpsize-07-alea/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.18) +cmake_minimum_required(VERSION 3.21) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-08-lattice/CMakeLists.txt b/tutorials/alpsize-08-lattice/CMakeLists.txt index 23c419577..41ff9424f 100644 --- a/tutorials/alpsize-08-lattice/CMakeLists.txt +++ b/tutorials/alpsize-08-lattice/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.18) +cmake_minimum_required(VERSION 3.21) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-09-scheduler/CMakeLists.txt b/tutorials/alpsize-09-scheduler/CMakeLists.txt index 6b1e8de07..ae527fde9 100644 --- a/tutorials/alpsize-09-scheduler/CMakeLists.txt +++ b/tutorials/alpsize-09-scheduler/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.18) +cmake_minimum_required(VERSION 3.21) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-10-fortran-scheduler/CMakeLists.txt b/tutorials/alpsize-10-fortran-scheduler/CMakeLists.txt index c32ad0ad3..25aa9e4c0 100644 --- a/tutorials/alpsize-10-fortran-scheduler/CMakeLists.txt +++ b/tutorials/alpsize-10-fortran-scheduler/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.18) +cmake_minimum_required(VERSION 3.21) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-11-fortran-ising/CMakeLists.txt b/tutorials/alpsize-11-fortran-ising/CMakeLists.txt index 78de7d796..97b7f8022 100644 --- a/tutorials/alpsize-11-fortran-ising/CMakeLists.txt +++ b/tutorials/alpsize-11-fortran-ising/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.18) +cmake_minimum_required(VERSION 3.21) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/code-06-mcmain-c++/CMakeLists.txt b/tutorials/code-06-mcmain-c++/CMakeLists.txt index 11055b87f..f8128411a 100644 --- a/tutorials/code-06-mcmain-c++/CMakeLists.txt +++ b/tutorials/code-06-mcmain-c++/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.18) +cmake_minimum_required(VERSION 3.21) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/code-07-mcmain-mcbase/CMakeLists.txt b/tutorials/code-07-mcmain-mcbase/CMakeLists.txt index 12ad7d69b..a9ad07fa1 100644 --- a/tutorials/code-07-mcmain-mcbase/CMakeLists.txt +++ b/tutorials/code-07-mcmain-mcbase/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.18) +cmake_minimum_required(VERSION 3.21) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/code-07-mcmain-mcbase/heisenberg/1d_lattice/CMakeLists.txt b/tutorials/code-07-mcmain-mcbase/heisenberg/1d_lattice/CMakeLists.txt index 1fc795c32..779802067 100644 --- a/tutorials/code-07-mcmain-mcbase/heisenberg/1d_lattice/CMakeLists.txt +++ b/tutorials/code-07-mcmain-mcbase/heisenberg/1d_lattice/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.18) +cmake_minimum_required(VERSION 3.21) project(heisenberg NONE) # find ALPS Library diff --git a/tutorials/code-07-mcmain-mcbase/heisenberg/nd_lattice/CMakeLists.txt b/tutorials/code-07-mcmain-mcbase/heisenberg/nd_lattice/CMakeLists.txt index 103997448..adb42a53f 100644 --- a/tutorials/code-07-mcmain-mcbase/heisenberg/nd_lattice/CMakeLists.txt +++ b/tutorials/code-07-mcmain-mcbase/heisenberg/nd_lattice/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.18) +cmake_minimum_required(VERSION 3.21) project(heisenberg NONE) # find ALPS Library diff --git a/tutorials/code-07-mcmain-mcbase/heisenberg/o_n_model/CMakeLists.txt b/tutorials/code-07-mcmain-mcbase/heisenberg/o_n_model/CMakeLists.txt index 4b5ea3948..4ed469b92 100644 --- a/tutorials/code-07-mcmain-mcbase/heisenberg/o_n_model/CMakeLists.txt +++ b/tutorials/code-07-mcmain-mcbase/heisenberg/o_n_model/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.18) +cmake_minimum_required(VERSION 3.21) project(ndim_spin NONE) # find ALPS Library From 11248c6a15e8b9acdf9e5ea222f42be3b4f9ad30 Mon Sep 17 00:00:00 2001 From: Tobias Wolf Date: Tue, 18 Aug 2026 16:24:42 -0500 Subject: [PATCH 7/7] build: raise CMake minimum to 3.22 3.21 was chosen as the CMakePresets v3 schema floor, but no supported distro ships exactly 3.21, so that floor is never exercised. 3.22 is what Ubuntu 22.04 (the oldest CI platform) ships, making the declared minimum one that CI actually builds with. RHEL 9 (3.31) and Debian 12 (3.25) are unaffected. Co-Authored-By: Claude Fable 5 --- CMakeLists.txt | 2 +- CMakePresets.json | 2 +- CONTRIBUTING.md | 4 ++-- README-py.md | 2 +- tutorials/alpsize-01-cmake/CMakeLists.txt | 2 +- tutorials/alpsize-02-original-c/CMakeLists.txt | 2 +- tutorials/alpsize-03-basic-cpp/CMakeLists.txt | 2 +- tutorials/alpsize-04-stl/CMakeLists.txt | 2 +- tutorials/alpsize-05-boost/CMakeLists.txt | 2 +- tutorials/alpsize-06-parameters/CMakeLists.txt | 2 +- tutorials/alpsize-07-alea/CMakeLists.txt | 2 +- tutorials/alpsize-08-lattice/CMakeLists.txt | 2 +- tutorials/alpsize-09-scheduler/CMakeLists.txt | 2 +- tutorials/alpsize-10-fortran-scheduler/CMakeLists.txt | 2 +- tutorials/alpsize-11-fortran-ising/CMakeLists.txt | 2 +- tutorials/code-06-mcmain-c++/CMakeLists.txt | 2 +- tutorials/code-07-mcmain-mcbase/CMakeLists.txt | 2 +- .../heisenberg/1d_lattice/CMakeLists.txt | 2 +- .../heisenberg/nd_lattice/CMakeLists.txt | 2 +- .../code-07-mcmain-mcbase/heisenberg/o_n_model/CMakeLists.txt | 2 +- 20 files changed, 21 insertions(+), 21 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 4463ff351..31d47fc5f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -17,7 +17,7 @@ # FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER # DEALINGS IN THE SOFTWARE. -cmake_minimum_required(VERSION 3.21) +cmake_minimum_required(VERSION 3.22) if(${CMAKE_SOURCE_DIR} STREQUAL ${CMAKE_BINARY_DIR}) message(FATAL_ERROR "In-source builds not allowed. Please make a new directory (called a build directory) and run CMake from there. You may need to remove CMakeCache.txt.") diff --git a/CMakePresets.json b/CMakePresets.json index 693c0c554..512f514ea 100644 --- a/CMakePresets.json +++ b/CMakePresets.json @@ -2,7 +2,7 @@ "version": 3, "cmakeMinimumRequired": { "major": 3, - "minor": 21, + "minor": 22, "patch": 0 }, "configurePresets": [ diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 3fb93add7..d7f1a1636 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -50,7 +50,7 @@ Before opening a new issue, please search existing issues to avoid duplicates. ### Prerequisites -- CMake ≥ 3.21 +- CMake ≥ 3.22 - A C++17-capable compiler (GCC, Clang, Intel, or Fujitsu) - Boost (downloaded automatically during configuration; or use a system install with `-DALPS_USE_SYSTEM_BOOST=ON`) - For Fortran bindings: gfortran (or compatible Fortran compiler) @@ -177,7 +177,7 @@ If you are contributing a new simulation application or library, the Governing C ### CMake -- CMake ≥ 3.21 features are acceptable. +- CMake ≥ 3.22 features are acceptable. - Use target-based linking (`target_link_libraries`, `target_include_directories`) rather than directory-level commands. --- diff --git a/README-py.md b/README-py.md index 7ef7351c6..25cf9467d 100644 --- a/README-py.md +++ b/README-py.md @@ -16,7 +16,7 @@ pip install pyalps ### Installation instruction from sources 1. Prerequisites - - CMake >= 3.21 + - CMake >= 3.22 - Boost sources >= 1.76 - BLAS/LAPACK - HDF5 diff --git a/tutorials/alpsize-01-cmake/CMakeLists.txt b/tutorials/alpsize-01-cmake/CMakeLists.txt index b5f6a349c..c88de950d 100644 --- a/tutorials/alpsize-01-cmake/CMakeLists.txt +++ b/tutorials/alpsize-01-cmake/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.21) +cmake_minimum_required(VERSION 3.22) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-02-original-c/CMakeLists.txt b/tutorials/alpsize-02-original-c/CMakeLists.txt index 4470f1ea4..bd133b065 100644 --- a/tutorials/alpsize-02-original-c/CMakeLists.txt +++ b/tutorials/alpsize-02-original-c/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.21) +cmake_minimum_required(VERSION 3.22) project(alpsize NONE) # enable C and C++ compilers diff --git a/tutorials/alpsize-03-basic-cpp/CMakeLists.txt b/tutorials/alpsize-03-basic-cpp/CMakeLists.txt index 1ebc80f4d..da0773fcb 100644 --- a/tutorials/alpsize-03-basic-cpp/CMakeLists.txt +++ b/tutorials/alpsize-03-basic-cpp/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.21) +cmake_minimum_required(VERSION 3.22) project(alpsize NONE) # enable C and C++ compilers diff --git a/tutorials/alpsize-04-stl/CMakeLists.txt b/tutorials/alpsize-04-stl/CMakeLists.txt index 1ebc80f4d..da0773fcb 100644 --- a/tutorials/alpsize-04-stl/CMakeLists.txt +++ b/tutorials/alpsize-04-stl/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.21) +cmake_minimum_required(VERSION 3.22) project(alpsize NONE) # enable C and C++ compilers diff --git a/tutorials/alpsize-05-boost/CMakeLists.txt b/tutorials/alpsize-05-boost/CMakeLists.txt index cdd7214a5..572fb6c00 100644 --- a/tutorials/alpsize-05-boost/CMakeLists.txt +++ b/tutorials/alpsize-05-boost/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.21) +cmake_minimum_required(VERSION 3.22) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-06-parameters/CMakeLists.txt b/tutorials/alpsize-06-parameters/CMakeLists.txt index 9500a5d21..0d59f06a7 100644 --- a/tutorials/alpsize-06-parameters/CMakeLists.txt +++ b/tutorials/alpsize-06-parameters/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.21) +cmake_minimum_required(VERSION 3.22) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-07-alea/CMakeLists.txt b/tutorials/alpsize-07-alea/CMakeLists.txt index 9500a5d21..0d59f06a7 100644 --- a/tutorials/alpsize-07-alea/CMakeLists.txt +++ b/tutorials/alpsize-07-alea/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.21) +cmake_minimum_required(VERSION 3.22) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-08-lattice/CMakeLists.txt b/tutorials/alpsize-08-lattice/CMakeLists.txt index 41ff9424f..51c07e9b9 100644 --- a/tutorials/alpsize-08-lattice/CMakeLists.txt +++ b/tutorials/alpsize-08-lattice/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.21) +cmake_minimum_required(VERSION 3.22) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-09-scheduler/CMakeLists.txt b/tutorials/alpsize-09-scheduler/CMakeLists.txt index ae527fde9..ea503b5cd 100644 --- a/tutorials/alpsize-09-scheduler/CMakeLists.txt +++ b/tutorials/alpsize-09-scheduler/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.21) +cmake_minimum_required(VERSION 3.22) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-10-fortran-scheduler/CMakeLists.txt b/tutorials/alpsize-10-fortran-scheduler/CMakeLists.txt index 25aa9e4c0..b68a64f4f 100644 --- a/tutorials/alpsize-10-fortran-scheduler/CMakeLists.txt +++ b/tutorials/alpsize-10-fortran-scheduler/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.21) +cmake_minimum_required(VERSION 3.22) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/alpsize-11-fortran-ising/CMakeLists.txt b/tutorials/alpsize-11-fortran-ising/CMakeLists.txt index 97b7f8022..c2e2dcc69 100644 --- a/tutorials/alpsize-11-fortran-ising/CMakeLists.txt +++ b/tutorials/alpsize-11-fortran-ising/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.21) +cmake_minimum_required(VERSION 3.22) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/code-06-mcmain-c++/CMakeLists.txt b/tutorials/code-06-mcmain-c++/CMakeLists.txt index f8128411a..3c2cc0c8e 100644 --- a/tutorials/code-06-mcmain-c++/CMakeLists.txt +++ b/tutorials/code-06-mcmain-c++/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.21) +cmake_minimum_required(VERSION 3.22) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/code-07-mcmain-mcbase/CMakeLists.txt b/tutorials/code-07-mcmain-mcbase/CMakeLists.txt index a9ad07fa1..1de3e807f 100644 --- a/tutorials/code-07-mcmain-mcbase/CMakeLists.txt +++ b/tutorials/code-07-mcmain-mcbase/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.21) +cmake_minimum_required(VERSION 3.22) project(alpsize NONE) # find ALPS Library diff --git a/tutorials/code-07-mcmain-mcbase/heisenberg/1d_lattice/CMakeLists.txt b/tutorials/code-07-mcmain-mcbase/heisenberg/1d_lattice/CMakeLists.txt index 779802067..54fc1ec20 100644 --- a/tutorials/code-07-mcmain-mcbase/heisenberg/1d_lattice/CMakeLists.txt +++ b/tutorials/code-07-mcmain-mcbase/heisenberg/1d_lattice/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.21) +cmake_minimum_required(VERSION 3.22) project(heisenberg NONE) # find ALPS Library diff --git a/tutorials/code-07-mcmain-mcbase/heisenberg/nd_lattice/CMakeLists.txt b/tutorials/code-07-mcmain-mcbase/heisenberg/nd_lattice/CMakeLists.txt index adb42a53f..3d8641b39 100644 --- a/tutorials/code-07-mcmain-mcbase/heisenberg/nd_lattice/CMakeLists.txt +++ b/tutorials/code-07-mcmain-mcbase/heisenberg/nd_lattice/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.21) +cmake_minimum_required(VERSION 3.22) project(heisenberg NONE) # find ALPS Library diff --git a/tutorials/code-07-mcmain-mcbase/heisenberg/o_n_model/CMakeLists.txt b/tutorials/code-07-mcmain-mcbase/heisenberg/o_n_model/CMakeLists.txt index 4ed469b92..c76d63126 100644 --- a/tutorials/code-07-mcmain-mcbase/heisenberg/o_n_model/CMakeLists.txt +++ b/tutorials/code-07-mcmain-mcbase/heisenberg/o_n_model/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.21) +cmake_minimum_required(VERSION 3.22) project(ndim_spin NONE) # find ALPS Library