Allow specifying HHVM as a dependency
parent
cd209e3180
commit
4c8e8ca702
|
@ -144,5 +144,19 @@ class PlatformRepository extends ArrayRepository
|
|||
$lib->setDescription('The '.$name.' PHP library');
|
||||
parent::addPackage($lib);
|
||||
}
|
||||
|
||||
if (defined('HHVM_VERSION')) {
|
||||
try {
|
||||
$prettyVersion = HHVM_VERSION;
|
||||
$version = $versionParser->normalize($prettyVersion);
|
||||
} catch (\UnexpectedValueException $e) {
|
||||
$prettyVersion = preg_replace('#^([^~+-]+).*$#', '$1', HHVM_VERSION);
|
||||
$version = $versionParser->normalize($prettyVersion);
|
||||
}
|
||||
|
||||
$hhvm = new CompletePackage('hhvm', $version, $prettyVersion);
|
||||
$hhvm->setDescription('The HHVM Runtime (64bit)');
|
||||
parent::addPackage($hhvm);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue