aboutsummaryrefslogtreecommitdiff
path: root/ghc.mk
diff options
context:
space:
mode:
authorIan Lynagh <igloo@earth.li>2010-08-01 18:09:54 +0000
committerIan Lynagh <igloo@earth.li>2010-08-01 18:09:54 +0000
commit2fe0d8ccb56589b113b8b0eb32909206038e95d7 (patch)
tree7ef7620099f9e0b1119b28949b095cc96b635346 /ghc.mk
parent06b46e0085741d0c84aedc32de15251785eeceb2 (diff)
Make the main haddock script versioned, and make plain "haddock" a symlink
Diffstat (limited to 'ghc.mk')
-rw-r--r--ghc.mk9
1 files changed, 9 insertions, 0 deletions
diff --git a/ghc.mk b/ghc.mk
index 8ba7e11e..bc44b13d 100644
--- a/ghc.mk
+++ b/ghc.mk
@@ -5,6 +5,7 @@ utils/haddock_CONFIGURE_OPTS = --flag in-ghc-tree
utils/haddock_HC_OPTS += -DNEW_GHC_LAYOUT
utils/haddock_dist_SHELL_WRAPPER = YES
utils/haddock_dist_INSTALL_SHELL_WRAPPER = YES
+utils/haddock_dist_INSTALL_SHELL_WRAPPER_NAME = haddock-$(ProjectVersion)
utils/haddock_dist_PROG = haddock$(exeext)
ifneq "$(BINDIST)" "YES"
@@ -39,5 +40,13 @@ install_utils/haddock_data:
$(INSTALL_DATA) $(INSTALL_OPTS) $$i "$(DESTDIR)$(ghclibdir)/html"; \
done
+ifeq "$(Windows)" "NO"
+install: install_haddock_link
+.PNONY: install_haddock_link
+install_haddock_link:
+ "$(RM)" $(RM_OPTS) "$(DESTDIR)$(bindir)/haddock"
+ $(LN_S) haddock-$(ProjectVersion) "$(DESTDIR)$(bindir)/haddock"
+endif
+
BINDIST_EXTRAS += $(addprefix utils/haddock/,html/*)