aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2017-03-26 20:41:35 +0200
committerJohn MacFarlane <jgm@berkeley.edu>2017-03-26 20:41:35 +0200
commitb7782cf8d32d22d8e9bc8bc125be2b2ff1fdd751 (patch)
treec2c50884ea16389cf9fc29d923f147703742b774
parent358dfba8f4eba45fdfdfad2c117de99df8b45bc4 (diff)
downloadpandoc-b7782cf8d32d22d8e9bc8bc125be2b2ff1fdd751.tar.gz
Revert "Text.Pandoc.Data: ensure it compiles even without embed_data_files."
This reverts commit 453970c6b34ed7cc2f52181e5e77b9182a3639e9.
-rw-r--r--src/Text/Pandoc/Data.hs14
1 files changed, 3 insertions, 11 deletions
diff --git a/src/Text/Pandoc/Data.hs b/src/Text/Pandoc/Data.hs
index 41ff5a0d6..df26f5412 100644
--- a/src/Text/Pandoc/Data.hs
+++ b/src/Text/Pandoc/Data.hs
@@ -1,15 +1,11 @@
-{-# LANGUAGE CPP #-}
-#ifdef EMBED_DATA_FILES
{-# LANGUAGE TemplateHaskell #-}
-#endif
+
module Text.Pandoc.Data (dataFiles) where
-import System.FilePath (FilePath, splitDirectories)
+import Data.FileEmbed
import qualified Data.ByteString as B
+import System.FilePath (splitDirectories)
import qualified System.FilePath.Posix as Posix
-#ifdef EMBED_DATA_FILES
-import Data.FileEmbed
-#endif
-- We ensure that the data files are stored using Posix
-- path separators (/), even on Windows.
@@ -18,8 +14,4 @@ dataFiles = map (\(fp, contents) ->
(Posix.joinPath (splitDirectories fp), contents)) dataFiles'
dataFiles' :: [(FilePath, B.ByteString)]
-#ifdef EMBED_DATA_FILES
dataFiles' = ("MANUAL.txt", $(embedFile "MANUAL.txt")) : $(embedDir "data")
-#else
-dataFiles' = error "dataFiles is only defined when embed_data_files flag set"
-#endif