script to generate /dev part of proto file.

This commit is contained in:
Ben Gras
2006-04-03 15:01:43 +00:00
parent ee2c14934a
commit dcb0fee484
3 changed files with 21 additions and 61 deletions

View File

@@ -3,10 +3,12 @@
PROGRAMS=at_wini bios_wini cdprobe dev2name floppy loadramdisk newroot \
pci sh service sysenv
MAKEDEV=/usr/bin/MAKEDEV
all: image.c image.s
clean:
rm -f $(PROGRAMS) bintoc image image.c
rm -rf $(PROGRAMS) bintoc image image.c t proto.gen
image.c: bintoc image
./bintoc -o $@ image
@@ -19,8 +21,8 @@ image.s: image.c
bintoc: bintoc.c
$(CC) -o $@ bintoc.c
image: proto mtab rc $(PROGRAMS)
mkfs -B1024 image proto || { rm -f image; false; }
image: proto.gen mtab rc $(PROGRAMS)
mkfs -B 2048 image proto.gen 2>/dev/null || { rm -f image; false; }
at_wini: ../../at_wini/at_wini
install -s ../../$@/$@ $@
@@ -91,6 +93,9 @@ service: ../../../servers/rs/service
depend:
/usr/bin/mkdep "$(CC) -E $(CPPFLAGS)" *.c > .depend
proto.gen: $(MAKEDEV) proto.sh proto
sh -e proto.sh <proto >proto.gen
# Include generated dependencies.
include .depend