title: Asio C++ Library: asio/detail/config.hpp: No such file or directory
body: <p>I downloaded the latest standalone version of <a href="http://think-async.com/Asio/Download" rel="nofollow">Boost's Asio Library</a>. Now I would like to integrate the header-only library in a simple qt creator c++ project. But if i try to run the "hello world" example with asio.hpp included I get the following error message (see below for full error message):</p>
  
  <pre><code>asio/detail/config.hpp: No such file or directory
  </code></pre>
  
  <p>These are the steps i took so far</p>
  
  <ol>
  <li>created a new project (c++ with qmake) in qt creator</li>
  <li>extracted the asio library</li>
  <li>copied the include and src folder of asio into a "libs" directory in my project</li>
  <li><p>specified in the .pro file that c++11 should be used by </p>
  
  <p>CONFIG += c++11</p></li>
  <li><p>moreover i tried to add the following defines in my main:</p></li>
  </ol>
  
  <blockquote>
  <pre><code> #define ASIO_STANDALONE
   #define ASIO_HAS_STD_ADDRESSOF
   #define ASIO_HAS_STD_ARRAY
   #define ASIO_HAS_CSTDINT
   #define ASIO_HAS_STD_SHARED_PTR
   #define ASIO_HAS_STD_TYPE_TRAITS
  
   #include &lt;iostream&gt;
   #include "libs/asio/include/asio.hpp"
  
   using namespace std;
  
   int main()
   {
       cout &lt;&lt; "Hello World!" &lt;&lt; endl;
       return 0;
   }
  </code></pre>
  </blockquote>
  
  <ol start="6">
  <li><p>It seems that qmake does not know about all includes. I'm not very fimilar with cmake, qmake and this stuff. So as a noob I tried to add a new INCLUDEPATH in the .pro file ...</p>
  
  <p>INCLUDEPATH += ./libs/asio/include</p></li>
  </ol>
  
  <p>...and got a new error:</p>
  
  <pre><code>boost/detail/atomic_count.hpp: No such file or directory
  </code></pre>
  
  <p>This is the complete error message for my first error:</p>
  
  <pre><code>make: Entering directory `/home/ubuntu/asiotest-build-desktop-Qt_4_8_1_in_PATH__System__Release'
  /usr/bin/qmake-qt4 -spec /usr/share/qt4/mkspecs/linux-g++ -o Makefile ../asiotest/asiotest.pro
  make: Leaving directory `/home/ubuntu/asiotest-build-desktop-Qt_4_8_1_in_PATH__System__Release'
  make: Entering directory `/home/ubuntu/asiotest-build-desktop-Qt_4_8_1_in_PATH__System__Release'
  g++ -c -pipe -O2 -Wall -W -DQT_WEBKIT -I/usr/share/qt4/mkspecs/linux-g++ -I../asiotest -I../asiotest -I. -o main.o ../asiotest/main.cpp
  In file included from ../asiotest/libs/asio/include/asio.hpp:18:0,
                   from ../asiotest/main.cpp:9:
  ../asiotest/libs/asio/include/asio/async_result.hpp:18:34: fatal error: asio/detail/config.hpp: No such file or directory
  compilation terminated.
  make: Leaving directory `/home/ubuntu/asiotest-build-desktop-Qt_4_8_1_in_PATH__System__Release'
  make: *** [main.o] Error 1
  17:55:01: The process "/usr/bin/make" exited with code 2.
  Error while building project asiotest (target: Desktop)
  When executing build step 'Make'
  </code></pre>
  
  <p>the file hierarchie:</p>
  
  <pre><code>asiotest (project folder)
  -- asiotest.pro
  -- sources (folder)
  ---- main.cpp
  -- libs (folder)
  ---- asio (folder)
  ------- include(folder)
  ---------- asio.hpp 
  ---------- asio (folder)
  ------------- detail (folder)
  ------------- more folders
  ------- src
  ---------- asio.cpp
  ---------- asio_ssl.cpp
  </code></pre>
  
  <p><strong>How can I teach qt to search for the include files in the right directory?</strong></p>
  
  <p>Note: Sorry for the quote around the source code but i didn't managed to get the code highlighted in the numbered list by simple using the source code "tag".</p>