Skip to content
Snippets Groups Projects
Unverified Commit 8d1e8865 authored by Robert Pavel's avatar Robert Pavel Committed by GitHub
Browse files

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
parent abdada03
Branches
Tags
No related merge requests found
...@@ -27,6 +27,9 @@ class Lua(Package): ...@@ -27,6 +27,9 @@ class Lua(Package):
version('5.1.4', sha256='b038e225eaf2a5b57c9bcc35cd13aa8c6c8288ef493d52970c9545074098af3a') version('5.1.4', sha256='b038e225eaf2a5b57c9bcc35cd13aa8c6c8288ef493d52970c9545074098af3a')
version('5.1.3', sha256='6b5df2edaa5e02bf1a2d85e1442b2e329493b30b0c0780f77199d24f087d296d') version('5.1.3', sha256='6b5df2edaa5e02bf1a2d85e1442b2e329493b30b0c0780f77199d24f087d296d')
variant('shared', default=True,
description='Builds a shared version of the library')
extendable = True extendable = True
depends_on('ncurses') depends_on('ncurses')
...@@ -58,10 +61,11 @@ def install(self, spec, prefix): ...@@ -58,10 +61,11 @@ def install(self, spec, prefix):
make('INSTALL_TOP=%s' % prefix, make('INSTALL_TOP=%s' % prefix,
'install') 'install')
static_to_shared_library(join_path(prefix.lib, 'liblua.a'), if '+shared' in spec:
arguments=['-lm', '-ldl'], static_to_shared_library(join_path(prefix.lib, 'liblua.a'),
version=self.version, arguments=['-lm', '-ldl'],
compat_version=self.version.up_to(2)) version=self.version,
compat_version=self.version.up_to(2))
# compatibility with ax_lua.m4 from autoconf-archive # compatibility with ax_lua.m4 from autoconf-archive
# https://www.gnu.org/software/autoconf-archive/ax_lua.html # https://www.gnu.org/software/autoconf-archive/ax_lua.html
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment