Arquivos
hhvm/hphp/runtime/ext_hhvm/gen_infotabs_header.php
T
Jordan Delong 363d1bb20f Code move src/ -> hphp/
This change is mostly for FB internal organizational reasons.
Building is not effected beyond the fact that the target now
lands in hphp/hhvm/hhvm rather than src/hhvm/hhvm.
2013-02-11 02:10:41 -08:00

24 linhas
542 B
PHP
Arquivo Executável

#!/bin/env php
<?php
# Ignore the --foo arguments passed by fbconfig.
while ($argv[1][0] == '-') {
array_shift($argv);
}
$output_file = $argv[1];
$outfile_tempnam = tempnam('/tmp', 'ext_hhvm.h.tmp');
$outfile = fopen($outfile_tempnam, 'w');
foreach(array_slice($argv, 2) as $cpp) {
$header = substr($cpp, 0, -4) . ".h";
fwrite($outfile, "#include \"$header\"\n");
}
fclose($outfile);
$outfile = null;
if (getenv("INSTALL_DIR")) {
$output_file = getenv("INSTALL_DIR") . '/' . $output_file;
}
`mv -f $outfile_tempnam $output_file`;