OpenVX-sample-impl icon indicating copy to clipboard operation
OpenVX-sample-impl copied to clipboard

fatal error: VX/vx.h: No such file or directory #include <VX/vx.h>

Open SijinJohn opened this issue 4 years ago • 11 comments

/home/pi/OpenVX/OpenVX-sample-impl/cts/test_engine/test_utils.h:21:10: fatal error: VX/vx.h: No such file or directory #include <VX/vx.h> ^~~~~~~~~ compilation terminated.

i am getting this error on Raspberry pi 3.

SijinJohn avatar Dec 11 '20 03:12 SijinJohn

refer this

https://github.com/KhronosGroup/OpenVX-sample-impl/issues/14

balaji-ch avatar Dec 11 '20 05:12 balaji-ch

@balaji-ch

i followed this

Use the Build.py script to build and install OpenVX 1.3 cd OpenVX-sample-impl/ python Build.py --os=Linux --venum --conf=Debug --conf_vision --enh_vision --conf_nn

Build and run the conformance:

export OPENVX_DIR=$(pwd)/install/Linux/x32/Debug export VX_TEST_DATA_PATH=$(pwd)/cts/test_data/ mkdir build-cts cd build-cts cmake -DOPENVX_INCLUDES=$OPENVX_DIR/include -DOPENVX_LIBRARIES=$OPENVX_DIR/bin/libopenvx.so;$OPENVX_DIR/bin/libvxu.so;pthread;dl;m;rt -DOPENVX_CONFORMANCE_VISION=ON -DOPENVX_USE_ENHANCED_VISION=ON -DOPENVX_CONFORMANCE_NEURAL_NETWORKS=ON ../cts/ cmake --build .

SijinJohn avatar Dec 11 '20 06:12 SijinJohn

Looking at your post export OPENVX_DIR=$(pwd)/install/Linux/x32/Debug I guess, you are trying a 32bit build. then the build command must be python Build.py --os=Linux --venum --conf=Debug --conf_vision --enh_vision --conf_nn --arch=32

Read the Build.py comments and enable needed flags. parser.add_option("--arch", dest="arch", help="Set the architecture (32 / 64 bit) [Default 64]", default='64')

balaji-ch avatar Dec 11 '20 08:12 balaji-ch

So do i need to do build command again from the beginning ??

I tried with your command :- python Build.py --os=Linux --venum --conf=Debug --conf_vision --enh_vision --conf_nn --arch=32 but same issue

SijinJohn avatar Dec 11 '20 10:12 SijinJohn

Delete everything and start afresh, following the build instructions carefully. unless you specifically want a 32 bit build , you don't need to specify arch=32 .

And still you are stuck, post all the command sequence you have used starting form git clone --recursive.

balaji-ch avatar Dec 11 '20 10:12 balaji-ch

I followed this tutorial:-

https://www.raspberrypi.org/blog/openvx-api-for-raspberry-pi/

SijinJohn avatar Dec 11 '20 10:12 SijinJohn

That blog post is the same as in Sample 2 - Build OpenVX 1.3 on Raspberry Pi https://github.com/KhronosGroup/OpenVX-sample-impl

Not sure about your error. Start afresh and see .

balaji-ch avatar Dec 11 '20 11:12 balaji-ch

@SijinJohn, let us know if this issue is resolved for you. The missing header file errors are due to missing submodules. Use the recursive clone flag to fix this.

kiritigowda avatar Dec 13 '20 00:12 kiritigowda

@kiritigowda

not resolved This step-> cmake -DOPENVX_INCLUDES=$OPENVX_DIR/include -DOPENVX_LIBRARIES=$OPENVX_DIR/bin/libopenvx.so;$OPENVX_DIR/bin/libvxu.so;pthread;dl;m;rt -DOPENVX_CONFORMANCE_VISION=ON -DOPENVX_USE_ENHANCED_VISION=ON -DOPENVX_CONFORMANCE_NEURAL_NETWORKS=ON ../cts/ gives error CMake Error: The source directory "/home/pi/OpenVX/OpenVX-sample-impl/build-cts" does not appear to contain CMakeLists.txt.

CmakeLists.txt is in OpenVX-sample-impl not inside build-cts I am not getting this error.

SijinJohn avatar Dec 14 '20 05:12 SijinJohn

@SijinJohn follow instructions below, see the Travis build log for more information.

Build OpenVX 1.3 on Raspberry Pi

  • Git Clone project with a recursive flag to get submodules
git clone --recursive https://github.com/KhronosGroup/OpenVX-sample-impl.git
  • Use Build.py script
cd OpenVX-sample-impl/
python Build.py --os=Linux --venum --conf=Debug --conf_vision --enh_vision --conf_nn
  • Build and run the conformance
export OPENVX_DIR=$(pwd)/install/Linux/x32/Debug
export VX_TEST_DATA_PATH=$(pwd)/cts/test_data/
mkdir build-cts
cd build-cts
cmake -DOPENVX_INCLUDES=$OPENVX_DIR/include -DOPENVX_LIBRARIES=$OPENVX_DIR/bin/libopenvx.so\;$OPENVX_DIR/bin/libvxu.so\;pthread\;dl\;m\;rt -DOPENVX_CONFORMANCE_VISION=ON -DOPENVX_USE_ENHANCED_VISION=ON -DOPENVX_CONFORMANCE_NEURAL_NETWORKS=ON ../cts/
cmake --build .
LD_LIBRARY_PATH=./lib ./bin/vx_test_conformance

kiritigowda avatar Dec 14 '20 06:12 kiritigowda

@kiritigowda When i run this:- cmake --build . I get this Scanning dependencies of target generate_version_file -- Get version information -- Version: 7aed89e [ 0%] Built target generate_version_file Scanning dependencies of target test_engine [ 1%] Building C object test_engine/CMakeFiles/test_engine.dir/test_bmp.c.o In file included from /home/pi/OpenVX/OpenVX-sample-impl/cts/test_engine/test.h:91, from /home/pi/OpenVX/OpenVX-sample-impl/cts/test_engine/test_bmp.c:18: /home/pi/OpenVX/OpenVX-sample-impl/cts/test_engine/test_utils.h:21:10: fatal error: VX/vx.h: No such file or directory #include <VX/vx.h> ^~~~~~~~~ compilation terminated. make[2]: *** [test_engine/CMakeFiles/test_engine.dir/build.make:82: test_engine/CMakeFiles/test_engine.dir/test_bmp.c.o] Error 1 make[1]: *** [CMakeFiles/Makefile2:223: test_engine/CMakeFiles/test_engine.dir/all] Error 2 make: *** [Makefile:149: all] Error 2

SijinJohn avatar Dec 14 '20 06:12 SijinJohn