1
0
mirror of git://projects.qi-hardware.com/eda-tools.git synced 2024-11-25 23:11:33 +02:00

Make boom-config complain about usage errors.

- boom/Makefile, boom/boom-config.in: add a warning to boom-config that the
  file is machine-generated
- boom/boom-config.in (usage): complain about unrecognized keywords
This commit is contained in:
Werner Almesberger 2010-10-17 20:15:48 -03:00
parent 41ae009c6a
commit 9e9eb89f3b
2 changed files with 14 additions and 1 deletions

View File

@ -14,7 +14,8 @@ DB = $(EQU) $(INV) $(DSC) $(CHR)
all: boom-config
boom-config: boom-config.in Makefile
sed 's/##DIST##/$(DIST)/;s/##MANU##/$(MANU)/' boom-config.in \
sed -e 's/##WARN##/*** MACHINE-GENERATED. DO NOT EDIT ! ***/' \
-e 's/##DIST##/$(DIST)/;s/##MANU##/$(MANU)/' boom-config.in \
>$@ || { rm -f $@; exit 1; }
chmod 755 boom-config

View File

@ -1,8 +1,18 @@
#!/bin/sh
# ##WARN##
DIST="##DIST##"
MANU="##MANU##"
usage()
{
echo "usage: $0 equ|inv|dsc|chr ..." 1>&2
exit 1
}
base=`which "$0"`
base=`dirname "$base"`
[ "$base" = "${base#/}" ] && base=`pwd`/$base
@ -18,6 +28,8 @@ while [ "$1" ]; do
for n in $DIST; do echo "$base/dist/$n/db/all.dsc"; done;;
chr)
for n in $MANU; do echo "$base/manu/$n/$n.chr"; done;;
*)
usage;;
esac
shift
done