diff options
| author | hallgren <hallgren@chalmers.se> | 2011-10-20 13:36:42 +0000 |
|---|---|---|
| committer | hallgren <hallgren@chalmers.se> | 2011-10-20 13:36:42 +0000 |
| commit | a9f4d42652dfd99413a8d09ba70869cbf137419a (patch) | |
| tree | 9e0f451358fe11c7454dc7689a472239ce20d70f /Setup.hs | |
| parent | 6c5ee3d6667a869a3f9b36cc4b036de3fde33f06 (diff) | |
Setup.hs: less verbose output during the compilation of the RGL
Only show the full gf command line if an error occurs.
Diffstat (limited to 'Setup.hs')
| -rw-r--r-- | Setup.hs | 9 |
1 files changed, 6 insertions, 3 deletions
@@ -343,12 +343,15 @@ run_gfc :: PackageDescription -> LocalBuildInfo -> [String] -> IO () run_gfc pkg lbi args = do let args' = ["-batch","-gf-lib-path="++rgl_src_dir,"+RTS","-K32M","-RTS"] ++ filter (not . null) args gf = default_gf pkg lbi - putStrLn $ "Running: " ++ gf ++ " " ++ unwords (map showArg args') + gf_cmdline = gf ++ " " ++ unwords (map showArg args') +-- putStrLn $ "Running: " ++ gf_cmdline e <- rawSystem gf args' case e of ExitSuccess -> return () - ExitFailure i -> die $ "gf exited with exit code: " ++ show i - where showArg arg = "'" ++ arg ++ "'" + ExitFailure i -> do putStrLn $ "Ran: " ++ gf_cmdline + die $ "gf exited with exit code: " ++ show i + where + showArg arg = if ' ' `elem` arg then "'" ++ arg ++ "'" else arg default_gf pkg lbi = buildDir lbi </> exeName' </> exeNameReal where |
