CMakePackage : changed method name from wdir
to build_directory
This commit is contained in:
parent
8091a3d6cb
commit
484aaf50cc
1 changed files with 6 additions and 8 deletions
|
@ -1186,8 +1186,6 @@ def build_process():
|
||||||
)
|
)
|
||||||
|
|
||||||
self.stage.keep = keep_stage
|
self.stage.keep = keep_stage
|
||||||
self.build_directory = join_path(self.stage.path, 'spack-build')
|
|
||||||
self.source_directory = self.stage.source_path
|
|
||||||
|
|
||||||
try:
|
try:
|
||||||
with contextlib.nested(self.stage, self._prefix_write_lock()):
|
with contextlib.nested(self.stage, self._prefix_write_lock()):
|
||||||
|
@ -1768,7 +1766,7 @@ def build_type(self):
|
||||||
return 'RelWithDebInfo'
|
return 'RelWithDebInfo'
|
||||||
|
|
||||||
def root_cmakelists_dir(self):
|
def root_cmakelists_dir(self):
|
||||||
return self.source_directory
|
return self.stage.source_path
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def std_cmake_args(self):
|
def std_cmake_args(self):
|
||||||
|
@ -1794,7 +1792,7 @@ def _std_args(pkg):
|
||||||
args.append('-DCMAKE_INSTALL_RPATH:STRING={0}'.format(rpaths))
|
args.append('-DCMAKE_INSTALL_RPATH:STRING={0}'.format(rpaths))
|
||||||
return args
|
return args
|
||||||
|
|
||||||
def wdir(self):
|
def build_directory(self):
|
||||||
return join_path(self.stage.source_path, 'spack-build')
|
return join_path(self.stage.source_path, 'spack-build')
|
||||||
|
|
||||||
def cmake_args(self):
|
def cmake_args(self):
|
||||||
|
@ -1803,16 +1801,16 @@ def cmake_args(self):
|
||||||
def cmake(self, spec, prefix):
|
def cmake(self, spec, prefix):
|
||||||
options = [self.root_cmakelists_dir()] + self.std_cmake_args + \
|
options = [self.root_cmakelists_dir()] + self.std_cmake_args + \
|
||||||
self.cmake_args()
|
self.cmake_args()
|
||||||
create = not os.path.exists(self.wdir())
|
create = not os.path.exists(self.build_directory())
|
||||||
with working_dir(self.wdir(), create=create):
|
with working_dir(self.build_directory(), create=create):
|
||||||
inspect.getmodule(self).cmake(*options)
|
inspect.getmodule(self).cmake(*options)
|
||||||
|
|
||||||
def build(self, spec, prefix):
|
def build(self, spec, prefix):
|
||||||
with working_dir(self.wdir()):
|
with working_dir(self.build_directory()):
|
||||||
inspect.getmodule(self).make()
|
inspect.getmodule(self).make()
|
||||||
|
|
||||||
def install(self, spec, prefix):
|
def install(self, spec, prefix):
|
||||||
with working_dir(self.wdir()):
|
with working_dir(self.build_directory()):
|
||||||
inspect.getmodule(self).make('install')
|
inspect.getmodule(self).make('install')
|
||||||
|
|
||||||
@PackageBase.sanity_check('build')
|
@PackageBase.sanity_check('build')
|
||||||
|
|
Loading…
Reference in a new issue