Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve handling of LAMMPS integer size defines in library.h #1792

merged 2 commits into from Dec 2, 2019


Copy link

akohlmey commented Nov 29, 2019


When including library.h when using the LAMMPS library interface, we need to set one of -DLAMMPS_BIGBIG, -DLAMMPS_SMALLBIG, or -DLAMMPS_SMALLSMALL. This should be the same as was used when compiling the library interface, but until we generate a file lmpconfig.h (similar to how we use lmpgitversion.h) that contains this information and include it, we have to depend on the user setting the correct value. For now we assume -DLAMMPS_SMALLBIG if no define is set by the user.

This PR also changes the incorrect use of #elif that was recently added.

Related Issues

Fixes #1791


Axel Kohlmeyer (Temple U)


By submitting this pull request, I agree, that my contribution will be included in LAMMPS and redistributed under either the GNU General Public License version 2 (GPL v2) or the GNU Lesser General Public License version 2.1 (LGPL v2.1).

Post Submission Checklist

  • The feature or features in this pull request is complete
  • Licensing information is complete
  • Corresponding author information is complete
  • The source code follows the LAMMPS formatting guidelines
  • The feature has been verified to work with the conventional build system
  • The feature has been verified to work with the CMake based build system
… check
…e is set
sjplimp approved these changes Dec 2, 2019
@rbberger rbberger merged commit 1d92840 into lammps:master Dec 2, 2019
6 checks passed
6 checks passed
lammps/pull-requests/cmake/cmake-kokkos-omp-pr head run ended
lammps/pull-requests/cmake/cmake-serial-pr head run ended
lammps/pull-requests/kokkos-omp-pr head run ended
lammps/pull-requests/openmpi-pr head run ended
lammps/pull-requests/serial-pr head run ended
lammps/pull-requests/shlib-pr head run ended
@akohlmey akohlmey deleted the akohlmey:library-define-fix branch Jan 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
3 participants
You can’t perform that action at this time.