diff options
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 18 |
1 files changed, 9 insertions, 9 deletions
@@ -10,7 +10,7 @@ all: build | |||
10 | # Base build | 10 | # Base build |
11 | # ---------------------------------------- | 11 | # ---------------------------------------- |
12 | 12 | ||
13 | build: luarocks luarocks-admin | 13 | build: luarocks luarocks-admin ./build/luarocks ./build/luarocks-admin |
14 | 14 | ||
15 | config.unix: | 15 | config.unix: |
16 | @echo Please run the "./configure" script before building. | 16 | @echo Please run the "./configure" script before building. |
@@ -35,14 +35,6 @@ luarocks-admin: config.unix | |||
35 | echo 'LUAROCKS_SYSCONFDIR="$(luarocksconfdir)" LUA_PATH="$(CURDIR)/src/?.lua;;" exec "$(LUA_BINDIR)/$(LUA_INTERPRETER)" "$(CURDIR)/src/bin/luarocks-admin" --project-tree="$(CURDIR)/lua_modules" "$$@"' >> luarocks-admin | 35 | echo 'LUAROCKS_SYSCONFDIR="$(luarocksconfdir)" LUA_PATH="$(CURDIR)/src/?.lua;;" exec "$(LUA_BINDIR)/$(LUA_INTERPRETER)" "$(CURDIR)/src/bin/luarocks-admin" --project-tree="$(CURDIR)/lua_modules" "$$@"' >> luarocks-admin |
36 | chmod +rx ./luarocks-admin | 36 | chmod +rx ./luarocks-admin |
37 | 37 | ||
38 | # ---------------------------------------- | ||
39 | # Regular install | ||
40 | # ---------------------------------------- | ||
41 | |||
42 | install: all $(DESTDIR)$(prefix)/bin/luarocks $(DESTDIR)$(prefix)/bin/luarocks-admin $(DESTDIR)$(luarocksconfdir)/config-$(LUA_VERSION).lua | ||
43 | mkdir -p "$(DESTDIR)$(prefix)/share/lua/$(LUA_VERSION)/luarocks" | ||
44 | cp -a src/luarocks/* "$(DESTDIR)$(prefix)/share/lua/$(LUA_VERSION)/luarocks" | ||
45 | |||
46 | ./build/luarocks: src/bin/luarocks config.unix | 38 | ./build/luarocks: src/bin/luarocks config.unix |
47 | mkdir -p "$(@D)" | 39 | mkdir -p "$(@D)" |
48 | (printf '#!$(LUA_BINDIR)/$(LUA_INTERPRETER)\n'\ | 40 | (printf '#!$(LUA_BINDIR)/$(LUA_INTERPRETER)\n'\ |
@@ -59,6 +51,14 @@ install: all $(DESTDIR)$(prefix)/bin/luarocks $(DESTDIR)$(prefix)/bin/luarocks-a | |||
59 | tail -n +2 src/bin/luarocks-admin \ | 51 | tail -n +2 src/bin/luarocks-admin \ |
60 | )> "$@" | 52 | )> "$@" |
61 | 53 | ||
54 | # ---------------------------------------- | ||
55 | # Regular install | ||
56 | # ---------------------------------------- | ||
57 | |||
58 | install: all $(DESTDIR)$(prefix)/bin/luarocks $(DESTDIR)$(prefix)/bin/luarocks-admin $(DESTDIR)$(luarocksconfdir)/config-$(LUA_VERSION).lua | ||
59 | mkdir -p "$(DESTDIR)$(prefix)/share/lua/$(LUA_VERSION)/luarocks" | ||
60 | cp -a src/luarocks/* "$(DESTDIR)$(prefix)/share/lua/$(LUA_VERSION)/luarocks" | ||
61 | |||
62 | $(DESTDIR)$(prefix)/bin/luarocks: ./build/luarocks | 62 | $(DESTDIR)$(prefix)/bin/luarocks: ./build/luarocks |
63 | $(INSTALL) -D "$<" "$@" | 63 | $(INSTALL) -D "$<" "$@" |
64 | 64 | ||