creating and using .lib files

Discussion in 'C++' started by slashman, Nov 5, 2004.

  1. slashman

    slashman Guest

    Hi,
    I wud like to know how to create and use .lib files from a few c++
    classes i have created that are common to a lot of my projects. My
    guess is .lib files can b used in windows and linux (please correct me
    if i'm worng). And if u guys cud also let me know where i cud find out
    such information in the future (books or websites) it would b
    x-tremely helpful
    thanks in advance
    vivek
    slashman, Nov 5, 2004
    #1
    1. Advertising

  2. slashman wrote:
    > Hi,
    > I wud like to know how to create and use .lib files from a few c++
    > classes i have created that are common to a lot of my projects.


    .lib is a file extension used by MS VC++ implementation for library
    archives. The C++ standard does not specify the extension / format
    of the archive. So if you want to create an archive for your
    classes, you have to check out the implementation details.

    <OT>
    Say, on GCC environment - you would use the gcc -c option to
    get the .o files. and then 'ar' command to archive.
    This could be different on your implementation.
    </OT>

    >My
    > guess is .lib files can b used in windows and linux (please correct me
    > if i'm worng).



    You cannot play around with the same .lib file across
    different software platforms. You have to compile them
    specifically with the relevant build system for the
    target platform.


    > And if u guys cud also let me know where i cud find out
    > such information in the future (books or websites) it would b
    > x-tremely helpful


    google.com for your favourite implementation
    (MS VC++, GNU C++ whatever).

    --
    Karthik. http://akktech.blogspot.com .
    ' Remove _nospamplz from my email to mail me. '
    Karthik Kumar, Nov 5, 2004
    #2
    1. Advertising

  3. slashman

    Guest

    (slashman) wrote in message news:<>...
    [snip other mangled `leet speak]
    > (please correct me
    > if i'm worng)


    What is the antonym for elite?
    Socks
    , Nov 12, 2004
    #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. James Yong
    Replies:
    0
    Views:
    532
    James Yong
    Sep 12, 2005
  2. Replies:
    3
    Views:
    2,731
  3. NAKAMURA, Hiroshi
    Replies:
    0
    Views:
    121
    NAKAMURA, Hiroshi
    Jul 6, 2004
  4. Stefano Crocco
    Replies:
    0
    Views:
    77
    Stefano Crocco
    Oct 17, 2008
  5. andreux
    Replies:
    3
    Views:
    181
    Hassan Schroeder
    Jan 8, 2009
Loading...

Share This Page