Import 2.3.7pre8
[davej-history.git] / scripts / Makefile
blob3db649d66acd2dcdffed2d2767fa92a1621095c2
1 HEADER=header.tk
2 TAIL=tail.tk
4 # Previous versions always remade kconfig.tk because they always depended
5 # on soundscript. This runs fairly fast, and I can't find all the
6 # Config.in files to depend on anyways. So I'll force it to remake.
8 kconfig.tk: dummy
10 kconfig.tk: ${TOPDIR}/Makefile ${TOPDIR}/arch/${ARCH}/config.in \
11 tkparse ${HEADER} ${TAIL}
12 @if [ -f /usr/local/bin/wish ]; then \
13 echo '#!'"/usr/local/bin/wish -f" > kconfig.tk; \
14 else \
15 echo '#!'"/usr/bin/wish -f" > kconfig.tk; \
17 cat ${HEADER} >> ./kconfig.tk
18 ./tkparse < ../arch/${ARCH}/config.in >> kconfig.tk
19 echo "set defaults \"arch/${ARCH}/defconfig\"" >> kconfig.tk
20 echo "set ARCH \"${ARCH}\"" >> kconfig.tk
21 cat ${TAIL} >> kconfig.tk
22 chmod 755 kconfig.tk
24 tkparse: tkparse.o tkcond.o tkgen.o
25 ${HOSTCC} -o tkparse tkparse.o tkcond.o tkgen.o
27 tkparse.o: tkparse.c tkparse.h
29 tkcond.o: tkcond.c tkparse.h
31 tkgen.o: tkgen.c tkparse.h
33 tkparse.o tkcond.o tkgen.o:
34 $(HOSTCC) $(HOSTCFLAGS) -c -o $@ $(@:.o=.c)
36 clean:
37 rm -f *~ kconfig.tk *.o tkparse mkdep split-include
39 include $(TOPDIR)/Rules.make