X-Git-Url: http://git.grml.org/?p=live-boot-grml.git;a=blobdiff_plain;f=Makefile;h=7be7e682102bd0ab8ec029ac9762b33be0d804dc;hp=232d144967f16f8464d5f745516b2508275c9dbe;hb=HEAD;hpb=376114ff58367b9fdb84f6d1c4c4ce3a2f8ad261 diff --git a/Makefile b/Makefile index 232d144..c64c8c3 100644 --- a/Makefile +++ b/Makefile @@ -4,7 +4,7 @@ SHELL := sh -e LANGUAGES = $(shell cd manpages/po && ls) -SCRIPTS = backends/*/* bin/* scripts/*.sh scripts/*/* +SCRIPTS = backend/*/* frontend/* components/* all: build @@ -31,39 +31,36 @@ test: echo " done."; \ else \ echo "W: checkbashisms - command not found"; \ - echo "I: checkbashisms can be optained from: "; \ - echo "I: http://git.debian.org/?p=devscripts/devscripts.git"; \ + echo "I: checkbashisms can be obtained from: "; \ + echo "I: https://salsa.debian.org/debian/devscripts.git"; \ echo "I: On Debian based systems, checkbashisms can be installed with:"; \ echo "I: apt-get install devscripts"; \ fi build: - @echo "Nothing to build." + $(MAKE) -C $(CURDIR)/manpages install: - # Installing scripts - mkdir -p $(DESTDIR)/lib/live - cp -r scripts/boot.sh scripts/boot $(DESTDIR)/lib/live + # Installing components + mkdir -p $(DESTDIR)/lib/live/boot + cp components/* $(DESTDIR)/lib/live/boot # Installing executables - mkdir -p $(DESTDIR)/sbin - cp bin/live-new-uuid bin/live-snapshot bin/live-swapfile $(DESTDIR)/sbin - - mkdir -p $(DESTDIR)/usr/share/live-boot - cp bin/live-preseed bin/live-reconfigure $(DESTDIR)/usr/share/live-boot - mkdir -p $(DESTDIR)/usr/share/initramfs-tools/hooks - cp backends/initramfs-tools/live.hook $(DESTDIR)/usr/share/initramfs-tools/hooks/live + for f in backend/initramfs-tools/*.hook; do \ + cp $${f} $(DESTDIR)/usr/share/initramfs-tools/hooks/$$(basename $${f} .hook); \ + done mkdir -p $(DESTDIR)/usr/share/initramfs-tools/scripts - cp backends/initramfs-tools/live.script $(DESTDIR)/usr/share/initramfs-tools/scripts/live + for f in backend/initramfs-tools/*.script; do \ + cp $${f} $(DESTDIR)/usr/share/initramfs-tools/scripts/$$(basename $${f} .script); \ + done - # Installing docs - mkdir -p $(DESTDIR)/usr/share/doc/live-boot - cp -r COPYING $(DESTDIR)/usr/share/doc/live-boot + mkdir -p $(DESTDIR)/bin + cp frontend/* $(DESTDIR)/bin - mkdir -p $(DESTDIR)/usr/share/doc/live-boot/examples - cp -r examples/* $(DESTDIR)/usr/share/doc/live-boot/examples - # (FIXME) + # Installing docs + mkdir -p $(DESTDIR)/usr/share/doc/live-boot-grml + cp -r COPYING $(DESTDIR)/usr/share/doc/live-boot-grml # Installing manpages for MANPAGE in manpages/en/*; \ @@ -83,10 +80,9 @@ install: uninstall: # Uninstalling executables - rm -f $(DESTDIR)/sbin/live-snapshot $(DESTDIR)/sbin/live-swapfile - rmdir --ignore-fail-on-non-empty $(DESTDIR)/sbin > /dev/null 2>&1 || true - - rm -rf $(DESTDIR)/usr/share/live-boot + rm -f $(DESTDIR)/bin/live-boot + rm -f $(DESTDIR)/bin/live-swapfile + rmdir --ignore-fail-on-non-empty $(DESTDIR)/bin > /dev/null 2>&1 || true rm -f $(DESTDIR)/usr/share/initramfs-tools/hooks/live rm -f $(DESTDIR)/usr/share/initramfs-tools/scripts/live @@ -98,7 +94,7 @@ uninstall: rmdir --ignore-fail-on-non-empty $(DESTDIR)/usr > /dev/null 2>&1 || true # Uninstalling docs - rm -rf $(DESTDIR)/usr/share/doc/live-boot + rm -rf $(DESTDIR)/usr/share/doc/live-boot-grml rmdir --ignore-fail-on-non-empty $(DESTDIR)/usr/share/doc > /dev/null 2>&1 || true rmdir --ignore-fail-on-non-empty $(DESTDIR)/usr/share > /dev/null 2>&1 || true rmdir --ignore-fail-on-non-empty $(DESTDIR)/usr > /dev/null 2>&1 || true