diff options
author | Rob Landley <rob@landley.net> | 2012-12-08 21:10:10 -0600 |
---|---|---|
committer | Rob Landley <rob@landley.net> | 2012-12-08 21:10:10 -0600 |
commit | aa777fe07df104e8d33b958fb4e19c81245ac9a3 (patch) | |
tree | 13477b526de55640db4a6ec90f6c52584e1f4c2f /scripts | |
parent | 37de8ed2aac771c118702b2315ccac7e02ecb729 (diff) | |
download | toybox-aa777fe07df104e8d33b958fb4e19c81245ac9a3.tar.gz |
Add README file to each toys/ directory, teach build infrastructure to get fancy name from that. This means adding new directories shouldn't require touching build scripts.
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/genconfig.sh | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/scripts/genconfig.sh b/scripts/genconfig.sh index accf0dba..4337666c 100755 --- a/scripts/genconfig.sh +++ b/scripts/genconfig.sh @@ -4,7 +4,6 @@ # before menuconfig. (It's called again from scripts/make.sh just to be sure.) mkdir -p generated -OUTFILE=generated/Config.in source configure @@ -28,15 +27,15 @@ genconfig() { # I could query the directory here, but I want to control the order # and capitalization in the menu - for j in Posix LSB Other + for j in toys/*/README do - echo "menu \"$j commands\"" + echo "menu \"$(head -n 1 $j)\"" echo - DIR=$(echo $j | tr A-Z a-z) + DIR="$(dirname "$j")" # extract config stanzas from each source file, in alphabetical order - for i in $(ls -1 toys/$DIR/*.c) + for i in $(ls -1 $DIR/*.c) do # Grab the config block for Config.in echo "# $i" |