Skip to content

Commit d6c3ccb

Browse files
committed
Improve Makefile
Signed-off-by: Bensuperpc <[email protected]>
1 parent 3225cd5 commit d6c3ccb

File tree

1 file changed

+16
-11
lines changed

1 file changed

+16
-11
lines changed

Makefile

Lines changed: 16 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,8 @@ uninstall:
3838
update: uninstall install
3939

4040
sync-submodule:
41-
git submodule update --init --recursive
42-
git submodule update --recursive --remote
41+
git submodule update --init --recursive --jobs=2
42+
git submodule update --recursive --remote --jobs=2
4343

4444
dist: clean
4545
mkdir -p package_build
@@ -61,6 +61,14 @@ dist-full: clean
6161

6262
check:
6363
find . -type f -name "*.sh" ! -path "*./git/*" ! -path "*/install.sh" ! -path "*/uninstall.sh" ! -path "*/Bash-Snippet/*" ! -path "*/git-scripts/*" ! -path "*/git-extras/*" ! -path "*/git-extra-commands/*" ! -path "*/cryptr/*" ! -path "*/others-dist/*" ! -path "*/bash-scripts/*" ! -path "*/fff/*" -exec $(SHELL) -n {} \;
64+
65+
clean:
66+
$(RM) -rf package_build/
67+
$(RM) -f $(PROJECT_NAME)-$(VERSION).tar.xz
68+
$(RM) -f $(PROJECT_NAME)-$(VERSION).tar.xz.sha384
69+
$(RM) -f $(PROJECT_NAME)-full-$(VERSION).tar.xz
70+
$(RM) -f $(PROJECT_NAME)-full-$(VERSION).tar.xz.sha384
71+
@echo "Clean OK"
6472

6573
check-dep:
6674
@echo "Check dependency:"
@@ -83,14 +91,11 @@ check-dep:
8391
@cwebp -version > /dev/null 2>&1 && echo "cwebp: OK" || echo "cwebp: Missing"
8492
@avifenc --version > /dev/null 2>&1 && echo "avifenc: OK" || echo "avifenc: Missing"
8593
@magick -version > /dev/null 2>&1 && echo "magick: OK" || echo "magick: Missing"
86-
94+
@pacman --version > /dev/null 2>&1 && echo "pacman: OK" || echo "pacman: Missing (If Archlinux based)"
95+
@apt --version > /dev/null 2>&1 && echo "apt: OK" || echo "apt: Missing (If debian based)"
96+
@clang-format --version > /dev/null 2>&1 && echo "clang-format: OK" || echo "clang-format: Missing"
97+
@cmake --version > /dev/null 2>&1 && echo "cmake: OK" || echo "cmake: Missing"
98+
@ninja --version > /dev/null 2>&1 && echo "ninja: OK" || echo "ninja: Missing"
8799

88-
clean:
89-
$(RM) -rf package_build/
90-
$(RM) -f $(PROJECT_NAME)-$(VERSION).tar.xz
91-
$(RM) -f $(PROJECT_NAME)-$(VERSION).tar.xz.sha384
92-
$(RM) -f $(PROJECT_NAME)-full-$(VERSION).tar.xz
93-
$(RM) -f $(PROJECT_NAME)-full-$(VERSION).tar.xz.sha384
94-
@echo "Clean OK"
95100

96-
.PHONY: check dist-full clean dist sync-submodule install uninstall update
101+
.PHONY: check check-dep dist-full clean dist sync-submodule install uninstall update

0 commit comments

Comments
 (0)