{"thread":{"id":"8399","subject":"[PATCH] Allow CFLAGS to be overridden while preserving VERSION","startedAt":"2007-06-02T17:14:50Z","lastAt":"2007-06-02T18:35:17Z","messageCount":2,"participants":["James Bowes","Jonas Fonseca"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"43813","messageId":"118080449045-git-send-email-jbowes@dangerouslyinc.com","threadId":"8399","inReplyTo":null,"subject":"[PATCH] Allow CFLAGS to be overridden while preserving VERSION","fromName":"James Bowes","fromEmail":"jbowes@dangerouslyinc.com","sentAt":"2007-06-02T17:14:50Z","receivedAt":"2007-06-02T17:14:50Z","isPatch":true,"sender":{"key":"jbowes@dangerouslyinc.com","avatar":"https://gravatar.com/avatar/a2fe98c66b2b47a9fa9d2ba92ff949d54c3208b1f8acc2e745b4b84ae3c4483a?d=mp&s=160"},"body":"If someone defined their own CFLAGS, they would have to include a -DVERSION=\nas well (or else get unknown-version as the version).\n\nSigned-off-by: James Bowes <jbowes@dangerouslyinc.com>\n---\n Makefile |    4 +++-\n 1 files changed, 3 insertions(+), 1 deletions(-)\n\ndiff --git a/Makefile b/Makefile\nindex 61fc86b..91cb097 100644\n--- a/Makefile\n+++ b/Makefile\n@@ -20,7 +20,7 @@ endif\n RPM_VERSION = $(subst -,.,$(VERSION))\n \n LDLIBS\t= -lcurses\n-CFLAGS\t= -Wall -O2 '-DVERSION=\"$(VERSION)\"'\n+CFLAGS\t= -Wall -O2\n DFLAGS\t= -g -DDEBUG -Werror\n PROGS\t= tig\n MANDOC\t= tig.1 tigrc.5\n@@ -28,6 +28,8 @@ HTMLDOC = tig.1.html tigrc.5.html manual.html README.html\n ALLDOC\t= $(MANDOC) $(HTMLDOC) manual.html-chunked manual.pdf\n TARNAME\t= tig-$(RPM_VERSION)\n \n+override CFLAGS += '-DVERSION=\"$(VERSION)\"'\n+\n all: $(PROGS)\n all-debug: $(PROGS)\n all-debug: CFLAGS += $(DFLAGS)\n-- \n1.5.2.888.g96a5e\n"},{"id":"43820","messageId":"20070602183517.GD19952@diku.dk","threadId":"8399","inReplyTo":"118080449045-git-send-email-jbowes@dangerouslyinc.com","subject":"Re: [PATCH] Allow CFLAGS to be overridden while preserving VERSION","fromName":"Jonas Fonseca","fromEmail":"fonseca@diku.dk","sentAt":"2007-06-02T18:35:17Z","receivedAt":"2007-06-02T18:35:17Z","isPatch":true,"sender":{"key":"fonseca@diku.dk","avatar":"https://gravatar.com/avatar/f82f3ad698717c51873b020c750a92438c820a24056dc39fe4d07baa10a92264?d=mp&s=160"},"body":"James Bowes <jbowes@dangerouslyinc.com> wrote Sat, Jun 02, 2007:\n> If someone defined their own CFLAGS, they would have to include a -DVERSION=\n> as well (or else get unknown-version as the version).\n\nThank you, applied and pushed out.\n\n-- \nJonas Fonseca\n"}]}