From b241472a90e8cdb3146acfbe555f50abd4b3b302 Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Thu, 28 May 2015 18:15:01 -0700 Subject: Better fix for #2187. * Reverted kludgy change to make-windows-installer.bat. * Removed make-reference-fiels.hs. * Moved the individual ingredients of reference.docx and reference.odt to the data directory. * Removed reference.docx and reference.odt from data directory. * We now build the reference archives from their ingredient pieces in the docx and odt writers, instead of having a reference.docx or reference.odt intermediary. This should fix #2187. It also simplifies the bulid procedure. The one thing users may notice is different is that you can no longer get the reference.docx or reference.odt using `--print-default-data-file`. Instead, simply generate a docx or odt using pandoc with a blank or minimal input, and use that (or a customized version) with `--reference-docx` or `--reference-odt`. --- Setup.hs | 15 ++------------- 1 file changed, 2 insertions(+), 13 deletions(-) (limited to 'Setup.hs') diff --git a/Setup.hs b/Setup.hs index bba8e884c..fe1798763 100644 --- a/Setup.hs +++ b/Setup.hs @@ -38,12 +38,11 @@ main = defaultMainWithHooks $ simpleUserHooks { , instHook = \pkgdescr -> instHook simpleUserHooks pkgdescr{ executables = [x | x <- executables pkgdescr, exeName x `notElem` noInstall] } - , postBuild = \args bf pkgdescr lbi -> do + , postBuild = \args bf pkgdescr lbi -> makeManPages args bf pkgdescr lbi - makeReferenceFiles args bf pkgdescr lbi } where - noInstall = ["make-pandoc-man-pages","make-reference-files"] + noInstall = ["make-pandoc-man-pages"] ppBlobSuffixHandler :: PPSuffixHandler ppBlobSuffixHandler = ("hsb", \_ _ -> @@ -64,13 +63,3 @@ makeManPages _ bf _ LocalBuildInfo{buildDir=buildDir} where verbosity = fromFlagOrDefault normal $ buildVerbosity bf progPath = buildDir "make-pandoc-man-pages" "make-pandoc-man-pages" - -makeReferenceFiles :: Args -> BuildFlags -> PackageDescription -> LocalBuildInfo -> IO () -makeReferenceFiles _ bf _ LocalBuildInfo{buildDir=buildDir} - = mapM_ - (rawSystemExit verbosity progPath . return) - referenceFormats - where - verbosity = fromFlagOrDefault normal $ buildVerbosity bf - progPath = buildDir "make-reference-files" "make-reference-files" - referenceFormats = ["docx", "odt"] -- cgit v1.2.3