From 580c6d9b448ea8db5c9fe8f99aa43967d297903b Mon Sep 17 00:00:00 2001 From: Thomas Petazzoni Date: Thu, 30 Jul 2009 17:26:49 +0200 Subject: makefile: new qstrip make function Define a qstrip function that strips double quotes and then whitespaces around a given string. This is a very commonly needed thing, and having a function allows to remove a large quantity of hand-written definitions, followed by a dummy comment to make text editors not crazy because of the unmatching double quote. Signed-off-by: Thomas Petazzoni --- Makefile | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 568348494..fd272b5f2 100644 --- a/Makefile +++ b/Makefile @@ -40,6 +40,10 @@ else BR2_LOCAL:=$(TOPDIR)/local endif +# Strip quotes and then whitespaces +qstrip=$(strip $(subst ",,$(1))) +#")) + # Variables for use in Make constructs comma:=, empty:= -- cgit v1.2.3 From 6cdf2481ee620843d56391a7a658c04b772d6c19 Mon Sep 17 00:00:00 2001 From: Thomas Petazzoni Date: Thu, 30 Jul 2009 17:28:20 +0200 Subject: makefile: use qstrip Signed-off-by: Thomas Petazzoni --- Makefile | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index fd272b5f2..f2e349f27 100644 --- a/Makefile +++ b/Makefile @@ -373,8 +373,7 @@ endif ifeq ($(BR2_ENABLE_LOCALE_PURGE),y) LOCALE_WHITELIST=$(PROJECT_BUILD_DIR)/locales.nopurge -LOCALE_NOPURGE=$(strip $(subst ",,$(BR2_ENABLE_LOCALE_WHITELIST))) -#")) +LOCALE_NOPURGE=$(call qstrip,$(BR2_ENABLE_LOCALE_WHITELIST)) target-purgelocales: rm -f $(LOCALE_WHITELIST) -- cgit v1.2.3