ikatyang / tree-sitter-yaml

YAML grammar for tree-sitter
https://ikatyang.github.io/tree-sitter-yaml/
MIT License
94 stars 38 forks source link

Installing yaml grammar on osx #53

Open dmmulroy opened 10 months ago

dmmulroy commented 10 months ago

When I try to install the yaml grammar on osx I am encountering the following error:

nvim-treesitter[yaml]: Error during compilation                                                                                          
-macosx_version_min has been renamed to -macos_version_min                                                                               
ld: warning: ignoring duplicate libraries: '-lgcc'                                                                                       
0  0x102b67648  __assert_rtn + 72                                                                                                        
1  0x102a9bfac  ld::AtomPlacement::findAtom(unsigned char, unsigned long long, ld::AtomPlacement::AtomLoc const*&, long long&) const + 12
04                                                                                                                                       
2  0x102ab1924  ld::InputFiles::SliceParser::parseObjectFile(mach_o::Header const*) const + 15164                                        
3  0x102abee30  ld::InputFiles::parseAllFiles(void (ld::AtomFile const*) block_pointer)::$_7::operator()(unsigned long, ld::FileInfo cons
t&) const + 420                                                                                                                          
4  0x19436c440  _dispatch_client_callout2 + 20                                                                                           
5  0x19437ff1c  _dispatch_apply_invoke + 224                                                                                             
6  0x19436c400  _dispatch_client_callout + 20                                                                                            
7  0x19437dfb8  _dispatch_root_queue_drain + 684                                                                                         
8  0x19437e6c0  _dispatch_worker_thread2 + 164                                                                                           
9  0x194518038  _pthread_wqthread + 228                                                                                                  
ld: Assertion failed: (resultIndex < sectData.atoms.size()), function findAtom, file Relocations.cpp, line 1336.                         
collect2: error: ld returned 1 exit status 

My system information is:

image
mvlsqz commented 10 months ago

I've fixed it using zig to compile the c++ project, not sure why the gcc compiler doesn't like something from the code

After install zig, I've exported the following environment variable

export CC="zig c++", then tried to install all parsers, everything worked as expected