Rewrote free disk space checking code
Moving the portability handling into a small C library cleans up things a lot, avoiding the pain of unpacking structs from inside haskell code.
This commit is contained in:
parent
f1398b5583
commit
e38a839a80
13 changed files with 124 additions and 237 deletions
21
configure.hs
21
configure.hs
|
@ -1,23 +1,6 @@
|
|||
{- configure program -}
|
||||
|
||||
import Data.Maybe
|
||||
|
||||
import qualified Build.Configure as Configure
|
||||
import Build.TestConfig
|
||||
import Utility.StatFS
|
||||
|
||||
tests :: [TestCase]
|
||||
tests = [ TestCase "StatFS" testStatFS
|
||||
] ++ Configure.tests False
|
||||
|
||||
{- This test cannot be included in Build.Configure due to needing
|
||||
- Utility/StatFS.hs to be built, which it is not when "cabal configure"
|
||||
- is run. -}
|
||||
testStatFS :: Test
|
||||
testStatFS = do
|
||||
s <- getFileSystemStats "."
|
||||
return $ Config "statfs_sanity_checked" $
|
||||
MaybeBoolConfig $ Just $ isJust s
|
||||
import Build.Configure
|
||||
|
||||
main :: IO ()
|
||||
main = Configure.run tests
|
||||
main = run tests
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue