[GHC] #14064: Compiling problem on FreeBSD 11 ("failed in phase")

GHC ghc-devs at haskell.org
Mon Jul 31 06:28:17 UTC 2017


#14064: Compiling problem on FreeBSD 11 ("failed in phase")
-------------------------------------+-------------------------------------
        Reporter:  ohho              |                Owner:  (none)
            Type:  bug               |               Status:  infoneeded
        Priority:  normal            |            Milestone:
       Component:  Compiler          |              Version:  8.2.1
      Resolution:                    |             Keywords:
Operating System:  FreeBSD           |         Architecture:  x86_64
 Type of failure:  GHC doesn't work  |  (amd64)
  at all                             |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by ohho):

 Replying to [comment:1 bgamari]:
 > I believe this is actually a
 [[https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221111|FreeBSD
 issue]]. Can you confirm that the fix proposed on that ticket resolves the
 issue?

 Yes, it was due to the package was built unpatched.\\
 I reinstalled gcc5 from the ports collection, it did solve the problem.

 However, the
 [https://www.reddit.com/r/haskell/comments/6oz5q3/announce_ghc_821_available/dkoy3m3/
 ld.gold error] I posted on reddit remained the same.

 Check this out:

 {{{
 $ /home/ghc/bin/ghc -O0  --make Main.hs
 [1 of 1] Compiling Main             ( Main.hs, Main.o )
 Linking Main ...
 /usr/local/bin/ld.gold: error: cannot find -liconv
 /usr/local/bin/ld.gold: error: cannot find -lcharset
 /usr/local/bin/ld.gold: error: cannot find -lgmp
 /home/ghc/lib/ghc-8.2.1/base-4.10.0.0/libHSbase-4.10.0.0.a(PrelIOUtils.o):function
 localeEncoding: error: undefined reference to 'locale_charset'
 /home/ghc/lib/ghc-8.2.1/base-4.10.0.0/libHSbase-4.10.0.0.a(iconv.o):function
 hs_iconv_open: error: undefined reference to 'libiconv_open'
 /home/ghc/lib/ghc-8.2.1/base-4.10.0.0/libHSbase-4.10.0.0.a(iconv.o):function
 hs_iconv: error: undefined reference to 'libiconv'
 /home/ghc/lib/ghc-8.2.1/base-4.10.0.0/libHSbase-4.10.0.0.a(iconv.o):function
 hs_iconv_close: error: undefined reference to 'libiconv_close'
 collect2: error: ld returned 1 exit status
 `gcc5' failed in phase `Linker'. (Exit code: 1)
 }}}

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


More information about the ghc-tickets mailing list