[Hackage] #922: “lexical error (UTF-8 decoding error)” in WIndows 7

#922: “lexical error (UTF-8 decoding error)” in WIndows 7 ---------------------------------+------------------------------------------ Reporter: hamukazu | Owner: Type: defect | Status: new Priority: normal | Milestone: Component: cabal-install tool | Version: HEAD Severity: minor | Keywords: UTF-8 Difficulty: unknown | Ghcversion: Platform: Windows | ---------------------------------+------------------------------------------ ==== Symptom ==== When I type
cabal install cabal it fails with the following error: Distribution\Compat\Exception.hs:0:4: lexical error (UTF-8 decoding error)
==== Environment ==== It happens with 64 bit version of Windows 7. It came to occur after I failed to install HXT. (I am not sure it is related.) ==== Workaround ==== By setting
set LANG=C in command line, cabal comes to work.
I regard this is just a workaround and this issue should be reported as a bug. ==== Related links ==== http://stackoverflow.com/questions/9371438/cabal-install-complains-built- in04-lexical-error-utf-8-decoding-error/9533205#9533205 http://trac.haskell.org/network/ticket/43 -- Ticket URL: http://hackage.haskell.org/trac/hackage/ticket/922 Hackage http://haskell.org/cabal/ Hackage: Cabal and related projects

#922: “lexical error (UTF-8 decoding error)” in WIndows 7 ---------------------------------+------------------------------------------ Reporter: hamukazu | Owner: Type: defect | Status: new Priority: normal | Milestone: cabal-install-0.14 Component: cabal-install tool | Version: HEAD Severity: minor | Keywords: UTF-8 Difficulty: unknown | Ghcversion: Platform: Windows | ---------------------------------+------------------------------------------ Changes (by kosmikus): * milestone: => cabal-install-0.14 -- Ticket URL: http://hackage.haskell.org/trac/hackage/ticket/922#comment:1 Hackage http://haskell.org/cabal/ Hackage: Cabal and related projects

#922: “lexical error (UTF-8 decoding error)” in WIndows 7 ---------------------------------+------------------------------------------ Reporter: hamukazu | Owner: Type: defect | Status: new Priority: normal | Milestone: cabal-install-0.14 Component: cabal-install tool | Version: HEAD Severity: minor | Keywords: UTF-8 Difficulty: unknown | Ghcversion: Platform: Windows | ---------------------------------+------------------------------------------ Comment(by duncan): Looks like cpp is outputting text that is not ASCII or UTF8. This then blows up because ghc expects .hs files to be UTF8. Cabal can perhaps work around this cpp quirk by calling ghc/cpp with LANG=C. The new program launching utils in Cabal should make it easier to set env vars like this. It'd be useful if someone could confirm this hypothesis. -- Ticket URL: http://hackage.haskell.org/trac/hackage/ticket/922#comment:2 Hackage http://haskell.org/cabal/ Hackage: Cabal and related projects

#922: “lexical error (UTF-8 decoding error)” in WIndows 7 ---------------------------------+------------------------------------------ Reporter: hamukazu | Owner: Type: defect | Status: new Priority: normal | Milestone: cabal-install-0.16 Component: cabal-install tool | Version: HEAD Severity: minor | Keywords: UTF-8 Difficulty: unknown | Ghcversion: Platform: Windows | ---------------------------------+------------------------------------------ Changes (by kosmikus): * milestone: cabal-install-0.14 => cabal-install-0.16 Comment: Most likely will require a change in the Cabal lib. -- Ticket URL: http://hackage.haskell.org/trac/hackage/ticket/922#comment:3 Hackage http://haskell.org/cabal/ Hackage: Cabal and related projects
participants (1)
-
Hackage