Ask Your Question

onitcales's profile - activity

2019-11-12 16:53:12 -0600 received badge  Notable Question (source)
2019-01-14 14:51:59 -0600 received badge  Popular Question (source)
2015-04-19 11:36:20 -0600 commented question error adding symbols: File in wrong format collect2: error: ld returned 1 exit status

Tank you Berak! I tranlate this via google!

2015-04-19 11:30:45 -0600 received badge  Editor (source)
2015-04-19 00:42:00 -0600 asked a question error adding symbols: File in wrong format collect2: error: ld returned 1 exit status

Escrevi este pequeno código para testar o uso do opencv.(I wrote this little code to test the opencv use.)

//teste.cpp-----------------------------------------------------------------------------
#include </usr/local/include/opencv/highgui.h>
int main(int argc, char** argv)
{
IplImage* img = cvLoadImage (argv[1]);
cvNamedWindow ("Exemplo 1", CV_WINDOW_AUTOSIZE);
cvShowImage ("Exemplo 1", img);
cvWaitKey(0);
cvReleaseImage(&img);
cvDestroyWindow("Exemplo 1");
}

Porém quando tento compilar no terminal, usando: (but when I try to build in terminal mode using:)

gcc -o teste teste.cpp pkg-config --libs opencv

recebo esta mensagem: (I received this message:) /usr/local/lib/libopencv_calib3d.so: error adding symbols: File in wrong format collect2: error: ld returned 1 exit status

como corrigir isso? ( how to fix this?)