create dependencies

This commit is contained in:
Sebastian Ramacher 2011-04-19 18:53:41 +02:00
parent a415666cc1
commit 8025225e14
4 changed files with 28 additions and 12 deletions

View file

@ -19,11 +19,13 @@ options:
%.o: %.c
@echo CC $<
@${CC} -c ${CFLAGS} -o $@ $<
@mkdir -p .depend
@${CC} -c ${CFLAGS} -o $@ $< -MMD -MF .depend/$@.dep
%.do: %.c
@echo CC $<
@${CC} -c ${CFLAGS} ${DFLAGS} -o $@ $<
@mkdir -p .depend
@${CC} -c ${CFLAGS} ${DFLAGS} -o $@ $< -MMD -MF .depend/$@.dep
${OBJECTS}: config.mk
${DOBJECTS}: config.mk
@ -34,7 +36,7 @@ ${PROJECT}: ${OBJECTS}
clean:
@rm -rf ${PROJECT} ${OBJECTS} ${PROJECT}-${VERSION}.tar.gz \
${DOBJECTS} ${PROJECT}-debug
${DOBJECTS} ${PROJECT}-debug .depend
make -C ft clean
${PROJECT}-debug: ${DOBJECTS}
@ -76,3 +78,5 @@ uninstall:
@echo removing manual page
@rm -f ${DESTDIR}${MANPREFIX}/man1/${PROJECT}.1
@make -C ft uninstall
-include $(wildcard .depend/*.dep)

View file

@ -18,11 +18,13 @@ options:
%.o: %.c
@echo CC $<
@${CC} -c ${CFLAGS} -o $@ $<
@mkdir -p .depend
@${CC} -c ${CFLAGS} -o $@ $< -MMD -MF .depend/$@.dep
%.do: %.c
@echo CC $<
@${CC} -c ${CFLAGS} ${DFLAGS} -o $@ $<
@mkdir -p .depend
@${CC} -c ${CFLAGS} ${DFLAGS} -o $@ $< -MMD -MF .depend/$@.dep
${OBJECTS}: config.mk
${DOBJECTS}: config.mk
@ -36,7 +38,7 @@ ${PLUGIN}-debug: ${DOBJECTS}
@${CC} -shared ${LDFLAGS} -o ${PLUGIN}.so $(DOBJECTS) ${LIBS}
clean:
@rm -rf ${OBJECTS} ${DOBJECTS} $(PLUGIN).so
@rm -rf ${OBJECTS} ${DOBJECTS} $(PLUGIN).so .depend
debug: options ${PLUGIN}-debug
@ -49,3 +51,5 @@ uninstall:
@echo uninstalling ${PLUGIN} plugin
@rm -f ${DESTDIR}${PREFIX}/lib/zathura/${PLUGIN}.so
@rm -rf ${DESTDIR}${PREFIX}/lib/zathura
-include $(wildcard .depend/*.dep)

View file

@ -18,11 +18,13 @@ options:
%.o: %.c
@echo CC $<
@${CC} -c ${CFLAGS} -o $@ $<
@mkdir -p .depend
@${CC} -c ${CFLAGS} -o $@ $< -MMD -MF .depend/$@.dep
%.do: %.c
@echo CC $<
@${CC} -c ${CFLAGS} ${DFLAGS} -o $@ $<
@mkdir -p .depend
@${CC} -c ${CFLAGS} ${DFLAGS} -o $@ $< -MMD -MF .depend/$@.dep
${OBJECTS}: config.mk
${DOBJECTS}: config.mk
@ -36,7 +38,7 @@ ${PLUGIN}-debug: ${DOBJECTS}
@${CC} -shared ${LDFLAGS} -o ${PLUGIN}.so $(DOBJECTS) ${LIBS}
clean:
@rm -rf ${OBJECTS} ${DOBJECTS} $(PLUGIN).so
@rm -rf ${OBJECTS} ${DOBJECTS} $(PLUGIN).so .depend
debug: options ${PLUGIN}-debug
@ -49,3 +51,5 @@ uninstall:
@echo uninstalling ${PLUGIN} plugin
@rm -f ${DESTDIR}${PREFIX}/lib/zathura/${PLUGIN}.so
@rm -rf ${DESTDIR}${PREFIX}/lib/zathura
-include $(wildcard .depend/*.dep)

View file

@ -18,11 +18,13 @@ options:
%.o: %.c
@echo CC $<
@${CC} -c ${CFLAGS} -o $@ $<
@mkdir -p .depend
@${CC} -c ${CFLAGS} -o $@ $< -MMD -MF .depend/$@.dep
%.do: %.c
@echo CC $<
@${CC} -c ${CFLAGS} ${DFLAGS} -o $@ $<
@mkdir -p .depend
@${CC} -c ${CFLAGS} ${DFLAGS} -o $@ $< -MMD -MF .depend/$@.dep
${OBJECTS}: config.mk
${DOBJECTS}: config.mk
@ -36,7 +38,7 @@ ${PLUGIN}-debug: ${DOBJECTS}
@${CC} -shared ${LDFLAGS} -o ${PLUGIN}.so $(DOBJECTS) ${LIBS}
clean:
@rm -rf ${OBJECTS} ${DOBJECTS} $(PLUGIN).so
@rm -rf ${OBJECTS} ${DOBJECTS} $(PLUGIN).so .depend
debug: options ${PLUGIN}-debug
@ -49,3 +51,5 @@ uninstall:
@echo uninstalling ${PLUGIN} plugin
@rm -f ${DESTDIR}${PREFIX}/lib/zathura/${PLUGIN}.so
@rm -rf ${DESTDIR}${PREFIX}/lib/zathura
-include $(wildcard .depend/*.dep)