Thread: GCC Compile Problem (link)

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Registered User
    Join Date
    Dec 2011
    Posts
    3

    GCC Compile Problem (link)

    Hi all,
    Really to say I'm not very familar with C and esspecially with C in linux-based systems, bcz. have spent 6 years in C# programming. But now, I'm back to C . So I need your experience help.

    Here is the problem: I cannot compile the C project (DiskSim) because recieve the following error: "undefined reference to `sqrt'"
    But the main problem is that in makefile THERE IS link flag -lm to math.h

    Any ideas?

    My system:
    ubuntu 11.10 x64
    gcc, g++ 4.6
    flex, bison 2.5
    KDevelop as IDE

    I have attached the error log file, the makefile. (let me know if you need the whole project - but it is about 5 Mb)

    Thanks a lot for any help.
    Best,
    Timbuktu
    Attached Files Attached Files
    Last edited by Timbuktu; 12-07-2011 at 01:16 PM.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. How to compile and link koolplot?
    By angela3017 in forum Linux Programming
    Replies: 4
    Last Post: 02-18-2011, 01:00 AM
  2. Compile and Link tutorials
    By tapti in forum C Programming
    Replies: 12
    Last Post: 08-04-2009, 03:23 AM
  3. Pimpl Idiom client/serve compile/link
    By George2 in forum C++ Programming
    Replies: 12
    Last Post: 03-15-2008, 06:25 AM
  4. Compile/Link errors...
    By Xenent in forum Game Programming
    Replies: 2
    Last Post: 10-23-2002, 05:39 PM
  5. Compile/Link errors...
    By Xenent in forum C++ Programming
    Replies: 2
    Last Post: 10-21-2002, 04:13 PM

Tags for this Thread