Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7667841
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T15:12:25+00:00 2026-05-31T15:12:25+00:00

I am compiling a program with the following flags and getting errors (running 64

  • 0

I am compiling a program with the following flags and getting errors (running 64 bit os):

g++ -lm -lml -lcvaux -lhighgui -lcv -lcxcore main.o BRIEF.o -o BRIEF_demo

I get a bunch of undefined references:

main.cpp:(.text+0x1f6): undefined reference to `cvInitMatHeader'

main.cpp:(.text+0x218): undefined reference to cvInitMatHeader'
main.o: In function
_Z14drawQuadrangleP9_IplImageiiiiiiii8CvScalari.constprop.77′:
main.cpp:(.text+0x2d5): undefined reference to cvLine'
main.cpp:(.text+0x333): undefined reference to
cvLine’
main.cpp:(.text+0x398): undefined reference to cvLine'
main.cpp:(.text+0x3f2): undefined reference to
cvLine’

Anyone have an idea how to circumvent this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T15:12:26+00:00Added an answer on May 31, 2026 at 3:12 pm

    I suppose you are using the newest OpenCV 2.3.x. cvInitMatHeader() and cvLine() are actually defined in libcxcore.so, which I can see you are including.

    My guess is that the order of the linking is wrong, so you need to adjust your command to something like:

    g++ main.cpp BRIEF.cpp -o BRIEF_demo -lm -lml -lcvaux -lhighgui -lcv -lcxcore
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am getting the following error while compiling a sample program in Qt 4.5
I'm getting errors while compiling a program that uses threads. Here is the part
I'm having problems compiling the following program. I'm using gcc -framework Foundation inherit8.1m and
Will the following program cause any problem during compiling and execution process? class A{
when compiling my program with GCC I get the following warning: format ‘%d’ expects
My MS Visual C# program was compiling and running just fine. I close MS
The following program: #include <boost/range/concepts.hpp> #include <iterator> #include <istream> using boost::range_detail::SinglePassIteratorConcept; int main() {
I have the following program: ~/test> cat test.cc int main() { int i =
I want to run Open MPI program in Xcode. I follow http://www.macresearch.org/compiling-running-and-debugging-mpi-programs-xcode tutorial. I
Recently I tried compiling program something like this with GCC: int f(int i){ if(i<0){

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.