SHA256
1
0
forked from pool/lua-toluapp
Tomáš Chvátal 2017-07-14 12:27:18 +00:00 committed by Git OBS Bridge
parent 50b069722d
commit 65d3bd8e98
2 changed files with 12 additions and 14 deletions

View File

@ -18,6 +18,17 @@
%define flavor @BUILD_FLAVOR@
%define mod_name toluapp
%define lua_suffix %(lua -e 'print(_VERSION)' | cut -d ' ' -f 2 |sed -e 's:\.:_:')
%define lua_value %(echo "%{flavor}" |sed -e 's:lua::')
%if "%{flavor}" == "lua51"
%define lua_suffix 5_1
%endif
%if "%{flavor}" == "lua52"
%define lua_suffix 5_2
%endif
%if "%{flavor}" == "lua53"
%define lua_suffix 5_3
%endif
Name: %{flavor}-%{mod_name}
Version: 1.0.93
Release: 0
@ -137,7 +148,7 @@ ln -sf %{_sysconfdir}/alternatives/tolua++ %{buildroot}%{_bindir}/tolua++
%postun -n libtolua++-%{lua_suffix}-1 -p /sbin/ldconfig
%post -n toluapp-%{lua_version}
/sbin/ldconfig
%{_sbindir}/update-alternatives --install %{_bindir}/tolua++ tolua++ %{_bindir}/toluapp-%{lua_version} 10
%{_sbindir}/update-alternatives --install %{_bindir}/tolua++ tolua++ %{_bindir}/toluapp-%{lua_version} %{lua_value}
%postun -n toluapp-%{lua_version}
/sbin/ldconfig

View File

@ -17,19 +17,6 @@ diff -urN tolua++-1.0.93/config_linux.py tolua++-1.0.93.lua52/config_linux.py
-LIBS = ['lua50', 'lualib50', 'dl', 'm']
+LIBS = ['lua', 'dl', 'm']
diff -urN tolua++-1.0.93/custom.py tolua++-1.0.93.lua52/custom.py
--- tolua++-1.0.93/custom.py 1970-01-01 01:00:00.000000000 +0100
+++ tolua++-1.0.93.lua52/custom.py 2014-10-01 11:52:32.217957188 +0200
@@ -0,0 +1,9 @@
+CCFLAGS = ['-O2', '-ansi']
+#LIBPATH = ['/usr/local/lib']
+LIBS = ['lua', 'dl', 'm']
+prefix = '/usr'
+build_dev=1
+tolua_bin = 'tolua++'
+tolua_lib = 'tolua++-5.2'
+TOLUAPP = 'tolua++'
+
diff -urN tolua++-1.0.93/SConstruct tolua++-1.0.93.lua52/SConstruct
--- tolua++-1.0.93/SConstruct 2008-04-21 02:05:35.000000000 +0200
+++ tolua++-1.0.93.lua52/SConstruct 2014-10-01 13:51:40.837513339 +0200