$sample = system("./my_command"); #the system call returns a string like "Intel CPU" if ($sample = "Intel CPU") { print "Intel CPU Found"; } else { exit(0); }