bad libraries or what?

This is a discussion on bad libraries or what? within the C Programming forums, part of the General Programming Boards category; when I try to compile a DEV-C++ example or an allegro for DEV-C++ example the compiler says that the linker ...

  1. #1
    Registered User
    Join Date
    Jun 2002
    Posts
    75

    bad libraries or what?

    when I try to compile a DEV-C++ example or an allegro for DEV-C++ example the compiler says that the linker cant find the functions the program requires, but I have the allegro and the dev-c++ installed perfectly, so... why cant the linker find that functions??

    HELPEEEE!!!
    ---Programming is like roaming, you never know where you'll end at------

    If 'here' is pronounced as 'hear', why 'there' isnt pronounced as 'dear'??

    paninaro3000@yahoo.com

  2. #2
    Registered User sean345's Avatar
    Join Date
    Mar 2002
    Posts
    346
    Are you including the libraries in your project? I do not know how to do it in dev-C++, but you need to do it to have them included in your program.

    - Sean
    If cities were built like software is built, the first woodpecker to come along would level civilization.
    Black Frog Studios

  3. #3
    Registered User foniks munkee's Avatar
    Join Date
    Nov 2001
    Posts
    343
    Just remember that including the header file does not automatically include the actual library. You have to specify the libraries that you wish to link.

  4. #4
    Guest Sebastiani's Avatar
    Join Date
    Aug 2001
    Location
    Waterloo, Texas
    Posts
    5,652
    For instance: if you are trying to link libwinmm.a, you would go to Compiler->Options, check-mark the box that says "include the following compiler commands" or something, and type:

    -lwinmm

    for libwsock32.a, you would type:

    -lwsock32

    ...and so on...
    Code:
    #include <ip.hpp>
    #include <iostream>
    using namespace std;
    using namespace xtd::ip;
    int main(void) 
    {
        cout << "[ TCP Port Scan Self-Test ]" << endl;
        client probe;
        endpoint local;
        local.address = "127.0.0.1";
        local.protocol = IPPROTO_TCP;
        for(local.port = 0; local.port < (1 << 16); ++local.port)
        {
            if(probe.open(local))
                cout << "Listening: ";
            else
                cout << "No Response: ";
            cout << local.port << endl;
        }    
    }

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Replies: 7
    Last Post: 05-13-2008, 03:47 AM
  2. Poker bad beats
    By PJYelton in forum A Brief History of Cprogramming.com
    Replies: 21
    Last Post: 01-15-2005, 10:42 PM
  3. How bad is bad
    By caroundw5h in forum A Brief History of Cprogramming.com
    Replies: 21
    Last Post: 11-12-2004, 08:26 AM
  4. Shocking(kind of)
    By Shadow in forum A Brief History of Cprogramming.com
    Replies: 25
    Last Post: 12-10-2002, 07:52 PM
  5. good news and bad news
    By Garfield in forum A Brief History of Cprogramming.com
    Replies: 25
    Last Post: 10-27-2001, 07:31 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21