make_single_applets.sh: show errors and warnings
While at it, fix one warning in modprobe-small.c Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
parent
590402bb55
commit
e7b54d0fcc
@ -28,6 +28,8 @@ for app in $apps; do
|
|||||||
done
|
done
|
||||||
#echo "$allno" >.config_allno
|
#echo "$allno" >.config_allno
|
||||||
|
|
||||||
|
trap 'test -f .config.SV && mv .config.SV .config && touch .config' EXIT
|
||||||
|
|
||||||
# Turn on each applet individually and build single-applet executable
|
# Turn on each applet individually and build single-applet executable
|
||||||
fail=0
|
fail=0
|
||||||
for app in $apps; do
|
for app in $apps; do
|
||||||
@ -54,16 +56,20 @@ for app in $apps; do
|
|||||||
mv .config busybox_config_${app}
|
mv .config busybox_config_${app}
|
||||||
elif ! make $makeopts >>busybox_make_${app}.log 2>&1; then
|
elif ! make $makeopts >>busybox_make_${app}.log 2>&1; then
|
||||||
: $((fail++))
|
: $((fail++))
|
||||||
|
grep -i -e error: -e warning: busybox_make_${app}.log
|
||||||
echo "Build error for ${app}"
|
echo "Build error for ${app}"
|
||||||
mv .config busybox_config_${app}
|
mv .config busybox_config_${app}
|
||||||
elif ! grep -q '^#define NUM_APPLETS 1$' include/NUM_APPLETS.h; then
|
elif ! grep -q '^#define NUM_APPLETS 1$' include/NUM_APPLETS.h; then
|
||||||
|
grep -i -e error: -e warning: busybox_make_${app}.log
|
||||||
mv busybox busybox_${app}
|
mv busybox busybox_${app}
|
||||||
: $((fail++))
|
: $((fail++))
|
||||||
echo "NUM_APPLETS != 1 for ${app}: `cat include/NUM_APPLETS.h`"
|
echo "NUM_APPLETS != 1 for ${app}: `cat include/NUM_APPLETS.h`"
|
||||||
mv .config busybox_config_${app}
|
mv .config busybox_config_${app}
|
||||||
else
|
else
|
||||||
|
grep -i -e error: -e warning: busybox_make_${app}.log \
|
||||||
|
|| rm busybox_make_${app}.log
|
||||||
mv busybox busybox_${app}
|
mv busybox busybox_${app}
|
||||||
rm busybox_make_${app}.log
|
#mv .config busybox_config_${app}
|
||||||
fi
|
fi
|
||||||
mv .config.SV .config
|
mv .config.SV .config
|
||||||
#exit
|
#exit
|
||||||
|
@ -59,7 +59,12 @@
|
|||||||
#define DEPFILE_BB CONFIG_DEFAULT_DEPMOD_FILE".bb"
|
#define DEPFILE_BB CONFIG_DEFAULT_DEPMOD_FILE".bb"
|
||||||
|
|
||||||
#define MOD_APPLET_CNT (ENABLE_MODPROBE + ENABLE_DEPMOD + ENABLE_INSMOD + ENABLE_LSMOD + ENABLE_RMMOD)
|
#define MOD_APPLET_CNT (ENABLE_MODPROBE + ENABLE_DEPMOD + ENABLE_INSMOD + ENABLE_LSMOD + ENABLE_RMMOD)
|
||||||
#define ONLY_APPLET (MOD_APPLET_CNT <= 1)
|
|
||||||
|
/* Do not bother if MODPROBE_SMALL=y but no applets selected. */
|
||||||
|
/* The rest of the file is in this if block. */
|
||||||
|
#if MOD_APPLET_CNT > 0
|
||||||
|
|
||||||
|
#define ONLY_APPLET (MOD_APPLET_CNT == 1)
|
||||||
#define is_modprobe (ENABLE_MODPROBE && (ONLY_APPLET || applet_name[0] == 'm'))
|
#define is_modprobe (ENABLE_MODPROBE && (ONLY_APPLET || applet_name[0] == 'm'))
|
||||||
#define is_depmod (ENABLE_DEPMOD && (ONLY_APPLET || applet_name[0] == 'd'))
|
#define is_depmod (ENABLE_DEPMOD && (ONLY_APPLET || applet_name[0] == 'd'))
|
||||||
#define is_insmod (ENABLE_INSMOD && (ONLY_APPLET || applet_name[0] == 'i'))
|
#define is_insmod (ENABLE_INSMOD && (ONLY_APPLET || applet_name[0] == 'i'))
|
||||||
@ -1063,3 +1068,5 @@ int modprobe_main(int argc UNUSED_PARAM, char **argv)
|
|||||||
return exitcode;
|
return exitcode;
|
||||||
#endif /* MODPROBE || INSMOD || RMMOD */
|
#endif /* MODPROBE || INSMOD || RMMOD */
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#endif /* MOD_APPLET_CNT > 0 */
|
||||||
|
Loading…
Reference in New Issue
Block a user