py/mkrules.mk: Rework find command so it works on OSX.

The Mac version of find doesn't support -printf, so this changes
things to use sed to strip off the leading path element instead.
pull/2630/head
Dave Hylands 2016-11-14 11:02:49 -08:00 zatwierdzone przez Damien George
rodzic a0b2c6ad32
commit 0400fa45ba
1 zmienionych plików z 1 dodań i 1 usunięć

Wyświetl plik

@ -108,7 +108,7 @@ endif
ifneq ($(FROZEN_MPY_DIR),)
# make a list of all the .py files that need compiling and freezing
FROZEN_MPY_PY_FILES := $(shell find -L $(FROZEN_MPY_DIR) -type f -name '*.py' -printf '%P\n')
FROZEN_MPY_PY_FILES := $(shell find -L $(FROZEN_MPY_DIR) -type f -name '*.py' | sed -e 's=^$(FROZEN_MPY_DIR)/==')
FROZEN_MPY_MPY_FILES := $(addprefix $(BUILD)/frozen_mpy/,$(FROZEN_MPY_PY_FILES:.py=.mpy))
# to build .mpy files from .py files