summaryrefslogtreecommitdiffstats
path: root/package/lua/lua-01-root-path.patch
blob: f82c9c5f0e22dd2a0cb921a3b79eefe018c0a95c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
Adjust installation location to /usr.
Remove version in module paths.

Signed-off-by: Francois Perrad <francois.perrad@gadz.org>

Index: b/etc/lua.pc
===================================================================
--- a/etc/lua.pc
+++ b/etc/lua.pc
@@ -8,13 +8,13 @@
 R= 5.1.5
 
 # grep '^INSTALL_.*=' ../Makefile | sed 's/INSTALL_TOP/prefix/'
-prefix= /usr/local
+prefix= /usr
 INSTALL_BIN= ${prefix}/bin
 INSTALL_INC= ${prefix}/include
 INSTALL_LIB= ${prefix}/lib
 INSTALL_MAN= ${prefix}/man/man1
-INSTALL_LMOD= ${prefix}/share/lua/${V}
-INSTALL_CMOD= ${prefix}/lib/lua/${V}
+INSTALL_LMOD= ${prefix}/share/lua
+INSTALL_CMOD= ${prefix}/lib/lua
 
 # canonical vars
 exec_prefix=${prefix}
Index: b/src/luaconf.h
===================================================================
--- a/src/luaconf.h
+++ b/src/luaconf.h
@@ -94,9 +94,9 @@
 	".\\?.dll;"  LUA_CDIR"?.dll;" LUA_CDIR"loadall.dll"
 
 #else
-#define LUA_ROOT	"/usr/local/"
-#define LUA_LDIR	LUA_ROOT "share/lua/5.1/"
-#define LUA_CDIR	LUA_ROOT "lib/lua/5.1/"
+#define LUA_ROOT	"/usr/"
+#define LUA_LDIR	LUA_ROOT "share/lua/"
+#define LUA_CDIR	LUA_ROOT "lib/lua/"
 #define LUA_PATH_DEFAULT  \
 		"./?.lua;"  LUA_LDIR"?.lua;"  LUA_LDIR"?/init.lua;" \
 		            LUA_CDIR"?.lua;"  LUA_CDIR"?/init.lua"