]> git.ipfire.org Git - thirdparty/chrony.git/commitdiff
Allow overriding system detection in configure
authorMiroslav Lichvar <mlichvar@redhat.com>
Tue, 10 Nov 2009 15:25:59 +0000 (16:25 +0100)
committerMiroslav Lichvar <mlichvar@redhat.com>
Thu, 12 Nov 2009 14:07:35 +0000 (15:07 +0100)
configure

index a8dd51a8d71e58487c329b50882209f6e6831b46..ba937d2627f4734c6f6db25211041017598313d1 100755 (executable)
--- a/configure
+++ b/configure
@@ -194,6 +194,11 @@ Fine tuning of the installation directories:
   --infodir=DIR          info documentation [PREFIX/info]
   --mandir=DIR           man documentation [PREFIX/man]
 
+Overriding system detection when cross-compiling:
+  --host-system=OS       Specify system name (uname -s)
+  --host-release=REL     Specify system release (uname -r)
+  --host-machine=CPU     Specify machine (uname -m)
+
 Some influential environment variables:
   CC          C compiler command
   CFLAGS      C compiler flags
@@ -219,8 +224,6 @@ OPERATINGSYSTEM=`uname -s`
 VERSION=`uname -r`
 MACHINE=`uname -m`
 
-SYSTEM=${OPERATINGSYSTEM}-${MACHINE}
-
 EXTRA_LIBS=""
 EXTRA_CLI_LIBS=""
 EXTRA_OBJECTS=""
@@ -280,6 +283,15 @@ do
     --enable-linuxcaps)
       feat_linuxcaps=1
     ;;
+    --host-system=* )
+      OPERATINGSYSTEM=`echo $option | sed -e 's/^.*=//;'`
+    ;;
+    --host-release=* )
+      VERSION=`echo $option | sed -e 's/^.*=//;'`
+    ;;
+    --host-machine=* )
+      MACHINE=`echo $option | sed -e 's/^.*=//;'`
+    ;;
     --help | -h )
       usage
       exit 0
@@ -289,6 +301,8 @@ do
     esac
 done
 
+SYSTEM=${OPERATINGSYSTEM}-${MACHINE}
+
 case $SYSTEM in
     SunOS-sun4* )
     case $VERSION in