ML_FILES=$(wildcard *.ml) NATIVE_FILES=$(patsubst %.ml,%.native,$(ML_FILES)) all: build build: $(NATIVE_FILES) clean: rm -f $(NATIVE_FILES) %.native: %.ml corebuild $@ .PHONY: all build clean