From 12fd53c27e133ed4e79c2f5a85ea8fb038c23b12 Mon Sep 17 00:00:00 2001 From: bas smit Date: Wed, 26 Jun 2013 13:25:20 +0200 Subject: [PATCH 1/2] Add debug target to the template makefile If the DEBUG variable is set (e.g. DEBUG=1 make target) debugging will be enabled by using pelicans -D flag. --- pelican/tools/templates/Makefile.in | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pelican/tools/templates/Makefile.in b/pelican/tools/templates/Makefile.in index 221568aa..fd553550 100644 --- a/pelican/tools/templates/Makefile.in +++ b/pelican/tools/templates/Makefile.in @@ -20,6 +20,11 @@ S3_BUCKET=$s3_bucket DROPBOX_DIR=$dropbox_dir +DEBUG ?= 0 +ifeq ($(DEBUG), 1) + PELICANOPTS += -D +endif + help: @echo 'Makefile for a pelican Web site ' @echo ' ' From 0d63b4520a302d5fb8e249c1d98c0043c566315b Mon Sep 17 00:00:00 2001 From: bas smit Date: Wed, 26 Jun 2013 13:58:35 +0200 Subject: [PATCH 2/2] Add info about debugging to the help output of the makefile --- pelican/tools/templates/Makefile.in | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pelican/tools/templates/Makefile.in b/pelican/tools/templates/Makefile.in index fd553550..80cf4737 100644 --- a/pelican/tools/templates/Makefile.in +++ b/pelican/tools/templates/Makefile.in @@ -43,7 +43,8 @@ help: @echo ' s3_upload upload the web site via S3 ' @echo ' github upload the web site via gh-pages ' @echo ' ' - + @echo 'Set the DEBUG variable to 1 to enable debugging, e.g. make DEBUG=1 html' + @echo ' ' html: clean $$(OUTPUTDIR)/index.html