Can't compile with Turbo C 4.5 Winsock

Discussion in 'C Programming' started by Moe, Nov 13, 2011.

  1. Moe

    Moe Guest

    Whenever I try to use a winsock function I always get an undefined symbol
    error even with winsock.h included. I'm not used to borland but it doesn't
    have a winsock.lib. Even when I downloaded the winsock dev from
    www.sockets.com and put those in I still get those errors. I made a
    project and inserted winsock.lib and STILL got them. How do I use winsock
    functions with it?
     
    Moe, Nov 13, 2011
    #1
    1. Advertising

  2. Moe

    jacob navia Guest

    Le 13/11/11 14:31, Moe a écrit :
    > Whenever I try to use a winsock function I always get an undefined symbol
    > error even with winsock.h included. I'm not used to borland but it doesn't
    > have a winsock.lib. Even when I downloaded the winsock dev from
    > www.sockets.com and put those in I still get those errors. I made a
    > project and inserted winsock.lib and STILL got them. How do I use winsock
    > functions with it?


    That compiler is something like 15-20 years old. Use a newer version of
    borland C.
     
    jacob navia, Nov 13, 2011
    #2
    1. Advertising

  3. Moe

    Rich Webb Guest

    On Sun, 13 Nov 2011 13:31:24 +0000 (UTC), Moe <> wrote:

    >Whenever I try to use a winsock function I always get an undefined symbol
    >error even with winsock.h included. I'm not used to borland but it doesn't
    >have a winsock.lib. Even when I downloaded the winsock dev from
    >www.sockets.com and put those in I still get those errors. I made a
    >project and inserted winsock.lib and STILL got them. How do I use winsock
    >functions with it?


    I don't recall if Turbo C had this utility but later Borland C/C++
    versions included an "implib" utility that would build an import library
    from a given DLL into the format that Borland used. The .lib file format
    may be the problem.

    implib options library_name dll

    where options is -a, prepend underscores; -c, warn on case sensitive
    symbols; -f, force import by name; -w, suppress warnings.

    --
    Rich Webb Norfolk, VA
     
    Rich Webb, Nov 13, 2011
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Chris Thompson

    server using winsock

    Chris Thompson, Sep 2, 2003, in forum: C++
    Replies:
    1
    Views:
    447
    Jim Fischer
    Sep 2, 2003
  2. Abbas Akhtar

    winsock api for newbies

    Abbas Akhtar, Sep 16, 2003, in forum: C++
    Replies:
    2
    Views:
    474
    Peter van Merkerk
    Sep 16, 2003
  3. Jay
    Replies:
    2
    Views:
    396
  4. Dom
    Replies:
    1
    Views:
    12,717
  5. Nagaraj
    Replies:
    1
    Views:
    900
    Lionel B
    Mar 1, 2007
Loading...

Share This Page