Why do sketches take up so much space and memory? When I compile this sketch for the Yún:

int led = 7;

void setup() {                
  pinMode(led, OUTPUT);     
}

void loop() {
  digitalWrite(led, HIGH);
}


I get:


  Sketch uses 5,098 bytes (17%) of program storage space. 
  
  Maximum is
  28,672 bytes. Global variables use 153 bytes (5%) of dynamic memory,
  leaving 2,407 bytes for local variables. Maximum is 2,560 bytes.


Even when I compile the BareMinimum sketch:

void setup() {                
  // setup    
}

void loop() {
  // loop
}


I get:


  Sketch uses 4,548 bytes (15%) of program storage space.
  
  Maximum is
  28,672 bytes. Global variables use 151 bytes (5%) of dynamic memory,
  leaving 2,409 bytes for local variables. Maximum is 2,560 bytes.


Why does a bare minimum sketch take up 15% of the program storage space allocated? And why does a very simple sketch take up 17% of the program storage space? According to the Arduino website:


  It's easy to use it all up by having lots of strings in your program.
  For example, a declaration like: char message[] = "I support the Cape
  Wind project."; puts 33 bytes into SRAM (each character takes a byte,
  plus the '\0' terminator).


However, there aren't any strings declared in either of these sketches.

It seems as if they might import or use other libraries/classes that I don't specify. Maybe it imports a system default library? Or is it something else?
Arduino compiles in a lot of standard libraries, interrupts, ... etc. For example the pinMode and digitalWrite functions use a lookup table to figure out at run time which GPIO registers to write data to. Another example is that Arduino keeps track of time, it defines some interrupts by default and all this functionality requires some space. You'll notice that if you extend the program, the foot print will only change slightly.

I personally like to program controllers with bare minimum, without "bloat", but you'll quickly enter the world of EE.SE and SO because several easy to use functions will no longer work out of the box. There are some alternative libraries for pinMode and digitalWrite that compile into a smaller footprint, but come with other disadvantages like for example static compiled pins (where led cannot be a variable, but is a constant).