define a weak Test::RunTestsImpl() symbol to avoid link errors
commit3845683a86cc1a7eda3cfc18be5d807a9fdc7b3d
authorAdam Simpkins <simpkins@fb.com>
Fri, 25 Jan 2019 21:28:26 +0000 (25 13:28 -0800)
committerHhvm Bot <hhvm-bot@users.noreply.github.com>
Fri, 25 Jan 2019 21:40:23 +0000 (25 13:40 -0800)
tree2da5f7fdf010f3f0c02521b89db7c9b94432a535
parentc884881e48f3a110753dbaa4fc93ee865cc12600
define a weak Test::RunTestsImpl() symbol to avoid link errors

Summary:
The test.cpp file uses `Test::RunTestsImpl()` but previously did not define
it.  It is instead provided by a separate library at runtime.  However, this
library itself depends on the library that contains test.cpp, causing a
circular dependency.  This circular dependencies causes linking to fail
depending on the build mode that is used.

This fixes the circular dependency issue by making `test.cpp` provide a
default `Test::RunTestsImpl()` implementation, but defining it as a weak
symbol so that subsequent libraries can override it.

Reviewed By: markw65

Differential Revision: D13790133

fbshipit-source-id: 2491a185178ae68514650ef599c276e9c1b6000c
hphp/test/ext/test.cpp