[GHC] #8167: build fails in non-unicode locale [happy: compiler/stage1/build/Parser.y: hGetContents: invalid argument (invalid byte sequence)]
#8167: build fails in non-unicode locale [happy: compiler/stage1/build/Parser.y: hGetContents: invalid argument (invalid byte sequence)] ----------------------------------+---------------------------------------- Reporter: rwbarton | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 7.7 (Parser) | Operating System: Unknown/Multiple Keywords: | Type of failure: Building GHC failed Architecture: | Test Case: Unknown/Multiple | Blocking: Difficulty: Unknown | Blocked By: | Related Tickets: | ----------------------------------+---------------------------------------- To reproduce, check out a fresh copy of GHC and `export LC_ALL=C` before going through the steps to build it. Commit 96adf0e99 introduced non-ASCII (UTF-8) text into `compiler/parser/Parser.y.pp` in a string literal. `happy` tries to read this file in the encoding corresponding to the system locale. Probably `happy` ought to declare that all its input files are UTF-8, like GHC does, but it currently doesn't, so it seems best to just ensure that `Parser.y.pp` is pure ASCII. Patch attached. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/8167> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#8167: build fails in non-unicode locale [happy: compiler/stage1/build/Parser.y: hGetContents: invalid argument (invalid byte sequence)] ----------------------------------------+---------------------------------- Reporter: rwbarton | Owner: Type: bug | Status: patch Priority: normal | Milestone: Component: Compiler (Parser) | Version: 7.7 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Building GHC failed | Unknown/Multiple Test Case: | Difficulty: Unknown Blocking: | Blocked By: | Related Tickets: ----------------------------------------+---------------------------------- Changes (by rwbarton): * status: new => patch -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/8167#comment:1> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#8167: build fails in non-unicode locale [happy: compiler/stage1/build/Parser.y: hGetContents: invalid argument (invalid byte sequence)] ----------------------------------------+---------------------------------- Reporter: rwbarton | Owner: Type: bug | Status: closed Priority: normal | Milestone: Component: Compiler (Parser) | Version: 7.7 Resolution: fixed | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Building GHC failed | Unknown/Multiple Test Case: | Difficulty: Unknown Blocking: | Blocked By: | Related Tickets: ----------------------------------------+---------------------------------- Changes (by thoughtpolice): * status: patch => closed * resolution: => fixed Comment: Thanks. Fixed in {{{ commit 6a02f280e074278acceb6e9331bb00dccfe02f08 Author: Reid Barton <rwbarton@gmail.com> Date: Fri Aug 23 19:27:20 2013 -0400 Fix build on non-unicode locale happy reads .y files with the system encoding, so keep Parser.y.pp ASCII. Signed-off-by: Austin Seipp <aseipp@pobox.com> }}} -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/8167#comment:2> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
participants (1)
-
GHC