--- bin/ant.orig	Tue Jul  9 09:01:58 2002
+++ bin/ant	Tue Jul  9 09:11:06 2002
@@ -69,6 +69,9 @@
   cd $saveddir
 fi
 
+# set ANT_LIB location
+ANT_LIB=${ANT_HOME}/lib
+
 # For Cygwin, ensure paths are in UNIX format before anything is touched
 if $cygwin ; then
   [ -n "$ANT_HOME" ] &&
@@ -113,23 +116,26 @@
       LOCALCLASSPATH="$JAVALIBDIR/$i.jar":"$LOCALCLASSPATH"
     fi
   done
-else
-  # add in the dependency .jar files in non-RPM mode (the default)
-  DIRLIBS="${ANT_HOME}"/lib
-  for i in "${DIRLIBS}"/*.jar
-  do
-    # if the directory is empty, then it will return the input string
-    # this is stupid, so case for it
-    if [ "$i" != "${DIRLIBS}/*.jar" ] ; then
-      if [ -z "$LOCALCLASSPATH" ] ; then
-        LOCALCLASSPATH=$i
-      else
-        LOCALCLASSPATH="$i":"$LOCALCLASSPATH"
-      fi
-    fi
-  done
+
+# in rpm mode ant/lib is in /usr/share/java/ant
+ANT_LIB=${JAVALIBDIR}/ant
+
 fi
 
+# add in the dependency .jar files in non-RPM mode (the default)
+for i in "${ANT_LIB}"/*.jar
+do
+  # if the directory is empty, then it will return the input string
+  # this is stupid, so case for it
+  if [ "$i" != "${ANT_LIB}/*.jar" ] ; then
+    if [ -z "$LOCALCLASSPATH" ] ; then
+      LOCALCLASSPATH=$i
+    else
+      LOCALCLASSPATH="$i":"$LOCALCLASSPATH"
+    fi
+  fi
+done
+
 if [ -n "$JAVA_HOME" ] ; then
   if [ -f "$JAVA_HOME/lib/tools.jar" ] ; then
     LOCALCLASSPATH="$LOCALCLASSPATH:$JAVA_HOME/lib/tools.jar"
