mirror of
https://github.com/bitwiseworks/gcc-os2.git
synced 2026-07-10 18:57:06 +00:00
Source URL: git://gcc.gnu.org/git/gcc.git Source Commit: 3e7b85061947bdc7c7465743ba90734566860821
14 lines
359 B
D
14 lines
359 B
D
import core.runtime, core.sys.posix.dlfcn;
|
|
|
|
extern(C) alias RunTests = int function();
|
|
|
|
extern(C) int runDepTests(const char* name)
|
|
{
|
|
auto h = rt_loadLibrary(name);
|
|
if (h is null) return false;
|
|
auto runTests = cast(RunTests).dlsym(h, "runTests");
|
|
assert(runTests !is null);
|
|
if (!runTests()) return false;
|
|
return rt_unloadLibrary(h);
|
|
}
|