OpenSSH-2.1: FROM in 'w' empty?

Pekka Savola pekkas at netcore.fi
Wed May 24 01:15:19 EST 2000


Hello all,

I had more time to dig into this problem.  Configure script would print
stuff like:
checking for ut_host field in utmp.h... ossh_cv_utmp_h_has_ut_host

instead of:
checking for ut_host field in utmp.h... yes

This is caused by discontinuation of an undocumented feature of
/bin/sh.  If you have bash-2.x as your /bin/sh, the configure script goes
wrong.

I patched configure and aclocal.m4.  The method used works for both bash1
and bash2, so the changes should be backward compatible.  I tested this
syntax on a couple of Redhat boxes and on Irix.

Regards,
  Pekka

--- configure	Sat May 20 08:48:05 2000
+++ configure.fixed	Tue May 23 17:59:14 2000
@@ -2957,7 +2957,7 @@
  	
 fi
 
-	ossh_result=`eval "echo "$"$ossh_varname"`
+	eval ossh_result=\$${ossh_varname}
 	if test -n "`echo $ossh_varname`"; then
 		echo "$ac_t""$ossh_result" 1>&6
 		if test "x$ossh_result" = "xyes"; then
@@ -2997,7 +2997,7 @@
  	
 fi
 
-	ossh_result=`eval "echo "$"$ossh_varname"`
+	eval ossh_result=\$${ossh_varname}
 	if test -n "`echo $ossh_varname`"; then
 		echo "$ac_t""$ossh_result" 1>&6
 		if test "x$ossh_result" = "xyes"; then
@@ -3037,7 +3037,7 @@
  	
 fi
 
-	ossh_result=`eval "echo "$"$ossh_varname"`
+	eval ossh_result=\$${ossh_varname}
 	if test -n "`echo $ossh_varname`"; then
 		echo "$ac_t""$ossh_result" 1>&6
 		if test "x$ossh_result" = "xyes"; then
@@ -3077,7 +3077,7 @@
  	
 fi
 
-	ossh_result=`eval "echo "$"$ossh_varname"`
+	eval ossh_result=\$${ossh_varname}
 	if test -n "`echo $ossh_varname`"; then
 		echo "$ac_t""$ossh_result" 1>&6
 		if test "x$ossh_result" = "xyes"; then
@@ -3117,7 +3117,7 @@
  	
 fi
 
-	ossh_result=`eval "echo "$"$ossh_varname"`
+	eval ossh_result=\$${ossh_varname}
 	if test -n "`echo $ossh_varname`"; then
 		echo "$ac_t""$ossh_result" 1>&6
 		if test "x$ossh_result" = "xyes"; then
@@ -3157,7 +3157,7 @@
  	
 fi
 
-	ossh_result=`eval "echo "$"$ossh_varname"`
+	eval ossh_result=\$${ossh_varname}
 	if test -n "`echo $ossh_varname`"; then
 		echo "$ac_t""$ossh_result" 1>&6
 		if test "x$ossh_result" = "xyes"; then
@@ -3197,7 +3197,7 @@
  	
 fi
 
-	ossh_result=`eval "echo "$"$ossh_varname"`
+	eval ossh_result=\$${ossh_varname}
 	if test -n "`echo $ossh_varname`"; then
 		echo "$ac_t""$ossh_result" 1>&6
 		if test "x$ossh_result" = "xyes"; then
@@ -3237,7 +3237,7 @@
  	
 fi
 
-	ossh_result=`eval "echo "$"$ossh_varname"`
+	eval ossh_result=\$${ossh_varname}
 	if test -n "`echo $ossh_varname`"; then
 		echo "$ac_t""$ossh_result" 1>&6
 		if test "x$ossh_result" = "xyes"; then
@@ -3277,7 +3277,7 @@
  	
 fi
 
-	ossh_result=`eval "echo "$"$ossh_varname"`
+	eval ossh_result=\$${ossh_varname}
 	if test -n "`echo $ossh_varname`"; then
 		echo "$ac_t""$ossh_result" 1>&6
 		if test "x$ossh_result" = "xyes"; then
@@ -3317,7 +3317,7 @@
  	
 fi
 
-	ossh_result=`eval "echo "$"$ossh_varname"`
+	eval ossh_result=\$${ossh_varname}
 	if test -n "`echo $ossh_varname`"; then
 		echo "$ac_t""$ossh_result" 1>&6
 		if test "x$ossh_result" = "xyes"; then
@@ -3357,7 +3357,7 @@
  	
 fi
 
-	ossh_result=`eval "echo "$"$ossh_varname"`
+	eval ossh_result=\$${ossh_varname}
 	if test -n "`echo $ossh_varname`"; then
 		echo "$ac_t""$ossh_result" 1>&6
 		if test "x$ossh_result" = "xyes"; then
@@ -3397,7 +3397,7 @@
  	
 fi
 
-	ossh_result=`eval "echo "$"$ossh_varname"`
+	eval ossh_result=\$${ossh_varname}
 	if test -n "`echo $ossh_varname`"; then
 		echo "$ac_t""$ossh_result" 1>&6
 		if test "x$ossh_result" = "xyes"; then
--- aclocal.m4	Mon May  8 13:49:37 2000
+++ aclocal.m4.fixed	Tue May 23 17:58:52 2000
@@ -22,7 +22,7 @@
 			eval "$ossh_varname=no" dnl
 		]) dnl
 	])
-	ossh_result=`eval "echo "$"$ossh_varname"`
+	eval ossh_result=\$${ossh_varname}
 	if test -n "`echo $ossh_varname`"; then
 		AC_MSG_RESULT($ossh_result)
 		if test "x$ossh_result" = "xyes"; then
----------


-- 
Pekka Savola                    "Tell me of difficulties surmounted, 
Pekka.Savola at netcore.fi          not those you stumble over and fall"






More information about the openssh-unix-dev mailing list