From 9ed6d0a9d1bb1c385d079e3b3c231176a6662cf6 Mon Sep 17 00:00:00 2001 From: Christoph Junghans <junghans@lanl.gov> Date: Fri, 24 Aug 2018 15:27:15 -0600 Subject: [PATCH] cmake: sort package in header --- cmake/CMakeLists.txt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cmake/CMakeLists.txt b/cmake/CMakeLists.txt index 460d177c92..c684c9df23 100644 --- a/cmake/CMakeLists.txt +++ b/cmake/CMakeLists.txt @@ -1008,7 +1008,9 @@ include_directories(${LAMMPS_STYLE_HEADERS_DIR}) ###################################### set(temp "#ifndef LMP_INSTALLED_PKGS_H\n#define LMP_INSTALLED_PKGS_H\n") set(temp "${temp}const char * LAMMPS_NS::LAMMPS::installed_packages[] = {\n") -foreach(PKG ${DEFAULT_PACKAGES} ${ACCEL_PACKAGES} ${OTHER_PACKAGES}) +set(temp_PKG_LIST ${DEFAULT_PACKAGES} ${ACCEL_PACKAGES} ${OTHER_PACKAGES}) +list(SORT temp_PKG_LIST) +foreach(PKG ${temp_PKG_LIST}) if(PKG_${PKG}) set(temp "${temp} \"${PKG}\",\n") endif() -- GitLab