purge-locales: further refactoring after removing man paths
Since the man paths have been removed, it is no longer necessary to grep them out and the loop can be simplified. Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
This commit is contained in:
parent
89d39fc7a3
commit
805240bae8
4
Makefile
4
Makefile
@ -546,9 +546,9 @@ define PURGE_LOCALES
|
|||||||
|
|
||||||
for dir in $(wildcard $(addprefix $(TARGET_DIR),/usr/share/locale /usr/share/X11/locale /usr/lib/locale)); \
|
for dir in $(wildcard $(addprefix $(TARGET_DIR),/usr/share/locale /usr/share/X11/locale /usr/lib/locale)); \
|
||||||
do \
|
do \
|
||||||
for lang in $$(cd $$dir; ls .|grep -v man); \
|
for langdir in $$dir/*; \
|
||||||
do \
|
do \
|
||||||
grep -qx $$lang $(LOCALE_WHITELIST) || rm -rf $$dir/$$lang; \
|
grep -qx $${langdir##*/} $(LOCALE_WHITELIST) || rm -rf $$langdir; \
|
||||||
done; \
|
done; \
|
||||||
done
|
done
|
||||||
endef
|
endef
|
||||||
|
Loading…
Reference in New Issue
Block a user