summaryrefslogtreecommitdiff
path: root/var
diff options
context:
space:
mode:
authorRobert Pavel <rspavel@lanl.gov>2020-03-30 10:56:23 -0600
committerGitHub <noreply@github.com>2020-03-30 11:56:23 -0500
commit8d1e88658dfc8b0d830a15cbff27d4e3cbcee9dc (patch)
tree04c6efd77b7ed0e0379b8982819aa369b7d32853 /var
parentabdada03a88b28bfdfe0698a99a977eea4c54bd8 (diff)
downloadspack-8d1e88658dfc8b0d830a15cbff27d4e3cbcee9dc.tar.gz
spack-8d1e88658dfc8b0d830a15cbff27d4e3cbcee9dc.tar.bz2
spack-8d1e88658dfc8b0d830a15cbff27d4e3cbcee9dc.tar.xz
spack-8d1e88658dfc8b0d830a15cbff27d4e3cbcee9dc.zip
Aded Option to Disable Shared Lua library Generation (#15758)
* Aded Option to Disable Shared Lua library Added option to disable generation of shared object library for lua to avoid build issues on static only platforms * Fixed Flake8 Issue with Lua Spackage Fixed indentation issue with lua spackage
Diffstat (limited to 'var')
-rw-r--r--var/spack/repos/builtin/packages/lua/package.py12
1 files changed, 8 insertions, 4 deletions
diff --git a/var/spack/repos/builtin/packages/lua/package.py b/var/spack/repos/builtin/packages/lua/package.py
index ea6265e28a..c8fe652c39 100644
--- a/var/spack/repos/builtin/packages/lua/package.py
+++ b/var/spack/repos/builtin/packages/lua/package.py
@@ -27,6 +27,9 @@ class Lua(Package):
version('5.1.4', sha256='b038e225eaf2a5b57c9bcc35cd13aa8c6c8288ef493d52970c9545074098af3a')
version('5.1.3', sha256='6b5df2edaa5e02bf1a2d85e1442b2e329493b30b0c0780f77199d24f087d296d')
+ variant('shared', default=True,
+ description='Builds a shared version of the library')
+
extendable = True
depends_on('ncurses')
@@ -58,10 +61,11 @@ class Lua(Package):
make('INSTALL_TOP=%s' % prefix,
'install')
- static_to_shared_library(join_path(prefix.lib, 'liblua.a'),
- arguments=['-lm', '-ldl'],
- version=self.version,
- compat_version=self.version.up_to(2))
+ if '+shared' in spec:
+ static_to_shared_library(join_path(prefix.lib, 'liblua.a'),
+ arguments=['-lm', '-ldl'],
+ version=self.version,
+ compat_version=self.version.up_to(2))
# compatibility with ax_lua.m4 from autoconf-archive
# https://www.gnu.org/software/autoconf-archive/ax_lua.html