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

Error during compilation #39

Open
AnnikenYT opened this issue Jul 11, 2023 · 9 comments
Open

Error during compilation #39

AnnikenYT opened this issue Jul 11, 2023 · 9 comments

Comments

@AnnikenYT
Copy link

Hiya!
I'm relatively new to everything-vim, recently made the switch from vscode to nvim w/ nvchad, so excuse my "noobishness".
When I'm trying to do :TSInstall svelte, I get the following error:

nvim-treesitter[svelte]: Error during compilation
In file included from src/scanner.c:7:
src/uthash.h:375:16: error: always_inline function '_mm_crc32_u8' requires target feature 'crc32', but would be inlined into function 'hashmap_crc32_helper' that is compiled without support for 'crc32'
    crc32val = _mm_crc32_u8(crc32val, HASHMAP_CAST(unsigned char, s[i]));
               ^
1 error generated.

I am using Windows (I know, shame on me) 11, and have emcc installed.

@Kohlenbach
Copy link

I'm having the same issue 😞
(also windows 11)

@AnnikenYT
Copy link
Author

Good to know that I'm not alone on that.
I'll check if this can be reproduced on win 10.

@Kohlenbach
Copy link

If you don't find a way to use with :TSInstall then maybe use custom until fix.
May help: https://youtu.be/Mtgo-nP_r8Y?t=420

@Rasmus-Bertell
Copy link

I can confirm this happening also on Windows 10, for whatever reason my Windows 11 laptop worked just fine.

Edition 	Windows 10 Enterprise
Version 	22H2
Installed on	‎xx/xx/2022
OS build	19045.3208
Experience	Windows Feature Experience Pack 1000.19041.1000.0

Processor	12th Gen Intel(R) Core(TM) i7-12700H   2.30 GHz
Installed RAM	32,0 GB (31,7 GB usable)
System type	64-bit operating system, x64-based processor

@Himujjal
Copy link
Owner

Himujjal commented Aug 1, 2023

Sorry fellas. Was out for vacation. Will get this fix done soon

@Noodle-Bug
Copy link

Looks like this is still happening

:TSInstall svelte

nvim-treesitter[svelte]: Error during compilation
In file included from src/scanner.c:7:^M
src/uthash.h:375:16: error: always_inline function '_mm_crc32_u8' requires target feature 'crc32', but would be inlined into function 'hashmap_crc32_helper' that is compiled without support for 'crc32'^M
    crc32val = _mm_crc32_u8(crc32val, HASHMAP_CAST(unsigned char, s[i]));^M
               ^^M
1 error generated.^M
NVIM v0.9.4
Build type: RelWithDebInfo
LuaJIT 2.1.1696883897

@lllama
Copy link

lllama commented Jan 22, 2024

So I've had the same issue and I was able to resolve it by opening a "Developer Powershell for VS2022" terminal, rather than my usual one. I then opened nvim and did TSInstall svelte. Everything compiled and then I got highlighting etc in normal sessions.

You'll need to install some variant of VS Studio Dev tools to get the required files etc.

@Noodle-Bug
Copy link

So I've had the same issue and I was able to resolve it by opening a "Developer Powershell for VS2022" terminal, rather than my usual one. I then opened nvim and did TSInstall svelte. Everything compiled and then I got highlighting etc in normal sessions.

You'll need to install some variant of VS Studio Dev tools to get the required files etc.

Hey that worked! What made you try that out?

@lllama
Copy link

lllama commented Jan 22, 2024

Thanks @Noodle-Bug. The error was suggesting that some feature needed turning on and I couldn't find a way to change the compiler options used by the treesitter plugin, so I decided to take a punt and see whether it would be enabled by default in the Developer terminal. (I know it sets a load of env vars etc.)

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

6 participants