From 408e56445dfb2818ec3c8e462686ebe958714baa Mon Sep 17 00:00:00 2001 From: Mark Wooding Date: Tue, 18 Jun 2024 23:37:37 +0100 Subject: [PATCH] Makefile: Add `help' summary. --- Makefile | 38 +++++++++++++++++++++++++++++++++++++- 1 file changed, 37 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index c4670ac..1a25369 100644 --- a/Makefile +++ b/Makefile @@ -27,7 +27,8 @@ all: clean:: check:: -.PHONY: all clean check +help:: +.PHONY: all clean check help .SECONDEXPANSION: #sorry ###-------------------------------------------------------------------------- @@ -35,11 +36,20 @@ check:: CONFIG_VARS = +help:: + @echo "Configuration variables" + ## Make verbosity. V = 0 +help::; @echo " V build verbosity" ## Level of pickiness to aspire to. NOTIFY_FATAL = 1 +help:: + @echo " NOTIFY_FATAL report fatal error on ..." && \ + echo " 1 = error" && \ + echo " 2 = warning" && \ + echo " 3 = info" ## Volume group from which to allocate chroot volumes and snapshots. CONFIG_VARS += VG LVPREFIX @@ -209,12 +219,14 @@ TOOLSARCH = $(MYARCH) ## A directory in which we can maintain private files and state. CONFIG_VARS += STATE STATE = state +help::; @echo " STATE directory for state files" ## A directory which will be spliced into chroots as `/usr/local.schroot/'. ## This will be our primary point of contact with the chroot. CONFIG_VARS += LOCAL ABSLOCAL LOCAL = local.schroot ABSLOCAL = $(abspath $(LOCAL)) +help::; @echo " LOCAL directory for chroot /usr/local" ## How to run a command as a privileged user. CONFIG_VARS += ROOTLY @@ -239,6 +251,15 @@ FOREIGN_GNUARCHS := $(foreach a,$(FOREIGN_ARCHS),\ -qDEB_TARGET_GNU_TYPE)) ###-------------------------------------------------------------------------- +### Basic help. + +help:: + @echo "Basic targets" && \ + echo " all build and install the infrastructure" && \ + echo " clean delete build files" && \ + echo " check verify correct installation" + +###-------------------------------------------------------------------------- ### Utilities. ## Hack to force rebuilding. @@ -661,6 +682,21 @@ maint: all check $(MAINT) -f$(FRESH) $(JOBS) .PHONY: maint +help:: + @echo "Maintenance targets" && \ + echo " maint run chroot maintenance" && \ + echo "Maintenance variables" && \ + echo " FRESH max time between updates" && \ + echo " N[smhdw] | create | force" && \ + echo " JOBS maintenance jobs to run" && \ + echo " ACT[.PAT,...][/FRESH]" && \ + echo " OPTS additional options (bin/chroot-maint --help)" && \ + echo "Maintenance actions" && \ + echo " chroot create and populate chroot" && \ + echo " cross-tools build cross-compilation toolchains" && \ + echo " pkg-source download and unpack local utilities" && \ + echo " pkg-build compile and install local utilities" + ###-------------------------------------------------------------------------- ### Running random commands. -- 2.11.0