From 4dc3c1ad4d317a6bb59db4295eb0edfbfbaa5d6f Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Mon, 1 Oct 2012 12:01:33 +0200 Subject: Makefile: less output --- Makefile | 54 +++++++++++++++++++++++++++++++----------------------- 1 file changed, 31 insertions(+), 23 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 89e2578..3870e21 100644 --- a/Makefile +++ b/Makefile @@ -6,43 +6,51 @@ DATE=$(shell date +%F_%T) all: initramfs initramfs: initramfs.cpio - gzip > initramfs < initramfs.cpio + @echo "Compressing archive" + @gzip > initramfs < initramfs.cpio initramfs.cpio: .root-done/.complete - cd root ;\ - find . | cpio -H newc -o > ../initramfs.cpio + @echo "Generating cpio archive" + @cd root ;\ + find . | cpio -H newc --quiet -o > ../initramfs.cpio .root-done/.complete: $(CONTENT-MARKER) .root-done/.links - touch .root-done/.complete + @touch .root-done/.complete $(CONTENT-MARKER): .root-done/%: % - -ldd $* | cut -d" " -f 3 | while read i ; do \ - if [ -n "$$i" ]; then \ - mkdir -p $$(dirname $$i) ;\ - cp --parents $$i root/ ;\ - fi ;\ - done - - -ldd $* | grep -v "=>" | cut -f1 -d" " | while read i ; do \ - if [ -n "$$i" ]; then \ - mkdir -p $$(dirname $$i) ;\ - cp --parents $$i root/ ;\ - fi ;\ - done + @echo "Installing $*" + @if ldd $* > /dev/null 2>&1 ; then \ + ldd $* | cut -d" " -f 3 | while read i ; do \ + if [ -n "$$i" ]; then \ + mkdir -p $$(dirname $$i) ;\ + cp --parents $$i root/ ;\ + echo -e "\tCopy library: $$i" ;\ + fi ;\ + done ;\ + \ + ldd $* | grep -v "=>" | cut -f1 -d" " | while read i ; do \ + if [ -n "$$i" ]; then \ + mkdir -p $$(dirname $$i) ;\ + cp --parents $$i root/ ;\ + echo -e "\tCopy library: $$i" ;\ + fi ;\ + done #;\ + fi - mkdir -p $(shell dirname $*) - cp -a --parents $* root/ + @mkdir -p $(shell dirname $*) + @cp -a --parents $* root/ - mkdir -p $(dir .root-done/$*) - touch .root-done/$* + @mkdir -p $(dir .root-done/$*) + @touch .root-done/$* + @echo .root-done/.links: Makefile - for i in $(CONTENT-LINKS) ; do \ + @for i in $(CONTENT-LINKS) ; do \ mkdir -p $$(dirname $$i) ;\ cp -a --parents $$i root/ ;\ done - touch .root-done/.static + @touch .root-done/.static $(CONTENT-MARKER): Makefile -- cgit v1.2.3