mirror of
https://github.com/jgm/pandoc.git
synced 2026-08-25 17:56:32 +00:00
Revert "New method for checking for presence of tex program."
This reverts commit 285bbf61cf.
This commit is contained in:
+1
-2
@@ -425,8 +425,7 @@ Executable pandoc
|
||||
aeson >= 0.7.0.5 && < 0.12,
|
||||
yaml >= 0.8.8.2 && < 0.9,
|
||||
containers >= 0.1 && < 0.6,
|
||||
HTTP >= 4000.0.5 && < 4000.4,
|
||||
process >= 1.0 && < 1.5
|
||||
HTTP >= 4000.0.5 && < 4000.4
|
||||
if flag(network-uri)
|
||||
Build-Depends: network-uri >= 2.6 && < 2.7, network >= 2.6
|
||||
else
|
||||
|
||||
@@ -52,7 +52,6 @@ import Data.Char ( toLower, toUpper )
|
||||
import Data.List ( delete, intercalate, isPrefixOf, isSuffixOf, sort )
|
||||
import System.Directory ( getAppUserDataDirectory, findExecutable,
|
||||
doesFileExist, Permissions(..), getPermissions )
|
||||
import System.Process ( readProcessWithExitCode )
|
||||
import System.IO ( stdout, stderr )
|
||||
import System.IO.Error ( isDoesNotExistError )
|
||||
import qualified Control.Exception as E
|
||||
@@ -1402,11 +1401,8 @@ convertWithOpts opts args = do
|
||||
_ | html5Output -> "wkhtmltopdf"
|
||||
_ -> latexEngine
|
||||
-- check for pdf creating program
|
||||
(ec,_,_) <- E.catch
|
||||
(readProcessWithExitCode pdfprog ["--version"] "")
|
||||
(\(_ :: E.SomeException) ->
|
||||
return (ExitFailure 1,"",""))
|
||||
when (ec /= ExitSuccess) $
|
||||
mbPdfProg <- findExecutable pdfprog
|
||||
when (isNothing mbPdfProg) $
|
||||
err 41 $ pdfprog ++ " not found. " ++
|
||||
pdfprog ++ " is needed for pdf output."
|
||||
|
||||
|
||||
Reference in New Issue
Block a user