The check for big or little endianness relies on grep reporting
match/non-match on the generated binary. If the user specified
--binary-files=without-match in their GREP_OPTIONS, this will fail.
Let's just explicitly specify --binary-files=binary, which will
override any user settings and do what we want.
Reported-by: Eugene (jno) Dvurechenski <j...@linux.vnet.ibm.com>
Signed-off-by: Cornelia Huck <cornelia.h...@de.ibm.com>
---
 configure | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/configure b/configure
index 0e516f9..0fad0e1 100755
--- a/configure
+++ b/configure
@@ -1666,9 +1666,9 @@ int main(int argc, char *argv[]) {
 EOF
 
 if compile_object ; then
-    if grep -q BiGeNdIaN $TMPO ; then
+    if grep -q --binary-files=binary BiGeNdIaN $TMPO ; then
         bigendian="yes"
-    elif grep -q LiTtLeEnDiAn $TMPO ; then
+    elif grep -q --binary-files=binary LiTtLeEnDiAn $TMPO ; then
         bigendian="no"
     else
         echo big/little test failed
-- 
1.8.5.5


Reply via email to