소스 검색

Optimize the dependency generating slightly

Bryan Drewery 11 년 전
부모
커밋
1d35e30fd4
2개의 변경된 파일4개의 추가작업 그리고 32개의 파일을 삭제
  1. 2 5
      build/autotools/includes/depend.m4
  2. 2 27
      configure

+ 2 - 5
build/autotools/includes/depend.m4

@@ -25,11 +25,8 @@ AC_DEFUN([DO_DEPS],
 files="src/Makefile.in src/compat/Makefile.in src/crypto/Makefile.in src/mod/channels.mod/Makefile src/mod/compress.mod/Makefile src/mod/console.mod/Makefile src/mod/ctcp.mod/Makefile src/mod/irc.mod/Makefile src/mod/server.mod/Makefile src/mod/share.mod/Makefile src/mod/transfer.mod/Makefile src/mod/update.mod/Makefile"
 for mf in $files; do
   # Strip MF so we end up with the name of the file.
-#  echo "MF: $mf"
-  mf=`echo "$mf" | sed -e 's/:.*$//'`
-  dirpart=`AS_DIRNAME("$mf")`
-#  echo "dirpart: $dirpart mf: $mf"
-#  rm -rf "$dirpart/.deps/"
+  mf=${mf%%:*}
+  dirpart=${mf%/*}
   rm -f "$dirpart/.deps/includes"
   test -d "$dirpart/.deps" || mkdir "$dirpart/.deps"
   for file in `sed -n -e '

+ 2 - 27
configure

@@ -8719,33 +8719,8 @@ esac
 files="src/Makefile.in src/compat/Makefile.in src/crypto/Makefile.in src/mod/channels.mod/Makefile src/mod/compress.mod/Makefile src/mod/console.mod/Makefile src/mod/ctcp.mod/Makefile src/mod/irc.mod/Makefile src/mod/server.mod/Makefile src/mod/share.mod/Makefile src/mod/transfer.mod/Makefile src/mod/update.mod/Makefile"
 for mf in $files; do
   # Strip MF so we end up with the name of the file.
-#  echo "MF: $mf"
-  mf=`echo "$mf" | sed -e 's/:.*$//'`
-  dirpart=`$as_dirname -- "$mf" ||
-$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
-	 X"$mf" : 'X\(//\)[^/]' \| \
-	 X"$mf" : 'X\(//\)$' \| \
-	 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$mf" |
-    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\/\)[^/].*/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\/\)$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\).*/{
-	    s//\1/
-	    q
-	  }
-	  s/.*/./; q'`
-#  echo "dirpart: $dirpart mf: $mf"
-#  rm -rf "$dirpart/.deps/"
+  mf=${mf%%:*}
+  dirpart=${mf%/*}
   rm -f "$dirpart/.deps/includes"
   test -d "$dirpart/.deps" || mkdir "$dirpart/.deps"
   for file in `sed -n -e '