title: fatal error: avr/io.h: No such file or directory arduino
body: <p>I'm trying to test a library for an DHT22 "Temperature Sensor", but I got an error while including an internal arduino library from the <code>DHT.cpp</code> file</p>
  
  <p>I got this error:</p>
  
  <pre><code>C:\Program Files (x86)\Arduino\libraries\DHT\DHT22.cpp:56:20:
  fatal error: avr/io.h: No such file or directory  #include &lt;avr/io.h&gt;
  </code></pre>
  
  <p>In the <code>DHT22.cpp</code>, this is the the block of error</p>
  
  <pre class="lang-c prettyprint-override"><code>extern "C" {
   #include &lt;avr/io.h&gt;
   #include &lt;avr/interrupt.h&gt;
   #include &lt;avr/pgmspace.h&gt;
  }
  </code></pre>
  
  <p>I got in the conclusion that the library is not finding the avr folder which is 
  in  <code>C:\Program Files (x86)\Arduino\hardware\tools\avr\avr\include\avr</code> I checked another built-in library servo.cpp and this is the include part</p>
  
  <pre class="lang-c prettyprint-override"><code>#include &lt;avr/interrupt.h&gt;
  #include &lt;Arduino.h&gt;
  </code></pre>
  
  <p>but the last one works without errors, my question is why the DHT library is not importing the required files and the servo does ?</p>