git.iko.soy/typeable/pandoc
on master help sign in
* cabalize: fix cabal version detection by using a bloody hack.
fe92360roktas
Makefile+2−2
@@ -52,7 +52,7 @@ GHC_PKG := ghc-pkg
52#-------------------------------------------------------------------------------
52#-------------------------------------------------------------------------------
53
53
54.PHONY: all
54.PHONY: all
55−all: build
55+all: $(BINS)
56
56
57.PHONY: templates
57.PHONY: templates
58templates: $(SRCDIR)/templates
58templates: $(SRCDIR)/templates
@@ -136,7 +136,7 @@ install-all: install-doc install-lib-doc
136 destdir=$(DESTDIR); destdir=$${destdir:-/}; \
136 destdir=$(DESTDIR); destdir=$${destdir:-/}; \
137 $(BUILDCMD) copy --destdir=$$destdir; \
137 $(BUILDCMD) copy --destdir=$$destdir; \
138 $(BUILDCMD) register
138 $(BUILDCMD) register
139−uninstall-all: uninstall-doc uninstall-lib-doc
139+uninstall-all: uninstall-exec uninstall-doc uninstall-lib-doc
140 -pkg_id="$(NAME)-$(VERSION)"; \
140 -pkg_id="$(NAME)-$(VERSION)"; \
141 libdir=$$($(GHC_PKG) field $$pkg_id library-dirs 2>/dev/null | \
141 libdir=$$($(GHC_PKG) field $$pkg_id library-dirs 2>/dev/null | \
142 sed 's/^library-dirs: *//'); \
142 sed 's/^library-dirs: *//'); \
cabalize+3−2
@@ -18,7 +18,7 @@ case "$ghc_version" in
186.4*)
186.4*)
19 BUILD_DEPENDS="${BUILD_DEPENDS} ${GHC64_DEPENDS}"
19 BUILD_DEPENDS="${BUILD_DEPENDS} ${GHC64_DEPENDS}"
20 ;;
20 ;;
21−6.[56]*)
21+6.[5-9]*)
22 BUILD_DEPENDS="${BUILD_DEPENDS} ${GHC66_DEPENDS}"
22 BUILD_DEPENDS="${BUILD_DEPENDS} ${GHC66_DEPENDS}"
23 ;;
23 ;;
24*)
24*)
@@ -30,7 +30,8 @@ BUILD_DEPENDS=$(echo $BUILD_DEPENDS | sed -e 's# #, #g')
30
30
31# Handle 'Hs-Source-Dir' option name which was deprecated in Cabal 1.1.4.
31# Handle 'Hs-Source-Dir' option name which was deprecated in Cabal 1.1.4.
32HS_SOURCE_DIRS='Hs-Source-Dirs'
32HS_SOURCE_DIRS='Hs-Source-Dirs'
33−if ghc-pkg -l | grep -q '\<[Cc]abal-[0-1]\.[0-1]\.[0-3][^,]*'; then
33+cabal_version=$(ghc-pkg -l | sed -ne 's/.*\<[Cc]abal-\([^,]*\).*/\1/p')
34+if printf "$cabal_version\n1.1.4" | sort | tail -n 1 | grep -q '1\.1\.4'; then
34 HS_SOURCE_DIRS='Hs-Source-Dir'
35 HS_SOURCE_DIRS='Hs-Source-Dir'
35fi
36fi
36
37