Fix issue with --library hanging
authorfuzzyray <fuzzyray@gentoo.org>
Tue, 17 Jul 2007 17:34:04 +0000 (17:34 -0000)
committerfuzzyray <fuzzyray@gentoo.org>
Tue, 17 Jul 2007 17:34:04 +0000 (17:34 -0000)
svn path=/; revision=419

trunk/src/revdep-rebuild/revdep-rebuild-rewrite

index a76dce3bd328c2ac573b247d5727c41dcf22c4bf..d6a30798f8c6b4f8288e02c1877e526829518220 100755 (executable)
@@ -496,14 +496,14 @@ main_checks() {
                                                # FIXME: I hate duplicating code
                                                # Only rebuild for direct dependencies
                                                MISSING_LIBS=$(
-                                                       expr="/$SONAME_SEARCH/s/^\([^[:space:]]*\).*$/\1/p"
+                                                       expr="/$SONAME_SEARCH/s/^[[:space:]]*\([^[:space:]]*\).*$/\1/p"
                                                        sort -u <<< "$ldd_output" | sed -n "$expr"
                                                )
                                                REQUIRED_LIBS=$(
                                                        expr='s/^[[:space:]]*NEEDED[[:space:]]*\([^[:space:]]*\).*/\1/p';
                                                        objdump -x "$FILE" | sed "$expr" | sort -u
                                                )
-                                               MISSING_LIBS=$(grep -F "$REQUIRED_LIBS")
+                                               MISSING_LIBS=$(grep -F "$REQUIRED_LIBS" <<< "$MISSING_LIBS")
                                                if [[ $MISSING_LIBS ]]; then
                                                        echo "obj $FILE" >> "$LIST.3_rebuild"
                                                        if [[ $SEARCH_BROKEN ]]; then