title: How to detect different Windows target platforms?
body: <p>I would like to create a common header file for my C/C++ files. In that header file I would like to have compile-time detection of which platform I'm building for and what type of application I'm building for that platform.</p>
  
  <p>The options are:</p>
  
  <ol>
  <li>Desktop App. OS: Win 7 / Win 8.x. CPU: Intel/AMD. Device: PC/Laptop</li>
  <li>Windows Phone App. OS: Windows: 8.x. CPU: ARM. Device: Windows Mobile Phone</li>
  <li>Desktop App. OS: Windows 8.x. CPU: Intel. Device: Tablet</li>
  <li>Store App. OS: Windows 8.x. CPU: Intel. Device: Tablet</li>
  <li>Desktop App. OS: Windows RT. CPU: ARM. Device: Tablet</li>
  <li>Store App. OS: Windows RT. CPU: ARM. Device: Tablet</li>
  </ol>
  
  <p>I'm not sure if [3] and [5] are actual possibilities.</p>
  
  <p>I have looked at winapifamily.h but I'm not sure how to interpret (or understand) the partition table in that header file, so some help would be greatly appreciated.</p>
  
  <p>In the header file I wish to create, I would like something like this:</p>
  
  <pre><code>#ifdef SOME_PREPROCESSOR_DEFINE
  /* Option 1*/
  #endif
  
  #ifdef SOME_PREPROCESSOR_DEFINE
  /* Option 2*/
  #endif
  
  #ifdef SOME_PREPROCESSOR_DEFINE
  /* Option 3*/
  #endif
  
  #ifdef SOME_PREPROCESSOR_DEFINE
  /* Option 4*/
  #endif
  
  #ifdef SOME_PREPROCESSOR_DEFINE
  /* Option 5*/
  #endif
  
  #ifdef SOME_PREPROCESSOR_DEFINE
  /* Option 6*/
  #endif
  </code></pre>
  
  <p>Thank you.</p>