public static function findLibPrefix() { $files = func_get_args(); $prefixes = self::getLookupPrefixes(); foreach ($prefixes as $prefix) { foreach ($files as $file) { $p = $prefix . DIRECTORY_SEPARATOR . $file; if (file_exists($p)) { return $prefix; } } } return; }
public function testPrefix() { $this->assertNotNull(Utils::findLibPrefix('icu/pkgdata.inc', 'icu/Makefile.inc')); $this->assertNotNull(Utils::findIncludePrefix('openssl/opensslv.h')); }