aboutsummaryrefslogtreecommitdiff
path: root/src/Text/Pandoc/PDF.hs
diff options
context:
space:
mode:
Diffstat (limited to 'src/Text/Pandoc/PDF.hs')
-rw-r--r--src/Text/Pandoc/PDF.hs5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/Text/Pandoc/PDF.hs b/src/Text/Pandoc/PDF.hs
index 75bd489d1..ea6699ac4 100644
--- a/src/Text/Pandoc/PDF.hs
+++ b/src/Text/Pandoc/PDF.hs
@@ -146,8 +146,9 @@ tex2pdf' verbose tmpDir program source = do
let logmsg = extractMsg log'
let extramsg =
case logmsg of
- x | "! Package inputenc Error" `BC.isPrefixOf` x ->
- "\nTry running pandoc with --latex-engine=xelatex."
+ x | ("! Package inputenc Error" `BC.isPrefixOf` x
+ && program /= "xelatex")
+ -> "\nTry running pandoc with --latex-engine=xelatex."
_ -> ""
return $ Left $ logmsg <> extramsg
(ExitSuccess, Nothing) -> return $ Left ""