Making common code reusable as there's a lot of duplicate code in imx6, kirkwood and oxnas archs.
Signed-off-by: Petr Štetiar <yn...@true.cz> --- include/image.mk | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/include/image.mk b/include/image.mk index 4e22fa5..3f65568 100644 --- a/include/image.mk +++ b/include/image.mk @@ -89,6 +89,16 @@ define toupper $(shell echo $(1) | tr '[:lower:]' '[:upper:]') endef +define tolower +$(shell echo $(1) | tr '[:upper:]' '[:lower:]') +endef + +define sanitize +$(shell echo $(call tolower,$(1)) | sed 's/_/-/g') +endef + +PROFILE_SANITIZED := $(call sanitize,$(PROFILE)) + define split_args $(foreach data, \ $(subst |,$(space),\ -- 1.7.9.5 _______________________________________________ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel