Hi everyone,
I have a problem trying to compile and build your Halide examples (located in $HOME_PATH/Qualcomm/Hexagon_SDK/3.3.2/tools/HEXAGON_Tools/8.1.05/Tools/Halide/Examples) when iostream is added.
Out-of-the-box they are fine. For example, gaussian5x5 can be compiled, run, passed to hexagon-sim, all good. But just by adding #include <iostream> (or fstream or anything that has to do with streams) to gaussian5x5_run.cpp file, hexagon-clang++ throws an error:
In file included from /home/ugljesa/work/Qualcomm/Hexagon_SDK/3.3.2/tools/HEXAGON_Tools/8.1.05/Tools/bin/../target/hexagon/include/c++/v1/fstream:169:
In file included from /home/ugljesa/work/Qualcomm/Hexagon_SDK/3.3.2/tools/HEXAGON_Tools/8.1.05/Tools/bin/../target/hexagon/include/c++/v1/ostream:138:
In file included from /home/ugljesa/work/Qualcomm/Hexagon_SDK/3.3.2/tools/HEXAGON_Tools/8.1.05/Tools/bin/../target/hexagon/include/c++/v1/ios:216:
In file included from /home/ugljesa/work/Qualcomm/Hexagon_SDK/3.3.2/tools/HEXAGON_Tools/8.1.05/Tools/bin/../target/hexagon/include/c++/v1/__locale:18:
In file included from /home/ugljesa/work/Qualcomm/Hexagon_SDK/3.3.2/tools/HEXAGON_Tools/8.1.05/Tools/bin/../target/hexagon/include/c++/v1/mutex:176:
In file included from /home/ugljesa/work/Qualcomm/Hexagon_SDK/3.3.2/tools/HEXAGON_Tools/8.1.05/Tools/bin/../target/hexagon/include/c++/v1/__mutex_base:17:
/home/ugljesa/work/Qualcomm/Hexagon_SDK/3.3.2/tools/HEXAGON_Tools/8.1.05/Tools/bin/../target/hexagon/include/c++/v1/__threading_support:23:10: fatal error:
'pthread.h' file not found
#include <pthread.h>
Not sure why it can not find pthread.h... it is in /usr/include folder, works fine for some other native posix applications. Runnning and building file (test-gaussian5x5) is not changed. Any idea or suggestion how to solve this problem is more than welcomed.
All the best,
Ugi
Hi Ugi, did you solve it? I encounter the same problem.