diff options
author | Denis Vlasenko <vda.linux@googlemail.com> | 2007-07-21 01:28:41 +0400 |
---|---|---|
committer | Denis Vlasenko <vda.linux@googlemail.com> | 2007-07-21 01:28:41 +0400 |
commit | 21d1014b5b91d1a1319273945291b7a9f4717827 (patch) | |
tree | b84eadba35d31f923ef62579652e4e5d76678c38 /scripts | |
parent | 2f6ae43b9c74d393a139007377895e8c50b8af9a (diff) |
chpasswd: new applet by Alexander Shishkin <virtuoso@slind.org>
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/defconfig | 1 | ||||
-rwxr-xr-x | scripts/trylink | 15 |
2 files changed, 12 insertions, 4 deletions
diff --git a/scripts/defconfig b/scripts/defconfig index 088ff791a..4709b2234 100644 --- a/scripts/defconfig +++ b/scripts/defconfig @@ -376,6 +376,7 @@ CONFIG_FEATURE_SECURETTY=y CONFIG_PASSWD=y CONFIG_FEATURE_PASSWD_WEAK_CHECK=y CONFIG_CRYPTPW=y +CONFIG_CHPASSWD=y CONFIG_SU=y CONFIG_FEATURE_SU_SYSLOG=y CONFIG_FEATURE_SU_CHECKS_SHELLS=y diff --git a/scripts/trylink b/scripts/trylink index ddd7fb179..cbd702338 100755 --- a/scripts/trylink +++ b/scripts/trylink @@ -22,9 +22,11 @@ try "-Wl,--start-group $l_list -Wl,--end-group" "$@" \ cat busybox_ld.err exit 1 } +mv busybox_unstripped busybox_unstripped.tmp # Now try to remove each lib and build without. # Stop when no lib can be removed. +ever_discarded=false while test "$BBOX_LIB_LIST"; do $debug && echo "Trying libraries: $BBOX_LIB_LIST" all_needed=true @@ -36,6 +38,7 @@ while test "$BBOX_LIB_LIST"; do echo "Library $one is not needed" BBOX_LIB_LIST="$without_one" all_needed=false + ever_discarded=true else echo "Library $one is needed" fi @@ -48,7 +51,11 @@ while test "$BBOX_LIB_LIST"; do #echo "$BBOX_LIB_LIST" | grep -q ' ' || break done -# Ok, make the binary -echo "Final link with: $BBOX_LIB_LIST" -l_list=`echo "$BBOX_LIB_LIST" | sed -e 's/ / -l/g' -e 's/^/-l/'` -try "-Wl,--start-group $l_list -Wl,--end-group" "$@" +mv busybox_unstripped.tmp busybox_unstripped +$ever_discarded && { + # Ok, make the binary + echo "Final link with: $BBOX_LIB_LIST" + l_list=`echo "$BBOX_LIB_LIST" | sed -e 's/ / -l/g' -e 's/^/-l/'` + try "-Wl,--start-group $l_list -Wl,--end-group" "$@" +} +exit 0 # Ensure "success" exit code |