Qt: Fix automoc when .h and .cpp are in different directories.

Thanks Pau Garcia i Quiles for the patch.
Qt: Enable running automoc test with Qt4 or Qt5.

Previously, the automoc tests required both Qt4 and Qt5.
KWSys 2014-08-04 (e787837a)

Extract upstream KWSys using the following shell commands.

$ git archive --prefix=upstream-kwsys/ e787837a | tar x
$ git shortlog --no-merges --abbrev=8 --format='%h %s' 65b36ede..e787837a
Ben Boeckel (4):
      9927862c SystemTools: more string replacements
      b3d598b0 strings: remove unnecessary c_str calls
      ffe94132 SystemTools: use char instead of const char*
      f29fec7c Directory: accept strings in methods

Rashad M (1):
      e787837a SharedForward: Cast away const to call execvp on MinGW 64-bit

Change-Id: I96437b332971670cfcd953717c5563e9ba0f2b99
Merge branch 'upstream-kwsys' into update-kwsys
Merge topic 'update-kwsys' into next

60c78367 Merge branch 'upstream-kwsys' into update-kwsys
158c6d1c KWSys 2014-08-04 (e787837a)
Merge topic 'qt-automoc' into next

20f56fe4 Qt: Enable running automoc test with Qt4 or Qt5.
6e576baa Qt: Fix automoc when .h and .cpp are in different directories.