TARGET = output_control
Dir2store = /opt/Rockchip/external/X10/etc/scripts
objects = *.o
CFLAGS = -lpthread -lhiredis -lm -liniparser -lcjson

${TARGET}:$(objects)
	${CC} -o $@ $(objects) $(CFLAGS)

%.o:%.c
	${CC} -c $<

.PHONY:clean install uninstall

clean:
	rm -f *.o ${TARGET}

install:
	cp -f ${TARGET} ${Dir2store}

uninstall:
	rm -f ${Dir2store}/${TARGET}
