Note that there are some explanatory texts on larger screens.

plurals
  1. POCan't compile first opencv program, '/usr/bin/ld: cannot find -lcv'
    primarykey
    data
    text
    <pre><code>g++ cv.cpp -o cv -I /usr/local/include/opencv -L /usr/local/lib -lm -lcv -lhighgui -lcvaux </code></pre> <p>Error:</p> <pre><code>/usr/bin/ld: cannot find -lcv collect2: ld returned 1 exit status </code></pre> <p>Code:</p> <pre class="lang-c prettyprint-override"><code>#include &lt;cv.h&gt; #include &lt;ml.h&gt; #include &lt;cxcore.h&gt; //#include &lt;cxtypes.h&gt; #include &lt;highgui.h&gt; int main(int argc, char* argv[]) { IplImage* img = cvLoadImage( "bal.png" ); cvNamedWindow( "Example1", CV_WINDOW_AUTOSIZE ); cvShowImage("Example1", img); cvWaitKey(0); cvReleaseImage( &amp;img ); cvDestroyWindow( "Example1" ); return 0; } </code></pre> <p>It's 32 bit, </p> <pre><code>locate libcv /usr/lib/libcv.so.2.1 /usr/lib/libcv.so.2.1.0 </code></pre> <hr> <pre><code>`pkg-config --cflags --libs opencv` -I/usr/local/include/opencv -I/usr/local/include /usr/local/lib/libopencv_calib3d.so /usr/local/lib/libopencv_contrib.so /usr/local/lib/libopencv_core.so /usr/local/lib/libopencv_features2d.so /usr/local/lib/libopencv_flann.so /usr/local/lib/libopencv_gpu.so /usr/local/lib/libopencv_highgui.so /usr/local/lib/libopencv_imgproc.so /usr/local/lib/libopencv_legacy.so /usr/local/lib/libopencv_ml.so /usr/local/lib/libopencv_nonfree.so /usr/local/lib/libopencv_objdetect.so /usr/local/lib/libopencv_photo.so /usr/local/lib/libopencv_stitching.so /usr/local/lib/libopencv_ts.so /usr/local/lib/libopencv_video.so /usr/local/lib/libopencv_videostab.so </code></pre> <hr> <p>Installed OpenCV-2.4.0 in /usr/local, I also have a system python-opencv. Where am i doing the mistake? What should i do?</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload