title: Using pcre2 in a c++ project
body: <p>I am looking at using pcre2 in my simple c++ app, (I am using vs2015).
  (I am looking at various regex libraries and the general feeling is that pcre/pcre2 are the most flexible)</p>
  
  <p>First I downloaded pcre2 from the official location, (<a href="http://sourceforge.net/projects/pcre/files/pcre2/10.20/" rel="noreferrer">http://sourceforge.net/projects/pcre/files/pcre2/10.20/</a>) and created a very simple example.</p>
  
  <pre><code>#define PCRE2_CODE_UNIT_WIDTH 8
  #include &lt;pcre2.h&gt;
  ...
  PCRE2_SPTR subject = (PCRE2_SPTR)std::string("this is it").c_str();
  PCRE2_SPTR pattern = (PCRE2_SPTR)std::string("([a-z]+)|\\s").c_str();
  
  ...
  int errorcode;
  PCRE2_SIZE erroroffset;
  pcre2_code *re = pcre2_compile(pattern, PCRE2_ZERO_TERMINATED, 
                                  PCRE2_ANCHORED | PCRE2_UTF, &amp;errorcode,  
                                  &amp;erroroffset, NULL);
  ...
  </code></pre>
  
  <p>First of all the file "<em>pcre2.h</em>" does not exist, so I renamed <em>pcre2.h.generic</em> to <em>pcre2.h</em></p>
  
  <p>But then I get linker errors with unresolved externals.</p>
  
  <p>I am guessing I need to include one or more files from the source to project.
  But I am reluctant to just randomly add files without knowing what it all does.</p>
  
  <p>Can someone give some simple steps to follow to successfully build a project using pcre2?</p>
  
  <p><strong>UPDATE</strong><br>
  This is not an import library issue, pcre2.h does not come with a librar, (not one that I can see in their release location).</p>