Skip to content

Commit

Permalink
Merge pull request #2765 from easybuilders/ocaisa-patch-1
Browse files Browse the repository at this point in the history
make `$LD_LIBRARY_PATH` detection more robust for LAMMPS
  • Loading branch information
boegel authored Aug 29, 2022
2 parents 10f9021 + aa6e335 commit 840fe7c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions easybuild/easyblocks/l/lammps.py
Original file line number Diff line number Diff line change
Expand Up @@ -454,9 +454,9 @@ def sanity_check_step(self, *args, **kwargs):
# Requires liblammps.so to be findable by the runtime linker (which it might not be if using
# rpath and filtering out LD_LIBRARY_PATH)
set_ld_library_path = ''
if 'LD_LIBRARY_PATH' not in os.environ:
if self.installdir not in os.getenv('LD_LIBRARY_PATH', default=''):
# Use LIBRARY_PATH to set it
set_ld_library_path = "LD_LIBRARY_PATH=$LIBRARY_PATH "
set_ld_library_path = "LD_LIBRARY_PATH=$LIBRARY_PATH:$LD_LIBRARY_PATH "
custom_commands = ["cd %s && " % execution_dir + set_ld_library_path + cmd for cmd in custom_commands]

shlib_ext = get_shared_lib_ext()
Expand Down

0 comments on commit 840fe7c

Please sign in to comment.