Hello all,

This is in reference to debian bug #393672, viewable at
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=393672

The gist of it is that apparently some mailers are brain dead.  No real
surprise there, I suppose, but the attached patch makes it easier to
build clamav in automated build environments where these brain dead
mailers might be installed.  My one fear is that some older shells on
systems supported by clamav might not support the POSIX character class
[:digit:] - it is POSIX, but that doesn't actuall gurantee portability
between operating systems, as I've found out the hard way :)

Thanks for considering it,

Index: debian/unstable/configure.in
===================================================================
--- debian/unstable/configure.in        (revision 185)
+++ debian/unstable/configure.in        (working copy)
@@ -178,9 +178,30 @@
     sendmailver_b=`echo $sendmailver | awk -F. '{printf $2}'`
     sendmailver_c=`echo $sendmailver | awk -F. '{printf $3}'`

-    AC_DEFINE_UNQUOTED(SENDMAIL_VERSION_A, $sendmailver_a, [major version of 
Sendmail])
-    AC_DEFINE_UNQUOTED(SENDMAIL_VERSION_B, $sendmailver_b, [minor version of 
Sendmail])
-    AC_DEFINE_UNQUOTED(SENDMAIL_VERSION_C, $sendmailver_c, [subversion of 
Sendmail])
+    case sendmailver_a in
+      [:digit:]+) ;;
+      *) sendmailver_a= ;;
+    esac
+
+    case sendmailver_b in
+      [:digit:]+) ;;
+      *) sendmailver_b= ;;
+    esac
+
+    case sendmailver_c in
+      [:digit:]+) ;;
+      *) sendmailver_c= ;;
+    esac
+
+    if test -n "$sendmailver_a"; then
+      AC_DEFINE_UNQUOTED(SENDMAIL_VERSION_A, $sendmailver_a, [major version of 
Sendmail])
+    fi
+    if test -n "$sendmailver_b"; then
+      AC_DEFINE_UNQUOTED(SENDMAIL_VERSION_B, $sendmailver_b, [minor version of 
Sendmail])
+    fi
+    if test -n "$sendmailver_c"; then
+      AC_DEFINE_UNQUOTED(SENDMAIL_VERSION_C, $sendmailver_c, [subversion of 
Sendmail])
+    fi
   fi
 fi


-- 
 --------------------------------------------------------------------------
|  Stephen Gran                  | BOFH excuse #426:  internet is needed   |
|  [EMAIL PROTECTED]             | to catch the etherbunny                 |
|  http://www.lobefin.net/~steve |                                         |
 --------------------------------------------------------------------------

Attachment: signature.asc
Description: Digital signature

_______________________________________________
http://lurker.clamav.net/list/clamav-devel.html

Reply via email to