Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Glasgow Haskell Compiler
Packages
Cabal
Commits
bb273e7c
Commit
bb273e7c
authored
Dec 03, 2014
by
Christiaan Baaij
Browse files
Don't fail canonicalizePath when libdir doesn't exist
parent
52f96e18
Changes
1
Hide whitespace changes
Inline
Side-by-side
Cabal/Distribution/Simple/LocalBuildInfo.hs
View file @
bb273e7c
...
...
@@ -97,7 +97,7 @@ import Data.Tree (flatten)
import
GHC.Generics
(
Generic
)
import
Data.Map
(
Map
)
import
System.Directory
(
canonicalizePath
)
import
System.Directory
(
doesDirectoryExist
,
canonicalizePath
)
import
System.FilePath
((
</>
))
-- | Data cached after configuration step. See also
...
...
@@ -437,7 +437,7 @@ depLibraryPaths inplace relative lbi clbi = do
allDepLibDirs'
=
if
hasInternalDeps
then
(
libdir
installDirs
)
:
allDepLibDirs
else
allDepLibDirs
allDepLibDirsC
<-
mapM
canonicalizePath
allDepLibDirs'
allDepLibDirsC
<-
mapM
canonicalizePath
NoFail
allDepLibDirs'
let
(
Platform
_
hostOS
)
=
hostPlatform
lbi
hostPref
=
case
hostOS
of
...
...
@@ -459,6 +459,11 @@ depLibraryPaths inplace relative lbi clbi = do
return
(
toNubListR
rpaths
)
where
internal
pkgid
=
pkgid
==
packageId
(
localPkgDescr
lbi
)
canonicalizePathNoFail
p
=
do
exists
<-
doesDirectoryExist
p
if
exists
then
canonicalizePath
p
else
return
p
-- -----------------------------------------------------------------------------
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment