From e7c1ca1fca7ac8b91c9ce4fc3b1036f2eca0b3d5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20Jan=C3=9Fen?= Date: Tue, 12 Feb 2019 08:07:28 +0100 Subject: [PATCH] Revert changes --- python/install.py | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/python/install.py b/python/install.py index 5a97b6106d..feb6527352 100644 --- a/python/install.py +++ b/python/install.py @@ -22,11 +22,6 @@ else: pydir = "" # copy lammps.py to pydir if it exists # if pydir not specified, install in site-packages via distutils setup() -if 'liblammps.dylib' in os.listdir('../src/'): - lib_ext = ".dylib" -else: - lib_ext = ".so" - if pydir: if not os.path.isdir(pydir): print( "ERROR: pydir %s does not exist" % pydir) @@ -41,7 +36,7 @@ if pydir: str = "cp ../src/liblammps.so %s" % pydir print(str) try: - shutil.copyfile("../src/liblammps" + lib_ext, os.path.join(pydir,"liblammps" + lib_ext) ) + shutil.copyfile("../src/liblammps.so", os.path.join(pydir,"liblammps.so") ) except shutil.Error: pass # source and destination are identical sys.exit() @@ -70,7 +65,7 @@ try: url = "http://lammps.sandia.gov", description = "LAMMPS molecular dynamics library", py_modules = ["lammps"], - data_files = [(get_python_lib(), ["../src/liblammps" + lib_ext])]) + data_files = [(get_python_lib(), ["../src/liblammps.so"])]) except: tryuser=True print ("Installation into global site-packages dir failed.\nTrying user site dir %s now." % site.USER_SITE) @@ -86,9 +81,8 @@ if tryuser: url = "http://lammps.sandia.gov", description = "LAMMPS molecular dynamics library", py_modules = ["lammps"], - data_files = [(site.USER_SITE, ["../src/liblammps" + lib_ext])]) + data_files = [(site.USER_SITE, ["../src/liblammps.so"])]) except: print("Installation into user site package dir failed.\nGo to ../python and install manually.") -