[PATCH 2 of 2] auto/feature: disable feature autotest when cross-compiling

Samuel Martin s.martin49 at gmail.com
Sun May 4 06:08:30 UTC 2014


# HG changeset patch
# User Samuel Martin <s.martin49 at gmail.com>
# Date 1399156849 -7200
#      Sun May 04 00:40:49 2014 +0200
# Node ID 03617a96c528d1f02abf829df964fcb29b06c942
# Parent  f0f3f5208b12c6afbbdfb55b32c968ebd7206ad5
auto/feature: disable feature autotest when cross-compiling

This patch introduce a new NGX_CROSSBUILD configure variable that records
whether --crossbuild=... option was passed on the command line.

Then this variable is used to disable the feature runtest because they
cannot usually be executed when cross-compiling.

diff -r f0f3f5208b12 -r 03617a96c528 auto/configure
--- a/auto/configure	Thu Apr 24 23:27:32 2014 +0200
+++ b/auto/configure	Sun May 04 00:40:49 2014 +0200
@@ -44,6 +44,7 @@
 else
     echo "building for $NGX_PLATFORM"
     NGX_SYSTEM=$NGX_PLATFORM
+    NGX_CROSSBUILD=crossbuild
 fi
 
 . auto/cc/conf
diff -r f0f3f5208b12 -r 03617a96c528 auto/feature
--- a/auto/feature	Thu Apr 24 23:27:32 2014 +0200
+++ b/auto/feature	Sun May 04 00:40:49 2014 +0200
@@ -49,7 +49,7 @@
 
 if [ -x $NGX_AUTOTEST ]; then
 
-    case "$ngx_feature_run" in
+    case "$NGX_CROSSBUILD$ngx_feature_run" in
 
         yes)
             # /bin/sh is used to intercept "Killed" or "Abort trap" messages
diff -r f0f3f5208b12 -r 03617a96c528 auto/options
--- a/auto/options	Thu Apr 24 23:27:32 2014 +0200
+++ b/auto/options	Sun May 04 00:40:49 2014 +0200
@@ -32,6 +32,7 @@
 NGX_TEST_BUILD_RTSIG=NO
 NGX_TEST_BUILD_SOLARIS_SENDFILEV=NO
 
+NGX_CROSSBUILD=
 NGX_PLATFORM=
 NGX_WINE=
 



More information about the nginx-devel mailing list