readline versions like "4.735beta5-pl2" should now be correctly recognized
authorChristian Bauer <Christian.Bauer@uni-mainz.de>
Tue, 20 Nov 2001 20:42:05 +0000 (20:42 +0000)
committerChristian Bauer <Christian.Bauer@uni-mainz.de>
Tue, 20 Nov 2001 20:42:05 +0000 (20:42 +0000)
acinclude.m4

index 50f7f27..e963eb9 100644 (file)
@@ -26,9 +26,9 @@ main()
     return 0;
 }], ginac_cv_rlversion=`cat 'conftest.out'`, ginac_cv_rlversion='unknown', ginac_cv_rlversion='4.2')])
 if test "x${ginac_cv_rlversion}" != "xunknown"; then
-  RL_VERSION_MAJOR=`echo ${ginac_cv_rlversion} | sed -e 's/\([[0-9]]\)\.\([[0-9]]\)/\1/'`
+  RL_VERSION_MAJOR=`echo ${ginac_cv_rlversion} | sed -e 's/\([[0-9]]*\)\.\([[0-9]]*\).*/\1/'`
   AC_DEFINE_UNQUOTED(GINAC_RL_VERSION_MAJOR, $RL_VERSION_MAJOR, [Major version of installed readline library.])
-  RL_VERSION_MINOR=`echo ${ginac_cv_rlversion} | sed -e 's/\([[0-9]]\)\.\([[0-9]]\)/\2/'`
+  RL_VERSION_MINOR=`echo ${ginac_cv_rlversion} | sed -e 's/\([[0-9]]*\)\.\([[0-9]]*\).*/\2/'`
   AC_DEFINE_UNQUOTED(GINAC_RL_VERSION_MINOR, $RL_VERSION_MINOR, [Minor version of installed readline library.])
 else
   GINAC_WARNING([I could not run a test of libreadline (needed for building ginsh).])