diff options
Diffstat (limited to 'Utility/Mounts.hs')
-rw-r--r-- | Utility/Mounts.hs | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/Utility/Mounts.hs b/Utility/Mounts.hs new file mode 100644 index 000000000..192da31a1 --- /dev/null +++ b/Utility/Mounts.hs @@ -0,0 +1,21 @@ +{- portability shim for System.MountPoints + - + - Copyright 2016 Joey Hess <id@joeyh.name> + - + - License: BSD-2-clause + -} + +{-# LANGUAGE CPP #-} +{-# OPTIONS_GHC -fno-warn-tabs #-} + +module Utility.Mounts (getMounts, Mntent(..)) where + +import qualified System.MountPoints +import System.MountPoints (Mntent(..)) + +getMounts :: IO [Mntent] +#ifndef __ANDROID__ +getMounts = System.MountPoints.getMounts +#else +getMounts = System.MountPoints.getProcMounts +#endif |