{"thread":{"id":"173","subject":"simplify Makefile","startedAt":"2005-04-20T12:19:03Z","lastAt":"2005-04-20T12:19:03Z","messageCount":1,"participants":["Andre Noll"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"974","messageId":"20050420121903.GA8664@skl-net.de","threadId":"173","inReplyTo":null,"subject":"simplify Makefile","fromName":"Andre Noll","fromEmail":"maan@systemlinux.org","sentAt":"2005-04-20T12:19:03Z","receivedAt":"2005-04-20T12:19:03Z","isPatch":false,"sender":{"key":"maan@systemlinux.org","avatar":null},"body":"Use a generic rule for executables that depend only on the corresponding\n.o and on $(LIB_FILE).\n\nSigned-Off-By: Andre Noll <maan@systemlinux.org>\n---\n\nMakefile |   49 ++-----------------------------------------------\n 1 files changed, 2 insertions(+), 47 deletions(-)\n\nMakefile: cd299f850679b2456e360d3aa6a2d529855ba7a5\n--- a/Makefile\n+++ b/Makefile\n@@ -34,62 +34,17 @@ LIBS= $(LIB_FILE) -lssl -lz\n \n init-db: init-db.o\n \n-update-cache: update-cache.o $(LIB_FILE)\n-\t$(CC) $(CFLAGS) -o update-cache update-cache.o $(LIBS)\n-\n-show-diff: show-diff.o $(LIB_FILE)\n-\t$(CC) $(CFLAGS) -o show-diff show-diff.o $(LIBS)\n-\n-write-tree: write-tree.o $(LIB_FILE)\n-\t$(CC) $(CFLAGS) -o write-tree write-tree.o $(LIBS)\n-\n-read-tree: read-tree.o $(LIB_FILE)\n-\t$(CC) $(CFLAGS) -o read-tree read-tree.o $(LIBS)\n-\n-commit-tree: commit-tree.o $(LIB_FILE)\n-\t$(CC) $(CFLAGS) -o commit-tree commit-tree.o $(LIBS)\n-\n-cat-file: cat-file.o $(LIB_FILE)\n-\t$(CC) $(CFLAGS) -o cat-file cat-file.o $(LIBS)\n-\n fsck-cache: fsck-cache.o $(LIB_FILE) object.o commit.o tree.o blob.o\n \t$(CC) $(CFLAGS) -o fsck-cache fsck-cache.o $(LIBS)\n \n-checkout-cache: checkout-cache.o $(LIB_FILE)\n-\t$(CC) $(CFLAGS) -o checkout-cache checkout-cache.o $(LIBS)\n-\n-diff-tree: diff-tree.o $(LIB_FILE)\n-\t$(CC) $(CFLAGS) -o diff-tree diff-tree.o $(LIBS)\n-\n rev-tree: rev-tree.o $(LIB_FILE) object.o commit.o tree.o blob.o\n \t$(CC) $(CFLAGS) -o rev-tree rev-tree.o $(LIBS)\n \n-show-files: show-files.o $(LIB_FILE)\n-\t$(CC) $(CFLAGS) -o show-files show-files.o $(LIBS)\n-\n-check-files: check-files.o $(LIB_FILE)\n-\t$(CC) $(CFLAGS) -o check-files check-files.o $(LIBS)\n-\n-ls-tree: ls-tree.o $(LIB_FILE)\n-\t$(CC) $(CFLAGS) -o ls-tree ls-tree.o $(LIBS)\n-\n merge-base: merge-base.o $(LIB_FILE) object.o commit.o tree.o blob.o\n \t$(CC) $(CFLAGS) -o merge-base merge-base.o $(LIBS)\n \n-merge-cache: merge-cache.o $(LIB_FILE)\n-\t$(CC) $(CFLAGS) -o merge-cache merge-cache.o $(LIBS)\n-\n-unpack-file: unpack-file.o $(LIB_FILE)\n-\t$(CC) $(CFLAGS) -o unpack-file unpack-file.o $(LIBS)\n-\n-git-export: git-export.o $(LIB_FILE)\n-\t$(CC) $(CFLAGS) -o git-export git-export.o $(LIBS)\n-\n-diff-cache: diff-cache.o $(LIB_FILE)\n-\t$(CC) $(CFLAGS) -o diff-cache diff-cache.o $(LIBS)\n-\n-convert-cache: convert-cache.o $(LIB_FILE)\n-\t$(CC) $(CFLAGS) -o convert-cache convert-cache.o $(LIBS)\n+%: %.o $(LIB_FILE)\n+\t$(CC) $(CFLAGS) -o $@ $< $(LIBS)\n \n blob.o: $(LIB_H)\n cat-file.o: $(LIB_H)\n"}]}