Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

0.7.1.0 Fails to build on macOS M1 using GHC 9.2.1 #132

Open
arafangion opened this issue Nov 25, 2021 · 3 comments
Open

0.7.1.0 Fails to build on macOS M1 using GHC 9.2.1 #132

arafangion opened this issue Nov 25, 2021 · 3 comments

Comments

@arafangion
Copy link

Just reporting that language-javascript seems to fail on macOS using the M1 architecture (Arm64), and I'm not sure how to make it pass:

bash-3.2$ locale
LANG="en_AU.UTF-8"
LC_COLLATE="en_AU.UTF-8"
LC_CTYPE="en_AU.UTF-8"
LC_MESSAGES="en_AU.UTF-8"
LC_MONETARY="en_AU.UTF-8"
LC_NUMERIC="en_AU.UTF-8"
LC_TIME="en_AU.UTF-8"
LC_ALL=
bash-3.2$ LC_ALL=en_AU.UTF-8 cabal install language-javascript
Resolving dependencies...
Build profile: -w ghc-9.2.1 -O1
In order, the following will be built (use -v for more details):
 - language-javascript-0.7.1.0 (lib) (requires build)
Starting     language-javascript-0.7.1.0 (lib)
Building     language-javascript-0.7.1.0 (lib)

Failed to build language-javascript-0.7.1.0.
Build log (
/Users/johnchapman/.cabal/logs/ghc-9.2.1/lngg-jvscrpt-0.7.1.0-62cfd969.log ):
Configuring library for language-javascript-0.7.1.0..
Warning: Packages using 'cabal-version: >= 1.10' and before 'cabal-version:
3.4' must specify the 'default-language' field for each component (e.g.
Haskell98 or Haskell2010). If a component uses different languages in
different modules then list the other ones in the 'other-languages' field.
Preprocessing library for language-javascript-0.7.1.0..
happy: src/Language/JavaScript/Parser/Grammar7.y: hGetContents: invalid argument (invalid byte sequence)
cabal: Failed to build language-javascript-0.7.1.0. See the build log above
for details.

bash-3.2$
@Daniel-Diaz
Copy link

Daniel-Diaz commented Apr 21, 2022

I ran into this same issue. Doing export LANG=C.UTF-8 made it work (in ubuntu-20.04.4 LTS).

@joeyh
Copy link

joeyh commented Mar 7, 2023

The sole unicode symbol in that file is ∉, which is used in a comment. Removing that character fixes the build on non-unicode locales.

@joeyh
Copy link

joeyh commented Mar 7, 2023

See also haskell/happy#157

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants