From fcd49f12493d6d47c128693e14b3f29ebe7bba42 Mon Sep 17 00:00:00 2001 From: "A. Wilcox" Date: Wed, 25 Oct 2023 03:02:09 -0500 Subject: Makefile: Use pattern matching for DE media This drastically simplifies adding new DEs and removes a lot of repetitive rules. --- Makefile | 21 ++------------------- 1 file changed, 2 insertions(+), 19 deletions(-) diff --git a/Makefile b/Makefile index 0d25c38..00315dd 100644 --- a/Makefile +++ b/Makefile @@ -18,14 +18,6 @@ help: @printf "\nYou must set ARCH to a supported architecture.\n" @printf "Note that if you don't set ARCH to the native arch of your host,\nyou probably need qemu-user installed.\n" -# This target only exists so the ARCH check runs before any other Make code. -check-env: - @printf "Please choose something to build!\n\nTry 'inst', 'iso', 'world', or 'help' for a complete list.\n" - -ifndef ARCH - $(error Set ARCH first) -endif - adelie-inst-firmware-$(ARCH)-$(VERSION).iso: configs/horizon/$(ARCH)-horizon-fw.installfile configs/horizon/firmware.installfile configs/horizon/horizon.installfile configs/arch/$(ARCH).installfile configs/base/base.installfile hscript-image -t iso -o adelie-inst-firmware-$(ARCH)-$(VERSION).iso configs/horizon/$(ARCH)-horizon-fw.installfile @@ -34,17 +26,8 @@ adelie-inst-$(ARCH)-$(VERSION).iso: configs/horizon/$(ARCH)-horizon.installfile inst: adelie-inst-firmware-$(ARCH)-$(VERSION).iso adelie-inst-$(ARCH)-$(VERSION).iso -adelie-live-kde-$(ARCH)-$(VERSION).iso: configs/live/$(ARCH)-kde.installfile configs/base/kde.installfile configs/arch/$(ARCH).installfile configs/base/base.installfile - hscript-image -t iso -o adelie-live-kde-$(ARCH)-$(VERSION).iso configs/live/$(ARCH)-kde.installfile - -adelie-live-lxqt-$(ARCH)-$(VERSION).iso: configs/live/$(ARCH)-lxqt.installfile configs/base/lxqt.installfile configs/arch/$(ARCH).installfile configs/base/base.installfile - hscript-image -t iso -o adelie-live-lxqt-$(ARCH)-$(VERSION).iso configs/live/$(ARCH)-lxqt.installfile - -adelie-live-mate-$(ARCH)-$(VERSION).iso: configs/live/$(ARCH)-mate.installfile configs/base/mate.installfile configs/arch/$(ARCH).installfile configs/base/base.installfile - hscript-image -t iso -o adelie-live-mate-$(ARCH)-$(VERSION).iso configs/live/$(ARCH)-mate.installfile - -adelie-live-xfce-$(ARCH)-$(VERSION).iso: configs/live/$(ARCH)-xfce.installfile configs/base/xfce.installfile configs/arch/$(ARCH).installfile configs/base/base.installfile - hscript-image -t iso -o adelie-live-xfce-$(ARCH)-$(VERSION).iso configs/live/$(ARCH)-xfce.installfile +adelie-live-%-$(ARCH)-$(VERSION).iso: configs/live/$(ARCH)-%.installfile configs/base/%.installfile configs/arch/$(ARCH).installfile configs/base/base.installfile + hscript-image -t iso -o adelie-live-$*-$(ARCH)-$(VERSION).iso configs/live/$(ARCH)-$*.installfile kde: adelie-live-kde-$(ARCH)-$(VERSION).iso lxqt: adelie-live-lxqt-$(ARCH)-$(VERSION).iso -- cgit v1.2.3-70-g09d2