Hello, attached please find a patch, which changes the check for EBCDIC. 1) I added a comment which explains why \n isn't portable enough. 2) space is space, no need to use \040 3) Change the logic, so that it potentially works even for other charsets.
Stepan Kasal
2005-08-16 Stepan Kasal <[EMAIL PROTECTED]> * config/general.m4sh (SP2NL, NL2SP): Simplify. Index: config/general.m4sh =================================================================== RCS file: /cvsroot/libtool/libtool/config/general.m4sh,v retrieving revision 1.18 diff -u -r1.18 general.m4sh --- config/general.m4sh 5 Jun 2005 17:34:17 -0000 1.18 +++ config/general.m4sh 16 Aug 2005 13:26:48 -0000 @@ -106,14 +106,15 @@ s/\([[^\\]]\(''\\\\''\\\\''\)*''\\\\''\)\$/\1\\$/g' # test EBCDIC or ASCII -case `$ECHO A|tr A '\301'` in - A) # EBCDIC based system - SP2NL="tr '\100' '\n'" - NL2SP="tr '\r\n' '\100\100'" +case `$ECHO X|tr X '\101'` in + A) # ASCII based system + # '\n' is not interpreted correctly by Solaris 8 /usr/ucb/tr + SP2NL="tr ' ' '\012'" + NL2SP="tr '\015\012' ' '" ;; - *) # Assume ASCII based system - SP2NL="tr '\040' '\012'" - NL2SP="tr '\015\012' '\040\040'" + *) # EBCDIC based system + SP2NL="tr ' ' '\n'" + NL2SP="tr '\r\n' ' '" ;; esac