[GHC] #13210: Can't run terminfo code in GHCi on Windows

GHC ghc-devs at haskell.org
Mon Jan 30 22:16:54 UTC 2017


#13210: Can't run terminfo code in GHCi on Windows
-------------------------------------+-------------------------------------
        Reporter:  RyanGlScott       |                Owner:
            Type:  bug               |               Status:  new
        Priority:  normal            |            Milestone:
       Component:  Runtime System    |              Version:  8.0.2
  (Linker)                           |
      Resolution:                    |             Keywords:
Operating System:  Windows           |         Architecture:
 Type of failure:  GHC rejects       |  Unknown/Multiple
  valid program                      |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by RyanGlScott):

 Hm, adding `-lpthread` doesn't seem to work around the issue for me:

 {{{
 $ ../../../Software/ghc/inplace/bin/runghc -lncursesw -lpthread
 Terminfo.hs
 GHC runtime linker: fatal error: I found a duplicate definition for symbol
    ungetch
 whilst processing object file
    C:\msys64\mingw64\lib\libncursesw.a
 The symbol was previously defined in
    (GHCi built-in symbols)
 This could be caused by:
    * Loading two different object files which export the same symbol
    * Specifying the same object file twice on the GHCi command line
    * An incorrect `package.conf' entry, causing some object to be
      loaded twice.
 ghc-stage2.exe: Could not on-demand load symbol 'ungetch_sp'

 ghc-stage2.exe: C:\msys64\mingw64\lib\libncursesw.a: unknown symbol
 `ungetch_sp'

 ghc-stage2.exe: Could not on-demand load symbol 'set_escdelay_sp'

 ghc-stage2.exe: C:\msys64\mingw64\lib\libncursesw.a: unknown symbol
 `set_escdelay_sp'

 ghc-stage2.exe: Could not on-demand load symbol 'newterm'

 ghc-stage2.exe: C:\msys64\mingw64\lib\libncursesw.a: unknown symbol
 `newterm'

 ghc-stage2.exe: Could not on-demand load symbol '.refptr._nc_globals'

 ghc-stage2.exe: C:\msys64\mingw64\lib\libncursesw.a: unknown symbol
 `.refptr._nc_globals'

 ghc-stage2.exe: Could not on-demand load symbol '_nc_err_abort'

 ghc-stage2.exe: C:\msys64\mingw64\lib\libncursesw.a: unknown symbol
 `_nc_err_abort'

 ghc-stage2.exe: Could not on-demand load symbol 'tparm'

 ghc-stage2.exe: C:\msys64\mingw64\lib\libncursesw.a: unknown symbol
 `tparm'

 ghc-stage2.exe: Could not on-demand load symbol '.refptr._nc_prescreen'

 ghc-stage2.exe: C:\msys64\mingw64\lib\libncursesw.a: unknown symbol
 `.refptr._nc_prescreen'

 ghc-stage2.exe: Could not on-demand load symbol '_nc_outch_sp'

 ghc-stage2.exe: C:\msys64\mingw64\lib\libncursesw.a: unknown symbol
 `_nc_outch_sp'

 ghc-stage2.exe: Could not on-demand load symbol '.refptr._nc_outch_sp'

 ghc-stage2.exe: C:\msys64\mingw64\lib\libncursesw.a: unknown symbol
 `.refptr._nc_outch_sp'

 ghc-stage2.exe: Could not on-demand load symbol '_nc_scrolln_sp'

 ghc-stage2.exe: C:\msys64\mingw64\lib\libncursesw.a: unknown symbol
 `_nc_scrolln_sp'

 ghc-stage2.exe: Could not on-demand load symbol '.refptr.SP'

 ghc-stage2.exe: C:\msys64\mingw64\lib\libncursesw.a: unknown symbol
 `.refptr.SP'

 ghc-stage2.exe: Could not on-demand load symbol '.refptr.cur_term'

 ghc-stage2.exe: C:\msys64\mingw64\lib\libncursesw.a: unknown symbol
 `.refptr.cur_term'

 ghc-stage2.exe: Could not on-demand load symbol '_nc_ospeed'

 ghc-stage2.exe: C:\msys64\mingw64\lib\libncursesw.a: unknown symbol
 `_nc_ospeed'

 ghc-stage2.exe: Could not on-demand load symbol 'set_curterm'

 Terminfo.hs:
 ByteCodeLink: can't find label
 During interactive linking, GHCi couldn't find the following symbol:
   set_curterm
 This may be due to you not asking GHCi to load extra object files,
 archives or DLLs needed by your current session.  Restart GHCi, specifying
 the missing library using the -L/path/to/object/dir and -lmissinglibname
 flags, or simply by naming the relevant files on the GHCi command line.
 Alternatively, this link failure might indicate a bug in GHCi.
 If you suspect the latter, please send a bug report to:
   glasgow-haskell-bugs at haskell.org
 }}}

--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/13210#comment:2>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list