[fix] improve the dist task
This commit is contained in:
parent
c205da71ea
commit
ff3350de5d
1 changed files with 9 additions and 8 deletions
17
Makefile
17
Makefile
|
@ -55,14 +55,15 @@ $(BUILD_DIR)/archy-slstatus: $(SLSTATUS_OBJ) $(COM_OBJ) $(REQ_OBJ)
|
||||||
clean:
|
clean:
|
||||||
rm -rf $(BUILD_DIR)
|
rm -rf $(BUILD_DIR)
|
||||||
|
|
||||||
dist:
|
dist: build/archy-slstatus
|
||||||
rm -rf "archy-slstatus_$(VERSION)"
|
mkdir -p "dist/archy-slstatus_$(VERSION)"
|
||||||
mkdir -p "archy-slstatus_$(VERSION)/components"
|
cp -R LICENSE README.md $(BUILD_DIR)/archy-slstatus archy-slstatus.1 "dist/archy-slstatus_$(VERSION)"
|
||||||
cp -R LICENSE Makefile README config.mk config.def.h \
|
tar -cf - "dist/archy-slstatus_$(VERSION)" | gzip -c > "archy-slstatus_$(VERSION).tar.gz"
|
||||||
arg.h $(SRC_DIR)/archy-slstatus.c $(COM:%=$(SRC_DIR)/%.c) $(REQ:%=$(SRC_DIR)/%.c) $(REQ:%=$(SRC_DIR)/%.h) \
|
rm -rf "dist/archy-slstatus_$(VERSION)"
|
||||||
archy-slstatus.1 "archy-slstatus_$(VERSION)"
|
mv "archy-slstatus_$(VERSION).tar.gz" "dist/archy-slstatus_$(VERSION).tar.gz"
|
||||||
tar -cf - "archy-slstatus_$(VERSION)" | gzip -c > "archy-slstatus_$(VERSION).tar.gz"
|
echo "The tarball is ready."
|
||||||
rm -rf "archy-slstatus_$(VERSION)"
|
printf "Tarball size: %s\n" $$(du -h dist/archy-slstatus_${VERSION}.tar.gz | cut -f1)
|
||||||
|
printf "Tarball hash: %s\n" $$(sha256sum dist/archy-slstatus_${VERSION}.tar.gz)
|
||||||
|
|
||||||
install: all
|
install: all
|
||||||
mkdir -p "$(DESTDIR)$(PREFIX)/bin"
|
mkdir -p "$(DESTDIR)$(PREFIX)/bin"
|
||||||
|
|
Loading…
Reference in a new issue