Revert "Add --noinstall flag to use the plumed source code directly without issuing make install"
This reverts commit a4684e2629.
Revert --noinstall flag commit
This commit is contained in:
@ -796,10 +796,6 @@ make lib-plumed args="-b" # download and build PLUMED in lib/plume
|
|||||||
make lib-plumed args="-p $HOME/.local" # use existing PLUMED installation in $HOME/.local
|
make lib-plumed args="-p $HOME/.local" # use existing PLUMED installation in $HOME/.local
|
||||||
make lib-plumed args="-p /usr/local -m shared" # use existing PLUMED installation in
|
make lib-plumed args="-p /usr/local -m shared" # use existing PLUMED installation in
|
||||||
# /usr/local and use shared linkage mode
|
# /usr/local and use shared linkage mode
|
||||||
make lib-plumed args="-p $HOME/plumed2 --noinstall -m shared" # use existing PLUMED
|
|
||||||
# compiled source code in
|
|
||||||
# $HOME/plumed2 and use
|
|
||||||
# shared linkage mode
|
|
||||||
:pre
|
:pre
|
||||||
|
|
||||||
Note that 2 symbolic (soft) links, "includelink" and "liblink" are
|
Note that 2 symbolic (soft) links, "includelink" and "liblink" are
|
||||||
|
|||||||
@ -12,12 +12,10 @@ help = """
|
|||||||
Syntax from src dir: make lib-plumed args="-b"
|
Syntax from src dir: make lib-plumed args="-b"
|
||||||
or: make lib-plumed args="-b -v 2.4.3"
|
or: make lib-plumed args="-b -v 2.4.3"
|
||||||
or: make lib-plumed args="-p /usr/local/plumed2 -m shared"
|
or: make lib-plumed args="-p /usr/local/plumed2 -m shared"
|
||||||
or: make lib-plumed args="-p /home/myname/myplumed2sourcecode --noinstall"
|
|
||||||
|
|
||||||
Syntax from lib dir: python Install.py -b -v 2.4.3
|
Syntax from lib dir: python Install.py -b -v 2.4.3
|
||||||
or: python Install.py -b
|
or: python Install.py -b
|
||||||
or: python Install.py -p /usr/local/plumed2 -m shared
|
or: python Install.py -p /usr/local/plumed2 -m shared
|
||||||
or: python Install.py -p /home/myname/myplumed2sourcecode --noinstall
|
|
||||||
|
|
||||||
specify one or more options, order does not matter
|
specify one or more options, order does not matter
|
||||||
|
|
||||||
@ -25,13 +23,11 @@ specify one or more options, order does not matter
|
|||||||
-v = set version of plumed2 to download and build (default: 2.4.3)
|
-v = set version of plumed2 to download and build (default: 2.4.3)
|
||||||
-p = specify folder of existing plumed2 installation
|
-p = specify folder of existing plumed2 installation
|
||||||
-m = set plumed linkage mode: static (default), shared, or runtime
|
-m = set plumed linkage mode: static (default), shared, or runtime
|
||||||
--noinstall = use existing plumed2 source code folder where make was issued but make install was not
|
|
||||||
|
|
||||||
Example:
|
Example:
|
||||||
|
|
||||||
make lib-plumed args="-b" # download/build in lib/plumed/plumed2
|
make lib-plumed args="-b" # download/build in lib/plumed/plumed2
|
||||||
make lib-plumed args="-p /usr/local/plumed2 -m shared" # use existing Plumed2 installation in /usr/local/plumed2
|
make lib-plumed args="-p $HOME/plumed2 -m shared" # use existing Plumed2 installation in $HOME/plumed2
|
||||||
make lib-plumed args="-p $HOME/plumed2 -m shared --noinstall" # use existing Plumed2 source code folder in $HOME/plumed2
|
|
||||||
"""
|
"""
|
||||||
|
|
||||||
# settings
|
# settings
|
||||||
@ -121,7 +117,6 @@ buildflag = False
|
|||||||
pathflag = False
|
pathflag = False
|
||||||
suffixflag = False
|
suffixflag = False
|
||||||
linkflag = True
|
linkflag = True
|
||||||
noinstallflag = False
|
|
||||||
|
|
||||||
iarg = 0
|
iarg = 0
|
||||||
while iarg < nargs:
|
while iarg < nargs:
|
||||||
@ -141,9 +136,6 @@ while iarg < nargs:
|
|||||||
elif args[iarg] == "-b":
|
elif args[iarg] == "-b":
|
||||||
buildflag = True
|
buildflag = True
|
||||||
iarg += 1
|
iarg += 1
|
||||||
elif args[iarg] == "--noinstall":
|
|
||||||
noinstallflag = True
|
|
||||||
iarg += 1
|
|
||||||
else: error()
|
else: error()
|
||||||
|
|
||||||
homepath = fullpath(homepath)
|
homepath = fullpath(homepath)
|
||||||
@ -205,21 +197,12 @@ if linkflag:
|
|||||||
os.remove("includelink")
|
os.remove("includelink")
|
||||||
if os.path.isfile("liblink") or os.path.islink("liblink"):
|
if os.path.isfile("liblink") or os.path.islink("liblink"):
|
||||||
os.remove("liblink")
|
os.remove("liblink")
|
||||||
if noinstallflag:
|
cmd = 'ln -s "%s/include" includelink' % homedir
|
||||||
cmd = 'ln -s "%s/src/include" includelink' % homedir
|
subprocess.check_output(cmd,stderr=subprocess.STDOUT,shell=True)
|
||||||
subprocess.check_output(cmd,stderr=subprocess.STDOUT,shell=True)
|
cmd = 'ln -s "%s/lib" liblink' % homedir
|
||||||
cmd = 'ln -s "%s/src/lib" liblink' % homedir
|
subprocess.check_output(cmd,stderr=subprocess.STDOUT,shell=True)
|
||||||
subprocess.check_output(cmd,stderr=subprocess.STDOUT,shell=True)
|
|
||||||
else:
|
|
||||||
cmd = 'ln -s "%s/include" includelink' % homedir
|
|
||||||
subprocess.check_output(cmd,stderr=subprocess.STDOUT,shell=True)
|
|
||||||
cmd = 'ln -s "%s/lib" liblink' % homedir
|
|
||||||
subprocess.check_output(cmd,stderr=subprocess.STDOUT,shell=True)
|
|
||||||
if os.path.isfile("Makefile.lammps.%s" % mode):
|
if os.path.isfile("Makefile.lammps.%s" % mode):
|
||||||
print("Creating Makefile.lammps")
|
print("Creating Makefile.lammps")
|
||||||
if noinstallflag:
|
cmd = 'echo PLUMED_LIBDIR="%s/lib" > Makefile.lammps; cat liblink/plumed/src/lib/Plumed.inc.%s Makefile.lammps.%s >> Makefile.lammps' % (homedir,mode,mode)
|
||||||
cmd = 'echo PLUMED_LIBDIR="%s/src/lib" > Makefile.lammps; cat liblink/Plumed.inc.%s Makefile.lammps.%s >> Makefile.lammps' % (homedir,mode,mode)
|
|
||||||
else:
|
|
||||||
cmd = 'echo PLUMED_LIBDIR="%s/lib" > Makefile.lammps; cat liblink/plumed/src/lib/Plumed.inc.%s Makefile.lammps.%s >> Makefile.lammps' % (homedir,mode,mode)
|
|
||||||
subprocess.check_output(cmd,stderr=subprocess.STDOUT,shell=True)
|
subprocess.check_output(cmd,stderr=subprocess.STDOUT,shell=True)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user