What is a framework?

Discussion in 'Mac Programming' started by vgoklani, Apr 26, 2006.

  1. macrumors regular

    vgoklani

    Joined:
    Jul 2, 2004
    #1
    I use the following command to link my C++ source code to the apple implementation of CLAPACK:

    g++ -o code code.cpp -framework veclib

    but what is a framework?
     
  2. macrumors 68000

    savar

    Joined:
    Jun 6, 2003
    Location:
    District of Columbia
    #2
    I don't know the dictionary definition, but a framework is usually a collection of libraries and the headers that declare the interfaces.
     
  3. macrumors 6502a

    NewbieNerd

    Joined:
    Sep 22, 2005
    Location:
    Chicago, IL
    #3
    I think a framework, at least on some level, is comparable to a Windows DLL, or dynamically linked library. Such a library exists as only one copy in memory, at least for the code segment of it, as opposed to statically linked libraries which are copied with every applicatioin that uses it. Though DLLs aren't completely better, they tend to be as you can update the DLLs and all programs depending on them see the benefit without any recompiling/relinking.

    So when you include NSObject.h in a file and compile, linking to the Foundation framework, you are just using the copy of NSObject.c already in memory instead of making another copy.

    Maybe a framework is completely different, hehe, but at least you know what a DLL is. :p
     
  4. macrumors 603

    jeremy.king

    Joined:
    Jul 23, 2002
    Location:
    Fuquay Varina, NC

Share This Page