Skip to content

Commit

Permalink
Makefiles: Tidy up output
Browse files Browse the repository at this point in the history
A few things were making the make output inconsistent and causing it to
print bad paths. Fix these:
* Define $RELATIVE_DIR in Makefile.quiet if not defined (eg docs case)
* Print a line when executing in envoy/ to provide context for message
* Fix up usage of $(ECHO_CHECK)

Signed-off-by: Joe Stringer <[email protected]>
  • Loading branch information
joestringer authored and ianvernon committed Jan 24, 2019
1 parent 31e11e1 commit 3213ec6
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 6 deletions.
6 changes: 5 additions & 1 deletion Makefile.quiet
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
ifeq ($(ROOT_DIR),)
ROOT_DIR ?= $(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))
RELATIVE_DIR ?= $(shell echo $(realpath .) | sed "s;$(ROOT_DIR)[/]*;;")
endif
ifeq ($(V),0)
QUIET=@
ECHO_CC=echo " CC $(RELATIVE_DIR)/$@"
ECHO_GEN=echo " GEN $(RELATIVE_DIR)/"
ECHO_GO=echo " GO $(RELATIVE_DIR)/$@"
ECHO_CHECK=echo " CHECK $(RELATIVE_DIR)"
ECHO_CHECK=echo " CHECK$(RELATIVE_DIR)"
ECHO_GINKGO=echo " GINKG $(RELATIVE_DIR)"
ECHO_CLEAN=echo " CLEAN $(RELATIVE_DIR)"
SPHINXOPTS+="-q"
Expand Down
2 changes: 1 addition & 1 deletion daemon/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ endif

.PHONY: check-bindata
check-bindata: bindata.go
@$(ECHO_CHECK) contrib/scripts/bindata.sh
@echo " CHECK contrib/scripts/bindata.sh"
$(QUIET) ../contrib/scripts/bindata.sh $(GO_BINDATA_SHA1SUM)

apply-bindata: go-bindata
Expand Down
10 changes: 6 additions & 4 deletions envoy/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 2017 Authors of Cilium
# Copyright 2017-2019 Authors of Cilium
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -18,17 +18,19 @@ include ../Makefile.defs
ifdef PKG_BUILD

all:
echo "cilium-envoy has been moved to github.com/cilium/proxy"
@echo " SKIP $(RELATIVE_DIR)/"
@echo "cilium-envoy has been moved to github.com/cilium/proxy"

install:
echo "cilium-envoy must be installed separately"
@echo "cilium-envoy must be installed separately"

clean:

else

all:
echo "cilium-envoy has been moved to github.com/cilium/proxy"
@echo " SKIP $(RELATIVE_DIR)/"
@echo "cilium-envoy has been moved to github.com/cilium/proxy"

install:
ifndef DISABLE_ENVOY_INSTALLATION
Expand Down

0 comments on commit 3213ec6

Please sign in to comment.