Pregunta

How to install Intel Threading Building Blocks on OSX 10.9, so it can be used with gcc?

I tried to do what usually works for me on Linux:

  1. Download the source.

  2. install using make.

  3. Specify PATH, LD_LIBRARY_PATH, LIBRARY_PATH and CPATH.

  4. Use like

    g++ mycode.cpp -O3 -o mycode -ltbb
    

result:

dyld: Library not loaded: libtbb.dylib
  Referenced from: /blabla/mycode
  Reason: image not found
Trace/BPT trap: 5
¿Fue útil?

Solución

On OSX, it is DYLD_LIBRARY_PATH instead of LD_LIBRARY_PATH

Otros consejos

You can install it via Homebrew:

$ brew install tbb

That takes care of the lib paths, so you only have to add -ltbb to the linker flags.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top