From cbcdae91484a13780a3d827a1b6ae85f7e3a9ab3 Mon Sep 17 00:00:00 2001 From: krasimir Date: Tue, 6 Oct 2009 10:27:34 +0000 Subject: hopefully the last revision of the relative paths handling algorithm --- src/GFI.hs | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'src/GFI.hs') diff --git a/src/GFI.hs b/src/GFI.hs index edf4ada5f..7b98f0ff8 100644 --- a/src/GFI.hs +++ b/src/GFI.hs @@ -130,10 +130,11 @@ loop opts gfenv0 = do putStrLn "wrote graph in file _gfdepgraph.dot" loopNewCPU gfenv "i":args -> do - cdir <- getCurrentDirectory - gfenv' <- case parseOptions cdir args of - Ok (opts',files) -> - importInEnv gfenv (addOptions opts opts') files + gfenv' <- case parseOptions args of + Ok (opts',files) -> do + curr_dir <- getCurrentDirectory + lib_dir <- getLibraryDirectory (addOptions opts opts') + importInEnv gfenv (addOptions opts (fixRelativeLibPaths curr_dir lib_dir opts')) files Bad err -> do putStrLn $ "Command parse error: " ++ err return gfenv -- cgit v1.2.3