Merge pull request #2069 from junghans/latte_v1.2.2

latte: bump to v1.2.2
This commit is contained in:
Axel Kohlmeyer 2020-05-07 14:27:19 -04:00 committed by GitHub
commit 3b77546eb9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 9 additions and 39 deletions

View File

@ -1,27 +0,0 @@
# - Find latte
# Find the native LATTE libraries.
#
# LATTE_LIBRARIES - List of libraries when using latte.
# LATTE_FOUND - True if latte found.
#
find_library(LATTE_LIBRARY NAMES latte)
include(FindPackageHandleStandardArgs)
# handle the QUIETLY and REQUIRED arguments and set LATTE_FOUND to TRUE
# if all listed variables are TRUE
find_package_handle_standard_args(LATTE DEFAULT_MSG LATTE_LIBRARY)
# Copy the results to the output variables and target.
if(LATTE_FOUND)
set(LATTE_LIBRARIES ${LATTE_LIBRARY})
if(NOT TARGET LATTE::latte)
add_library(LATTE::latte UNKNOWN IMPORTED)
set_target_properties(LATTE::latte PROPERTIES
IMPORTED_LOCATION "${LATTE_LIBRARY}")
endif()
endif()
mark_as_advanced(LATTE_LIBRARY)

View File

@ -6,7 +6,7 @@ if(TARGET LATTE::latte)
return()
endif()
find_package(LATTE)
find_package(LATTE 1.2.2 CONFIG)
if(LATTE_FOUND)
set(DOWNLOAD_LATTE_DEFAULT OFF)
else()
@ -17,8 +17,8 @@ if(DOWNLOAD_LATTE)
message(STATUS "LATTE download requested - we will build our own")
include(ExternalProject)
ExternalProject_Add(latte_build
URL https://github.com/lanl/LATTE/archive/v1.2.1.tar.gz
URL_MD5 85ac414fdada2d04619c8f936344df14
URL https://github.com/lanl/LATTE/archive/v1.2.2.tar.gz
URL_MD5 820e73a457ced178c08c71389a385de7
SOURCE_SUBDIR cmake
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=<INSTALL_DIR> ${CMAKE_REQUEST_PIC} -DCMAKE_INSTALL_LIBDIR=lib
-DBLAS_LIBRARIES=${BLAS_LIBRARIES} -DLAPACK_LIBRARIES=${LAPACK_LIBRARIES}
@ -35,10 +35,6 @@ if(DOWNLOAD_LATTE)
target_link_libraries(lammps PRIVATE LAMMPS::LATTE)
add_dependencies(LAMMPS::LATTE latte_build)
else()
find_package(LATTE)
if(NOT LATTE_FOUND)
message(FATAL_ERROR "LATTE library not found, help CMake to find it by setting LATTE_LIBRARY, or set DOWNLOAD_LATTE=ON to download it")
endif()
# latte needs lapack
target_link_libraries(lammps PRIVATE LATTE::latte ${LAPACK_LIBRARIES})
find_package(LATTE 1.2.2 REQUIRED CONFIG)
target_link_libraries(lammps PRIVATE LATTE::latte)
endif()

View File

@ -17,7 +17,7 @@ parser = ArgumentParser(prog='Install.py',
# settings
version = '1.2.1'
version = '1.2.2'
suffix = 'gfortran'
# known checksums for different LATTE versions. used to validate the download.
@ -25,6 +25,7 @@ checksums = { \
'1.1.0' : '533635721ee222d0ed2925a18fb5b294', \
'1.2.0' : '68bf0db879da5e068a71281020239ae7', \
'1.2.1' : '85ac414fdada2d04619c8f936344df14', \
'1.2.2' : '820e73a457ced178c08c71389a385de7', \
}
# help message
@ -33,12 +34,12 @@ HELP = """
Syntax from src dir: make lib-latte args="-b"
or: make lib-latte args="-p /usr/local/latte"
or: make lib-latte args="-m gfortran"
or: make lib-latte args="-b -v 1.2.1"
or: make lib-latte args="-b -v 1.2.2"
Syntax from lib dir: python Install.py -b
or: python Install.py -p /usr/local/latte
or: python Install.py -m gfortran
or: python Install.py -v 1.2.1 -b
or: python Install.py -v 1.2.2 -b
Example: