本文整理汇总了Python中easybuild.framework.application.Application.make_install方法的典型用法代码示例。如果您正苦于以下问题:Python Application.make_install方法的具体用法?Python Application.make_install怎么用?Python Application.make_install使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类easybuild.framework.application.Application
的用法示例。
在下文中一共展示了Application.make_install方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: make_install
# 需要导入模块: from easybuild.framework.application import Application [as 别名]
# 或者: from easybuild.framework.application.Application import make_install [as 别名]
def make_install(self):
"""Extend make install to make sure that the 'python' command is present."""
Application.make_install(self)
python_binary_path = os.path.join(self.installdir, 'bin', 'python')
if not os.path.isfile(python_binary_path):
pythonver = '.'.join(self.version().split('.')[0:2])
srcbin = "%s%s" % (python_binary_path, pythonver)
try:
os.symlink(srcbin, python_binary_path)
except OSError, err:
self.log.error("Failed to symlink %s to %s: %s" % err)
示例2: make_install
# 需要导入模块: from easybuild.framework.application import Application [as 别名]
# 或者: from easybuild.framework.application.Application import make_install [as 别名]
def make_install(self):
"""Install step
Default make install and optionally remove incomplete lapack libs.
If the full_lapack option was set to false we don't
"""
Application.make_install(self)
if not self.getcfg('full_lapack'):
for i in ['liblapack.a', 'liblapack.so']:
lib = os.path.join(self.installdir, "lib", i[0])
if os.path.exists(lib):
os.rename(lib, os.path.join(self.installdir, "lib",
lib.replace("liblapack", "liblapack_atlas")))
else:
self.log.warning("Tried to remove %s, but file didn't exist")