xref: /OK3568_Linux_fs/external/security/rk_tee_user/v2/scripts/common.mk (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593Smuzhiyun# Makefile script used in various OP-TEE test components
2*4882a593Smuzhiyun
3*4882a593Smuzhiyun# Since 'clean' make rules rely on 'rmdir', removed directories shall
4*4882a593Smuzhiyun# not end with 'current directory' (./ or .) subpath information.
5*4882a593Smuzhiyun# This macro remove trailing './' info from input path.
6*4882a593Smuzhiyundefine strip-trailing-slashes-and-dots
7*4882a593Smuzhiyun$(eval _o := $(patsubst %/,%,$(patsubst %/.,%,$(1))))$(if \
8*4882a593Smuzhiyun	$(filter-out $(1),$(_o)),$(call strip-trailing-slashes-and-dots,$(_o)),$(_o))
9*4882a593Smuzhiyunendef
10