Do not call perl from a bash script. Whatever required this before as since been fixed.

This commit is contained in:
Steve Checkoway
2007-02-04 01:35:37 +00:00
parent 4d27ec506f
commit ae8f79a2ed
2 changed files with 17 additions and 19 deletions
+17
View File
@@ -0,0 +1,17 @@
#!/usr/bin/perl -w
$ver = 0;
if( open FH, '<ver.cpp' )
{
$_ = <FH>;
/version_num = (\d+);/ and $ver = $1+1;
close FH;
}
chop( $date = `date` );
open FH, '>ver.cpp' or die $!;
# Cannot use const here since gcc will strip it out...
print FH <<"EOF";
unsigned long version_num = $ver;
const char *version_time = "$date";
EOF
close FH;