#!/usr/bin/perl
# -------------------------------------------------------------------------------------
#  Project	 : hcl
#  File          : hclcpuinfo
#  Author        : Keerthan Muthurasa <kmuthurasa at mandriva dot com>
#  Created On    : Mon Aug 27 11:15:03 2007
#  Purpose       : Collect data about hardware using /proc/cpuinfo 
# -------------------------------------------------------------------------------------
use strict;
my $procCount=0;
my $path="/tmp/report";
open(IFIL,"/proc/cpuinfo");
open(OFIL,">>$path/processor.xml");
while(<IFIL>)
{
	if(/^processor.*/)
	{
		$procCount++;
	}

}
print OFIL "<processor_count>$procCount</processor_count>\n";
print OFIL "</cpu>\n";
close(OFIL);
close(IFIL);
