aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile6
1 files changed, 4 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index ffc5e6e8..0ac52ca4 100644
--- a/Makefile
+++ b/Makefile
@@ -11,6 +11,8 @@ luadir ?= $(datarootdir)/lua/$(LUA_VERSION)
11INSTALL ?= install 11INSTALL ?= install
12INSTALL_DATA ?= $(INSTALL) -m 644 12INSTALL_DATA ?= $(INSTALL) -m 644
13 13
14SHEBANG = '\#!$(LUA_BINDIR)/$(LUA_INTERPRETER)'
15
14LUAROCKS_FILES = $(shell find src/luarocks/ -type f -name '*.lua') 16LUAROCKS_FILES = $(shell find src/luarocks/ -type f -name '*.lua')
15 17
16all: build 18all: build
@@ -46,7 +48,7 @@ luarocks-admin: config.unix
46 48
47./build/luarocks: src/bin/luarocks config.unix 49./build/luarocks: src/bin/luarocks config.unix
48 mkdir -p "$(@D)" 50 mkdir -p "$(@D)"
49 (printf '#!$(LUA_BINDIR)/$(LUA_INTERPRETER)\n'\ 51 (printf '$(SHEBANG)\n'\
50 'package.loaded["luarocks.core.hardcoded"] = { SYSCONFDIR = [[$(luarocksconfdir)]] }\n'\ 52 'package.loaded["luarocks.core.hardcoded"] = { SYSCONFDIR = [[$(luarocksconfdir)]] }\n'\
51 'package.path=[[$(luadir)/?.lua;]] .. package.path\n'; \ 53 'package.path=[[$(luadir)/?.lua;]] .. package.path\n'; \
52 tail -n +2 src/bin/luarocks \ 54 tail -n +2 src/bin/luarocks \
@@ -54,7 +56,7 @@ luarocks-admin: config.unix
54 56
55./build/luarocks-admin: src/bin/luarocks-admin config.unix 57./build/luarocks-admin: src/bin/luarocks-admin config.unix
56 mkdir -p "$(@D)" 58 mkdir -p "$(@D)"
57 (printf '#!$(LUA_BINDIR)/$(LUA_INTERPRETER)\n'\ 59 (printf '$(SHEBANG)\n'\
58 'package.loaded["luarocks.core.hardcoded"] = { SYSCONFDIR = [[$(luarocksconfdir)]] }\n'\ 60 'package.loaded["luarocks.core.hardcoded"] = { SYSCONFDIR = [[$(luarocksconfdir)]] }\n'\
59 'package.path=[[$(luadir)/?.lua;]] .. package.path\n'; \ 61 'package.path=[[$(luadir)/?.lua;]] .. package.path\n'; \
60 tail -n +2 src/bin/luarocks-admin \ 62 tail -n +2 src/bin/luarocks-admin \