Hi experts,
I am trying to compile a simple program using OpenCV 2.4.13, but i got always a bunch of errors while compiling.. Can you help me understand how can i compile the program?
I completed this instructions successfully:
http://processors.wiki.ti.com/index.php/Building_OpenCV_for_ARM_Cortex-A8
the program:
#include <opencv/cv.h> //main OpenCV header #include <opencv/highgui.h> //GUI header int main() { // declare a new IplImage pointer IplImage* myimage; // load an image myimage = cvLoadImage("springbreak.jpg",1); //change the file name to your own image //create a new window & display the image cvNamedWindow("Smile", 1); cvShowImage("Smile", myimage); //wait for key to close the window cvWaitKey(0); cvDestroyWindow("Smile"); cvReleaseImage(&myimage); return 0; }
The commad used to compile (i am specifying an installation folder that i have on my host pc):
arm-arago-linux-gnueabi-gcc opencv_hello.c -o opencv_hello -I /home/pfreire/openCV/build/install/include
/tmp/cck0hzXw.o: In function `cvRound':
opencv_hello.c:(.text+0x1c): undefined reference to `lrint'
/tmp/cck0hzXw.o: In function `cvDecRefData':
opencv_hello.c:(.text+0xf00): undefined reference to `cvFree_'
opencv_hello.c:(.text+0xfa8): undefined reference to `cvFree_'
/tmp/cck0hzXw.o: In function `cvGetRow':
(...) undefined reference for a lot of things
Thanks,
Regards,
Pedro