[build] add startswith/endswith functions