use system lua 5.3: disable luajit
This commit is contained in:
parent
d1b388be6e
commit
9c13c93eb2
@ -14,6 +14,7 @@ Summary: A Lua language interpreter embedding in Haskell
|
|||||||
License: MIT
|
License: MIT
|
||||||
Url: https://hackage.haskell.org/package/%{pkg_name}
|
Url: https://hackage.haskell.org/package/%{pkg_name}
|
||||||
Source0: https://hackage.haskell.org/package/%{pkgver}/%{pkgver}.tar.gz
|
Source0: https://hackage.haskell.org/package/%{pkgver}/%{pkgver}.tar.gz
|
||||||
|
Patch0: hslua-system-lua.patch
|
||||||
|
|
||||||
BuildRequires: ghc-Cabal-devel
|
BuildRequires: ghc-Cabal-devel
|
||||||
BuildRequires: ghc-rpm-macros
|
BuildRequires: ghc-rpm-macros
|
||||||
@ -23,7 +24,7 @@ BuildRequires: ghc-containers-devel
|
|||||||
BuildRequires: ghc-exceptions-devel
|
BuildRequires: ghc-exceptions-devel
|
||||||
BuildRequires: ghc-mtl-devel
|
BuildRequires: ghc-mtl-devel
|
||||||
BuildRequires: ghc-text-devel
|
BuildRequires: ghc-text-devel
|
||||||
BuildRequires: pkgconfig(luajit)
|
BuildRequires: pkgconfig(lua)
|
||||||
%if %{with tests}
|
%if %{with tests}
|
||||||
BuildRequires: ghc-QuickCheck-devel
|
BuildRequires: ghc-QuickCheck-devel
|
||||||
BuildRequires: ghc-quickcheck-instances-devel
|
BuildRequires: ghc-quickcheck-instances-devel
|
||||||
@ -50,7 +51,7 @@ Requires(postun): ghc-compiler = %{ghc_version}
|
|||||||
%endif
|
%endif
|
||||||
Requires: %{name}%{?_isa} = %{version}-%{release}
|
Requires: %{name}%{?_isa} = %{version}-%{release}
|
||||||
# Begin cabal-rpm deps:
|
# Begin cabal-rpm deps:
|
||||||
Requires: pkgconfig(luajit)
|
Requires: pkgconfig(lua)
|
||||||
# End cabal-rpm deps
|
# End cabal-rpm deps
|
||||||
|
|
||||||
%description devel
|
%description devel
|
||||||
@ -59,13 +60,14 @@ This package provides the Haskell %{pkg_name} library development files.
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n %{pkgver}
|
%setup -q -n %{pkgver}
|
||||||
cabal-tweak-drop-dep ', fail >= 4.9 && < 5'
|
%patch0 -p1 -b .orig
|
||||||
cabal-tweak-flag system-lua True
|
sed -i "/fail /d" hslua.cabal
|
||||||
cabal-tweak-flag use-pkgconfig True
|
#cabal-tweak-drop-dep '\", fail >= 4.9 && < 5\"'
|
||||||
rm -r lua-5.3.4
|
rm -r lua-5.3.4
|
||||||
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
|
%define cabal_configure_options -f -luajit -f use-pkgconfig
|
||||||
%ghc_lib_build
|
%ghc_lib_build
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,11 +1,31 @@
|
|||||||
--- hslua-0.4.1/hslua.cabal~ 2015-09-09 06:23:09.000000000 +0900
|
--- hslua-0.9.5/hslua.cabal.orig 2018-01-04 23:32:01.000000000 +0100
|
||||||
+++ hslua-0.4.1/hslua.cabal 2016-06-28 10:21:53.952491564 +0900
|
+++ hslua-0.9.5/hslua.cabal 2018-01-30 00:14:21.052923877 +0100
|
||||||
@@ -50,7 +50,7 @@
|
@@ -35,7 +35,8 @@
|
||||||
if flag(luajit)
|
|
||||||
Extra-libraries: luajit-5.1
|
flag system-lua
|
||||||
else
|
description: Use the system-wide Lua instead of the bundled copy.
|
||||||
- Extra-libraries: lua
|
- default: False
|
||||||
+ Pkgconfig-depends: lua-5.1
|
+ default: True
|
||||||
includes: lua.h
|
+ manual: True
|
||||||
else
|
|
||||||
c-sources: lua-5.1.5/lobject.c, lua-5.1.5/ltm.c, lua-5.1.5/ldblib.c,
|
flag apicheck
|
||||||
|
description: Compile Lua with -DLUA_USE_APICHECK.
|
||||||
|
@@ -60,6 +61,7 @@
|
||||||
|
flag luajit
|
||||||
|
description: Link with LuaJIT. This implies flag system-lua as well.
|
||||||
|
default: False
|
||||||
|
+ manual: True
|
||||||
|
|
||||||
|
flag lua501
|
||||||
|
description: Build against lua 5.1.
|
||||||
|
@@ -115,7 +116,7 @@
|
||||||
|
if flag(lua502)
|
||||||
|
pkgconfig-depends: lua5.2
|
||||||
|
else
|
||||||
|
- pkgconfig-depends: lua5.3
|
||||||
|
+ pkgconfig-depends: lua
|
||||||
|
else
|
||||||
|
Extra-libraries: lua
|
||||||
|
if !flag(use-pkgconfig)
|
||||||
|
|
||||||
|
Diff finished. Tue Jan 30 00:14:26 2018
|
||||||
|
Loading…
Reference in New Issue
Block a user