title: qt generate header file containing git hash at compile time and force rebuild using files
body: <p>I figured out how to generate define macro containing git hash at compile time:</p>
  
  <pre><code>DEFINES += GIT_CURRENT_SHA1="\\\"$(shell git -C \""$$_PRO_FILE_PWD_"\" describe)\\\""
  </code></pre>
  
  <p>The problem is that when the git hash is changed, the files (mainwindow.cpp which is adding text to about dialog) which are using the GIT_CURRENT_SHA1 are not automatically rebuilt (obviously)..</p>
  
  <p>I would like to generate header file at compile time containing git hash like in 
  const char *git_hash="git-hash-etc-etc"; </p>
  
  <p>And this header file I would include in mainwindow.cpp and hope it would be recompiled when the header changes..</p>
  
  <p>My question is mainly what to add into .pro file to generate such file from Makefile?</p>
  
  <p>Thanks.</p>