ooc-lang / rock

:ocean: self-hosted ooc compiler that generates c99
http://ooc-lang.org/
MIT License
401 stars 40 forks source link

Problem installing: GC_jmp_buf multiple definition #1009

Closed nikos-alexandris closed 3 years ago

nikos-alexandris commented 3 years ago

Hello, i'm trying to install ooc on fedora 34 x86_64 linux with gcc 11.1.1 and when i run make rescue it fails with multiple linker errors stating that GC_jmp_buf has been defined multiple times. Specifically, it seems that it is trying to define it in /rock/vendor-prefix/lib/libgc.a when it has been defined in rock/vendor-build/../vendor/gc/include/private/gc_priv.h:2316 Does anyone have a fix for this?

horasal commented 3 years ago

It seems that libgc in vendor is a little outdated - it's still 7.2e (published in 2013). also I noticed that libgc does fix a similar problem in 2017 here

clone latest gc and try again may help

mv vendor/gc vendor/gc1
git clone https://github.com/ivmai/bdwgc vendor/gc
cd vendor/gc && ./autogen.sh && cd ../../
make rescue
nikos-alexandris commented 3 years ago

Worked like a charm! Thanks!