vnmakarov / mir

A lightweight JIT compiler based on MIR (Medium Internal Representation) and C11 JIT compiler and interpreter based on MIR
MIT License
2.29k stars 145 forks source link

fixed CMakeLists.txt: #406

Closed byte0xcafe closed 3 months ago

byte0xcafe commented 3 months ago

cmake failed for me (master & 1.0.0-release):

[ 5%] Built target mir [ 6%] Built target mir_static [ 8%] Built target mir_shared [ 10%] Linking C executable c2m /usr/bin/ld: CMakeFiles/mir.dir/c2mir/c2mir.c.o: in function `check_assign_op\': c2mir.c:(.text+0x169e9): undefined reference to `nanl' clang: error: linker command failed with exit code 1 (use -v to see invocation) make[2]: [CMakeFiles/c2m.dir/build.make:103: c2m] Error 1 make[1]: [CMakeFiles/Makefile2:977: CMakeFiles/c2m.dir/all] Error 2 make: *** [Makefile:101: all] Error

therefore added '-lm' to target 'mir'