From c53e53d701ece2c8a66339cb43f1f5046c355b30 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Mon, 13 Jun 2022 17:47:20 -0400 Subject: [PATCH] must set `suffix` variable only when suffixflag is true --- lib/latte/Install.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/latte/Install.py b/lib/latte/Install.py index 94879ff4a0..2e8f9bee8d 100644 --- a/lib/latte/Install.py +++ b/lib/latte/Install.py @@ -71,7 +71,8 @@ buildflag = args.build pathflag = args.path is not None version = args.version suffixflag = args.machine is not None -suffix = args.machine +if suffixflag: + suffix = args.machine if pathflag: lattedir = args.path @@ -132,8 +133,6 @@ os.symlink(os.path.join(lattedir, 'src', 'latte_c_bind.o'), 'filelink.o') # copy Makefile.lammps.suffix to Makefile.lammps if suffixflag or not os.path.exists("Makefile.lammps"): - if suffix is None: - suffix = 'gfortran' print("Creating Makefile.lammps") if os.path.exists("Makefile.lammps.%s" % suffix): shutil.copyfile("Makefile.lammps.%s" % suffix, 'Makefile.lammps')