users-guide: Clean manpage build artifacts and fix usage of clean-target
authorBen Gamari <bgamari.foss@gmail.com>
Sun, 17 Jan 2016 18:26:03 +0000 (19:26 +0100)
committerBen Gamari <ben@smart-cactus.org>
Sun, 17 Jan 2016 22:40:42 +0000 (23:40 +0100)
Test Plan: Build then clean

Reviewers: austin, thomie

Reviewed By: thomie

Differential Revision: https://phabricator.haskell.org/D1786

GHC Trac Issues: #11433

docs/users_guide/ghc.mk
rules/sphinx.mk

index 83cf60a..9144a07 100644 (file)
@@ -30,6 +30,8 @@ $(MAN_PAGES): $(docs/users_guide_MAN_RST_SOURCES) $(utils/mkUserGuidePart_GENERA
        $(SPHINXBUILD) -b man -d docs/users_guide/.doctrees-man docs/users_guide docs/users_guide/build-man
 endif
 
+$(eval $(call clean-target,users-guide,manpage,docs/users_guide/.doctrees-man/ docs/users_guide/build-man/))
+
 man : $(MAN_PAGES)
 
 ifeq "$(BUILD_MAN)" "YES"
index 5a3c7ce..7337242 100644 (file)
@@ -22,7 +22,7 @@ $(call profStart, sphinx($1,$2))
 # $1 = dir
 # $2 = docname
 
-$(call clean-target,$1,sphinx,$1/.doctrees-html/ $1/.doctrees-pdf/ $1/build-html/ $1/build-pdf/ $1/$2.pdf)
+$(eval $(call clean-target,$1,sphinx,$1/.doctrees-html/ $1/.doctrees-pdf/ $1/build-html/ $1/build-pdf/ $1/$2.pdf))
 
 # empty "all_$1" target just in case we're not building docs at all
 $(call all-target,$1,)