[FFmpeg-devel] [PATCH] configure's to_lower and to_upper fix on *bsd

Pierre d'Herbemont pdherbemont
Fri Feb 8 16:02:26 CET 2008


Hi,

here, on Mac OS X, (should be a BSD issue):
$ echo "hello z" | tr '[a-z]' '[A-Z]'
HELLO ]

This cause configure to generate a bad crafted config.h. Here is a fix  
for that, as suggested by the BSD tr's man page.

Pierre.

Index: configure
===================================================================
--- configure	(revision 11879)
+++ configure	(working copy)
@@ -215,13 +215,12 @@
      exit 1
  }

-# "tr '[a-z]' '[A-Z]'" is a workaround for Solaris tr not grokking  
"tr a-z A-Z"
  toupper(){
-    echo "$@" | tr '[a-z]' '[A-Z]'
+    echo "$@" | tr '[:lower:]' '[:upper:]'
  }

  tolower(){
-    echo "$@" | tr '[A-Z]' '[a-z]'
+    echo "$@" | tr '[:upper:]' '[:lower:]'
  }

  set_all(){





More information about the ffmpeg-devel mailing list