tum-ei-eda / etiss

Extendable Translating Instruction Set Simulator
https://tum-ei-eda.github.io/etiss/
Other
29 stars 36 forks source link

TCC fails to compile on systems with `glibc` > 2.34 #108

Closed wysiwyng closed 1 year ago

wysiwyng commented 2 years ago

TCC uses the deprecated glibc function __malloc_hook internally. This function was marked deprecated for some years now (since glibc version 2.14), but has finally been removed from glibc in version 2.34, meaning TCC now fails to compile on systems already using this version.

Possible solutions: 1) Use TCC from a maintained fork, such as https://repo.or.cz/w/tinycc.git 2) Patch TCC before compilation to disable the problematic code parts

Both solutions have their problems: 1) All maintained forks have not had a stable release since 2017, so some commit would have to be picked quite arbitrarily 2) Adds more hackery to the already less-than-optimal compile process of TCC

I have tested both solutions and they seem to work unchanged from the original.