aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xconfigure.pl11
1 files changed, 11 insertions, 0 deletions
diff --git a/configure.pl b/configure.pl
index 58d0f9f42..a38f3f101 100755
--- a/configure.pl
+++ b/configure.pl
@@ -2159,6 +2159,17 @@ sub guess_cpu
# what kind of CPU we're running on.
my $cpuinfo = '/proc/cpuinfo';
+ if(defined($ENV{'CPUINFO'})) {
+ my $cpuinfo_env = $ENV{'CPUINFO'};
+
+ if(-e $cpuinfo_env and -r $cpuinfo_env) {
+ autoconfig("Will use $cpuinfo_env as /proc/cpuinfo");
+ $cpuinfo = $cpuinfo_env;
+ } else {
+ warn("Could not read from ENV /proc/cpuinfo ($cpuinfo_env)");
+ }
+ }
+
if(-e $cpuinfo and -r $cpuinfo)
{
open CPUINFO, $cpuinfo or die "Could not read $cpuinfo\n";