UIFILES := $(wildcard *.ui) PYFILES := $(UIFILES:.ui=.py) CC = python3 -m PyQt5.uic.pyuic all: $(PYFILES) %.py: %.ui $(CC) -o $@ $< clean: rm $(PYFILES)