Cleanup makefiles and curl calls

This commit is contained in:
Tristan
2022-06-07 04:06:13 +01:00
parent 60b21d9f39
commit b96c915703
6 changed files with 55 additions and 43 deletions

16
deps/lua/Makefile vendored
View File

@@ -6,16 +6,16 @@ LUA_DESTDIR = dist
LUA_DESTDIR_ABS = $(shell realpath $(LUA_DESTDIR))
LUA_ARCHIVE = lua-dist.tar.gz
all: $(LUA_BUILDIR) $(LUA_DESTDIR) $(LUA_ARCHIVE)
all: build $(LUA_DESTDIR) $(LUA_ARCHIVE)
$(LUA_BUILDIR):
$(LUA_TARBALL):
curl -fsSL -o "$(LUA_TARBALL)" "$(LUA_SOURCES)"
$(LUA_BUILDIR): $(LUA_TARBALL)
@if ! [ -d "$(LUA_BUILDIR)" ]; then mkdir -v "$(LUA_BUILDIR)"; fi
$(LUA_BUILDIR)/lua-$(LUA_VERSION).tar.gz: $(LUA_BUILDIR)
curl -sSL -o "$(LUA_TARBALL)" "$(LUA_SOURCES)"
build: $(LUA_BUILDIR)/lua-$(LUA_VERSION).tar.gz
tar -C $(LUA_BUILDIR) --strip-components=1 -xf "$(LUA_TARBALL)"
build: $(LUA_BUILDIR)
$(MAKE) -C $(LUA_BUILDIR) -j$(shell nproc) linux
$(LUA_DESTDIR): build
@@ -26,9 +26,9 @@ $(LUA_ARCHIVE): $(LUA_DESTDIR)
tar -C "$(LUA_DESTDIR)" -cjf "$(LUA_ARCHIVE)" $$(ls -1 $(LUA_DESTDIR))
clean:
rm -fv "$(LUA_TARBALL)"
rm -rf "$(LUA_BUILDIR)"
rm -rf "$(LUA_DESTDIR)"
rm -fv "$(LUA_TARBALL)"
rm -fv "$(LUA_ARCHIVE)"
.PHONY: clean build