aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlejandro Colomar <alx@kernel.org>2024-07-18 12:18:23 +0200
committerAlejandro Colomar <alx@kernel.org>2024-07-20 11:18:06 +0200
commit082547cb6fbb0f5899a30c31d37cd9a724e231e6 (patch)
treed91787180c4342d316dd10fce739110e26e793c8
parent35a780a99bd8895009de2a708c0308d9bf8b66ac (diff)
downloadman-pages-082547cb6fbb0f5899a30c31d37cd9a724e231e6.tar.gz
share/mk/: Reduce the work of 'make && make install'
Distros expect 'make' to build only what they need. While we want to build more stuff upstream, for various reasons (mainly, for extra diagnostics), packagers only want what they'll use, and don't want to waste CPU time with that. Also, distros expect 'make install' to only install what they'll use, which is just the manual pages. For that, repurpose the build and install targets to do precisely that, and add build-all and install-all targets that do all that can be done. Reported-by: Sam James <sam@gentoo.org> Signed-off-by: Alejandro Colomar <alx@kernel.org> Cherry-picked-from: liba2i.git 791f163b1a72 (2024-07-18, "share/mk/: Reduce the work of 'make && make install'") Signed-off-by: Alejandro Colomar <alx@kernel.org>
-rw-r--r--share/mk/build/_.mk8
-rw-r--r--share/mk/dist/check/_.mk4
-rw-r--r--share/mk/install/_.mk3
3 files changed, 11 insertions, 4 deletions
diff --git a/share/mk/build/_.mk b/share/mk/build/_.mk
index 9bdcbd6b7e..b41bcfa82f 100644
--- a/share/mk/build/_.mk
+++ b/share/mk/build/_.mk
@@ -12,8 +12,8 @@ include $(MAKEFILEDIR)/configure/directory_variables/build.mk
_MANDIR := $(builddir)/man
-.PHONY: build
-build: \
+.PHONY: build-all
+build-all: \
build-catman \
build-html \
build-man \
@@ -21,5 +21,9 @@ build: \
build-ps \
build-ex;
+.PHONY: build
+build: \
+ build-man;
+
endif # include guard
diff --git a/share/mk/dist/check/_.mk b/share/mk/dist/check/_.mk
index d0a3b5df9b..ce6441805f 100644
--- a/share/mk/dist/check/_.mk
+++ b/share/mk/dist/check/_.mk
@@ -33,8 +33,8 @@ distcheck-%: $(_DISTCHECKSRCDIR) $(MK) | $$(@D)/
.PHONY: distcheck
distcheck: distcheck-diffoscope
distcheck: $(_DISTCHECKSRCDIR) $(MK)
- $(info $(INFO_)MAKE lint build install dist)
- $(MAKE) $(_MAKE_OPTS) lint build install dist \
+ $(info $(INFO_)MAKE lint build-all install-all dist)
+ $(MAKE) $(_MAKE_OPTS) lint build-all install-all dist \
'INFO_= distcheck: '
$(info $(INFO_)MAKE check)
$(MAKE) $(_MAKE_OPTS) check \
diff --git a/share/mk/install/_.mk b/share/mk/install/_.mk
index e4a0f3e339..c78ee6b0bb 100644
--- a/share/mk/install/_.mk
+++ b/share/mk/install/_.mk
@@ -19,6 +19,9 @@ include $(MAKEFILEDIR)/configure/build-depends/coreutils/rm.mk
$(RM) $*
+.PHONY: install-all
+install-all: install-man;
+
.PHONY: install
install: install-man;