jgm/pandoc — Issue #441: Man-pages installed with "bad" permissions
Author: magthe
Created: 2012-03-09 21:19:42+00:00
State: open

When packaging pandoc for ArchLinux I ended up applying the following patch, which I think should be considered for permanent inclusion.

```

Index: archhaskell-habs/haskell-pandoc/src/pandoc-1.9.1.1/Setup.hs
===================================================================
--- archhaskell-habs.orig/haskell-pandoc/src/pandoc-1.9.1.1/Setup.hs
+++ archhaskell-habs/haskell-pandoc/src/pandoc-1.9.1.1/Setup.hs
@@ -8,7 +8,7 @@ import Distribution.Simple.LocalBuildInf
import Distribution.Verbosity ( Verbosity, silent )
import Distribution.Simple.GHC (ghcPackageDbOptions)
import Distribution.Simple.InstallDirs (mandir, bindir, CopyDest (NoCopyDest))
-import Distribution.Simple.Utils (copyFiles)
+import Distribution.Simple.Utils (installOrdinaryFiles)
import Control.Exception ( bracket_ )
import Control.Monad ( unless )
import System.Process ( rawSystem, runCommand, waitForProcess )
@@ -86,7 +86,7 @@ manDir = "man"
installManpages :: PackageDescription -> LocalBuildInfo
-> Verbosity -> CopyDest -> IO ()
installManpages pkg lbi verbosity copy =
- copyFiles verbosity (mandir (absoluteInstallDirs pkg lbi copy))
+ installOrdinaryFiles verbosity (mandir (absoluteInstallDirs pkg lbi copy))
(zip (repeat manDir) manpages)

-- | Returns a list of 'dependencies' that have been modified after 'file'.
```