clingo: fix ~python build (#30824)
This commit is contained in:
parent
3fdb3f832a
commit
57822d3014
2 changed files with 15 additions and 10 deletions
1
.github/workflows/bootstrap.yml
vendored
1
.github/workflows/bootstrap.yml
vendored
|
@ -12,6 +12,7 @@ on:
|
||||||
# built-in repository or documentation
|
# built-in repository or documentation
|
||||||
- 'var/spack/repos/builtin/**'
|
- 'var/spack/repos/builtin/**'
|
||||||
- '!var/spack/repos/builtin/packages/clingo-bootstrap/**'
|
- '!var/spack/repos/builtin/packages/clingo-bootstrap/**'
|
||||||
|
- '!var/spack/repos/builtin/packages/clingo/**'
|
||||||
- '!var/spack/repos/builtin/packages/python/**'
|
- '!var/spack/repos/builtin/packages/python/**'
|
||||||
- '!var/spack/repos/builtin/packages/re2c/**'
|
- '!var/spack/repos/builtin/packages/re2c/**'
|
||||||
- 'lib/spack/docs/**'
|
- 'lib/spack/docs/**'
|
||||||
|
|
|
@ -86,15 +86,19 @@ def cmake_args(self):
|
||||||
except UnsupportedCompilerFlag:
|
except UnsupportedCompilerFlag:
|
||||||
InstallError('clingo requires a C++14-compliant C++ compiler')
|
InstallError('clingo requires a C++14-compliant C++ compiler')
|
||||||
|
|
||||||
args = [
|
args = ['-DCLINGO_BUILD_WITH_LUA=OFF']
|
||||||
|
|
||||||
|
if '+python' in self.spec:
|
||||||
|
args += [
|
||||||
'-DCLINGO_REQUIRE_PYTHON=ON',
|
'-DCLINGO_REQUIRE_PYTHON=ON',
|
||||||
'-DCLINGO_BUILD_WITH_PYTHON=ON',
|
'-DCLINGO_BUILD_WITH_PYTHON=ON',
|
||||||
'-DPYCLINGO_USER_INSTALL=OFF',
|
'-DPYCLINGO_USER_INSTALL=OFF',
|
||||||
'-DPYCLINGO_USE_INSTALL_PREFIX=ON',
|
'-DPYCLINGO_USE_INSTALL_PREFIX=ON',
|
||||||
'-DCLINGO_BUILD_WITH_LUA=OFF',
|
|
||||||
self.cmake_py_shared
|
self.cmake_py_shared
|
||||||
]
|
]
|
||||||
if self.spec['cmake'].satisfies('@3.16.0:'):
|
if self.spec['cmake'].satisfies('@3.16.0:'):
|
||||||
args += self.cmake_python_hints
|
args += self.cmake_python_hints
|
||||||
|
else:
|
||||||
|
args += ['-DCLINGO_BUILD_WITH_PYTHON=OFF']
|
||||||
|
|
||||||
return args
|
return args
|
||||||
|
|
Loading…
Reference in a new issue