Index: config/auto/pcre.pm
===================================================================
--- config/auto/pcre.pm	(revision 48967)
+++ config/auto/pcre.pm	(working copy)
@@ -35,12 +35,11 @@
 
     my $without = $conf->options->get( qw| without-pcre | );
 
-    if ($without) {
-        $conf->data->set( HAS_PCRE => 0 );
-        $self->set_result('no');
-        return 1;
-    }
+    $self->set_result('no');
+    $conf->data->set( HAS_PCRE => 0 );
 
+    return 1 if ($without);
+
     my $osname = $conf->data->get('osname');
 
     my $extra_libs = $self->_select_lib( {
@@ -53,12 +52,12 @@
 
     $conf->cc_gen('config/auto/pcre/pcre_c.in');
     eval { $conf->cc_build( q{}, $extra_libs ) };
-    my $has_pcre = 0;
     if ( !$@ ) {
         my $test = $conf->cc_run();
-        $has_pcre = $self->_evaluate_cc_run($conf, $test);
+        if ( my $has_pcre = $self->_evaluate_cc_run($conf, $test) ) {
+	    $conf->data->set( HAS_PCRE => $has_pcre);
+        }
     }
-    $conf->data->set( HAS_PCRE => $has_pcre);
 
     return 1;
 }
