In the code :: blocks compiler for linux, how can one add flag compilations like '-lrt' or '-lboost_thread'?

Debugging in gdb doesn't work for me, so I like the nice debugging interface that code :: blocks offers. Now that I have moved the project to the area where these flags are required (the ones in the title, of course), I found that I could no longer compile to code :: blocks: /.

+1


source to share


1 answer


Hi everyone, I figured out how to add -lrt. Since -lrt is passed to the linker, not the compiler, you can go to Settings-> Compiler and Debugger-> linker options and then click add and after doing "locate lrt" I found this nice library / usr / lib / libaticalrt. so. "I added the library to the linker options and now these errors are gone ... Time to try increasing!



EDIT: Boost was solved in a similar way. The library provided by lboost_thread is libboost_thread.so. The localization is found at "/usr/lib/libboost_thread.so". Adding it to the linker options solved the problem: D

+3


source







All Articles