Browse Source

fix bug, f.e. glib package ignored by mistake

Waldemar Brodkorb 13 years ago
parent
commit
d4173bfaec
2 changed files with 13 additions and 7 deletions
  1. 7 1
      mk/build.mk
  2. 6 6
      tools/adk/depmaker.c

+ 7 - 1
mk/build.mk

@@ -532,7 +532,13 @@ package/Config.in.auto menu .menu: $(wildcard ${TOPDIR}/package/*/Makefile) ${TO
 	@$(TOPDIR)/bin/tools/pkgmaker
 	@:>.menu
 
-dep:
+$(TOPDIR)/bin/tools:
+	@mkdir -p $(TOPDIR)/bin/tools
+
+${TOPDIR}/bin/tools/depmaker: $(TOPDIR)/bin/tools
+	$(HOSTCC) -o $(TOPDIR)/bin/tools/depmaker $(TOPDIR)/tools/adk/depmaker.c
+
+dep: $(TOPDIR)/bin/tools/depmaker
 	@echo "Generating dependencies ..."
 	$(TOPDIR)/bin/tools/depmaker > ${TOPDIR}/package/Depends.mk
 

+ 6 - 6
tools/adk/depmaker.c

@@ -155,12 +155,12 @@ int main() {
 			}
 			
 			/* exclude manual maintained packages from package/Makefile */
-			if (!(strncmp(pkgdirp->d_name, "eglibc", strlen(pkgdirp->d_name)) == 0) &&
-				!(strncmp(pkgdirp->d_name, "libc", strlen(pkgdirp->d_name)) == 0) &&
-				!(strncmp(pkgdirp->d_name, "libpthread", strlen(pkgdirp->d_name)) == 0) &&
-				!(strncmp(pkgdirp->d_name, "uclibc++", strlen(pkgdirp->d_name)) == 0) &&
-				!(strncmp(pkgdirp->d_name, "uclibc", strlen(pkgdirp->d_name)) == 0) &&
-				!(strncmp(pkgdirp->d_name, "glibc", strlen(pkgdirp->d_name)) == 0)) {
+			if (!(strncmp(pkgdirp->d_name, "eglibc", 6) == 0) &&
+				!(strncmp(pkgdirp->d_name, "libc", 4) == 0) &&
+				!(strncmp(pkgdirp->d_name, "libpthread", 10) == 0) &&
+				!(strncmp(pkgdirp->d_name, "uclibc++", 8) == 0) &&
+				!(strncmp(pkgdirp->d_name, "uclibc", 6) == 0) &&
+				!(strncmp(pkgdirp->d_name, "glibc", 5) == 0)) {
 				/* print result to stdout */
 				printf("package-$(ADK_COMPILE_%s) += %s\n", pkgvar, pkgdirp->d_name); 
 			}