[GHC] #14183: ghc.exe: addLibrarySearchPath error

#14183: ghc.exe: addLibrarySearchPath error ----------------------------------------+--------------------------------- Reporter: vagarenko | Owner: (none) Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 8.2.1 Keywords: | Operating System: Windows Architecture: Unknown/Multiple | Type of failure: None/Unknown Test Case: | Blocked By: Blocking: | Related Tickets: Differential Rev(s): | Wiki Page: ----------------------------------------+--------------------------------- Recently I've removed Haskell Platform 8.0.1 and installed new Platform 8.2.1 Since then, when compiling a module GHC sometimes spits the following messages: {{{ ghc.exe: addLibrarySearchPath: C:\Program Files\Haskell Platform\8.0.1\mingw\lib (Win32 error 3): The system cannot find the path specified. }}} dozens of times in a row. But the compilation succeeds. The directory `C:\Program Files\Haskell Platform\8.0.1\` doesn't exist on my machine. I haven't figured out when exactly this happens but it seems to happen only when the module has Template Haskell splices in it. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/14183 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#14183: ghc.exe: addLibrarySearchPath error ---------------------------------+---------------------------------------- Reporter: vagarenko | Owner: (none) Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 8.2.1 Resolution: | Keywords: Operating System: Windows | Architecture: Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | ---------------------------------+---------------------------------------- Description changed by vagarenko: Old description:
Recently I've removed Haskell Platform 8.0.1 and installed new Platform 8.2.1
Since then, when compiling a module GHC sometimes spits the following messages: {{{ ghc.exe: addLibrarySearchPath: C:\Program Files\Haskell Platform\8.0.1\mingw\lib (Win32 error 3): The system cannot find the path specified. }}} dozens of times in a row. But the compilation succeeds. The directory `C:\Program Files\Haskell Platform\8.0.1\` doesn't exist on my machine.
I haven't figured out when exactly this happens but it seems to happen only when the module has Template Haskell splices in it.
New description: My OS is Windows 7. Recently I've removed Haskell Platform 8.0.1 and installed new Platform 8.2.1 Since then, when compiling a module GHC sometimes spits the following messages: {{{ ghc.exe: addLibrarySearchPath: C:\Program Files\Haskell Platform\8.0.1\mingw\lib (Win32 error 3): The system cannot find the path specified. }}} dozens of times in a row. But the compilation succeeds. The directory `C:\Program Files\Haskell Platform\8.0.1\` doesn't exist on my machine. I haven't figured out when exactly this happens but it seems to happen only when the module has Template Haskell splices in it. -- -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/14183#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#14183: ghc.exe: addLibrarySearchPath error ---------------------------------+---------------------------------------- Reporter: vagarenko | Owner: (none) Type: bug | Status: new Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.2.1 Resolution: | Keywords: Operating System: Windows | Architecture: Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | ---------------------------------+---------------------------------------- Changes (by bgamari): * cc: Phyx- (added) * milestone: => 8.4.1 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/14183#comment:2 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#14183: ghc.exe: addLibrarySearchPath error ---------------------------------+---------------------------------------- Reporter: vagarenko | Owner: (none) Type: bug | Status: closed Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.2.1 Resolution: invalid | Keywords: Operating System: Windows | Architecture: Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | ---------------------------------+---------------------------------------- Changes (by Phyx-): * status: new => closed * resolution: => invalid Comment: Hi, This isn't a GHC bug. Something external is giving GHC that path as an extra library path. Looking at the install instructions for Platform https://www.haskell.org/platform/windows.html it says to modify your cabal config to add extra library paths. these paths seem to match the format of the one that's giving you the warnings. You need to update your cabal config file to point to your new GHC instead of the old path. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/14183#comment:3 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#14183: ghc.exe: addLibrarySearchPath error ---------------------------------+---------------------------------------- Reporter: vagarenko | Owner: (none) Type: bug | Status: closed Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.2.1 Resolution: invalid | Keywords: Operating System: Windows | Architecture: Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | ---------------------------------+---------------------------------------- Comment (by vagarenko): **Phyx-**: I've changed paths in cabal config, but the error is still there. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/14183#comment:4 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#14183: ghc.exe: addLibrarySearchPath error ---------------------------------+---------------------------------------- Reporter: vagarenko | Owner: (none) Type: bug | Status: closed Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.2.1 Resolution: invalid | Keywords: Operating System: Windows | Architecture: Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | ---------------------------------+---------------------------------------- Comment (by vagarenko): If I run `cabal haddock` the error changes to: {{{ haddock.exe: addLibrarySearchPath: C:\Program Files\Haskell Platform\8.0.1\mingw\lib (Win32 error 3): The system cannot find the path specified. }}} Looks like it is a cabal error. I've made an issue in cabal repo: https://github.com/haskell/cabal/issues/4741 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/14183#comment:5 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#14183: ghc.exe: addLibrarySearchPath error ---------------------------------+---------------------------------------- Reporter: vagarenko | Owner: (none) Type: bug | Status: closed Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.2.1 Resolution: invalid | Keywords: Operating System: Windows | Architecture: Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | ---------------------------------+---------------------------------------- Comment (by Phyx-): I don't think it's a cabal bug. The fact that it's reporting a platform path indicates that it's something platform did or was done after it was install. You must still have a config that points to that path. GHC does infer some paths, but they're always relative to where it was installed. A couple of things to check, 1) check your ghc settings file (should be in your bin or lib folder, a file called Settings). Secondly check your packages, inspect the output of `ghc-pkg dump`. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/14183#comment:6 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#14183: ghc.exe: addLibrarySearchPath error ---------------------------------+---------------------------------------- Reporter: vagarenko | Owner: (none) Type: bug | Status: closed Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.2.1 Resolution: invalid | Keywords: Operating System: Windows | Architecture: Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | ---------------------------------+---------------------------------------- Changes (by vagarenko): * Attachment "ghc-pkg dump.txt" added. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/14183 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#14183: ghc.exe: addLibrarySearchPath error ---------------------------------+---------------------------------------- Reporter: vagarenko | Owner: (none) Type: bug | Status: closed Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.2.1 Resolution: invalid | Keywords: Operating System: Windows | Architecture: Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | ---------------------------------+---------------------------------------- Comment (by vagarenko): `settings` file in `C:\Program Files\Haskell Platform\8.2.1\lib`: {{{ [("GCC extra via C opts", " -fwrapv -fno-builtin"), ("C compiler command", "$topdir/../mingw/bin/gcc.exe"), ("C compiler flags", " -fno-stack-protector"), ("C compiler link flags", " "), ("C compiler supports -no-pie", "YES"), ("Haskell CPP command","$topdir/../mingw/bin/gcc.exe"), ("Haskell CPP flags","-E -undef -traditional"), ("ld command", "$topdir/../mingw/bin/ld.exe"), ("ld flags", ""), ("ld supports compact unwind", "YES"), ("ld supports build-id", "YES"), ("ld supports filelist", "NO"), ("ld is GNU ld", "YES"), ("ar command", "$topdir/../mingw/bin/ar.exe"), ("ar flags", "q"), ("ar supports at file", "YES"), ("touch command", "$topdir/bin/touchy.exe"), ("dllwrap command", "$topdir/../mingw/bin/dllwrap.exe"), ("windres command", "$topdir/../mingw/bin/windres.exe"), ("libtool command", ""), ("perl command", "$topdir/../perl/perl.exe"), ("cross compiling", "NO"), ("target os", "OSMinGW32"), ("target arch", "ArchX86_64"), ("target word size", "8"), ("target has GNU nonexec stack", "False"), ("target has .ident directive", "True"), ("target has subsections via symbols", "False"), ("target has RTS linker", "YES"), ("Unregisterised", "NO"), ("LLVM llc command", "llc"), ("LLVM opt command", "opt") ] }}} `ghc-pkg dump` has no references to `Haskell Platform\8.0.1` -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/14183#comment:7 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#14183: ghc.exe: addLibrarySearchPath error ---------------------------------+---------------------------------------- Reporter: vagarenko | Owner: (none) Type: bug | Status: closed Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.2.1 Resolution: invalid | Keywords: Operating System: Windows | Architecture: Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | ---------------------------------+---------------------------------------- Comment (by vagarenko): Oh wait when I run `cabal exec ghc-pkg dump` (I'm working in a cabal sandbox) it has a lot of references to `Haskell Platform\8.0.1` -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/14183#comment:8 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#14183: ghc.exe: addLibrarySearchPath error ---------------------------------+---------------------------------------- Reporter: vagarenko | Owner: (none) Type: bug | Status: closed Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.2.1 Resolution: invalid | Keywords: Operating System: Windows | Architecture: Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | ---------------------------------+---------------------------------------- Comment (by Phyx-): You probably have to re-create your sandbox. The sandboxes are a snapshot in time so they would maintain reconfigured data. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/14183#comment:9 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#14183: ghc.exe: addLibrarySearchPath error ---------------------------------+---------------------------------------- Reporter: vagarenko | Owner: (none) Type: bug | Status: closed Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.2.1 Resolution: invalid | Keywords: Operating System: Windows | Architecture: Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | ---------------------------------+---------------------------------------- Comment (by vagarenko): Yes, after re-creating the sandbox, the error disappeared. Thanks for your help! -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/14183#comment:10 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler
participants (1)
-
GHC