# File: tyan/s2892/s2892/Makefile is autogenerated
include fallback/Makefile.settings

ifeq "$(CONFIG_CBFS)" "1"

all:  ./coreboot.romfs
else
all:  ./coreboot.rom
endif


cbfstool:
	mkdir -p tools/lzma
	$(MAKE) -C $(TOP)/util/cbfstool obj=$(shell pwd)

include Makefile.settings

fallback/coreboot.rom:
	if (cd fallback; \
		$(MAKE) coreboot.rom)\
	then true; else exit 1; fi;

normal/coreboot.rom:
	if (cd normal; \
		$(MAKE) coreboot.rom)\
	then true; else exit 1; fi;

clean:  fallback-clean normal-clean base-clean

fallback-clean:
	(cd fallback; $(MAKE) clean)

normal-clean:
	(cd normal; $(MAKE) clean)

base-clean:
	rm -f romcc*

./coreboot.rom: normal/coreboot.rom  fallback/coreboot.rom 
	 cat  normal/coreboot.rom  fallback/coreboot.rom > ./coreboot.rom


	 cat  normal/coreboot.strip  fallback/coreboot.strip > ./coreboot.rom.bootblock

./coreboot.romfs: ./coreboot.rom cbfstool
	rm -f coreboot.cbfs
	./cbfstool ./coreboot.romfs create 1011712 262144 ./coreboot.rom.bootblock
	if [ -f normal/cbfs-support ]; then ./cbfstool ./coreboot.romfs add-payload ../payload.elf normal/payload `cat normal/cbfs-support`; fi
	if [ -f fallback/cbfs-support ]; then ./cbfstool ./coreboot.romfs add-payload ../payload.elf fallback/payload `cat fallback/cbfs-support`; fi
	 ./cbfstool ./coreboot.romfs print
.PHONY: all clean cbfstool fallback-clean normal-clean fallback/coreboot.rom normal/coreboot.rom



Makefile: /home/myles/buildrom-devel/work/coreboot/svn/targets/tyan/s2892/s2892/config.py /home/myles/buildrom-devel/work/coreboot/svn/targets/tyan/s2892/Config.lb
	(cd /home/myles/buildrom-devel/work/coreboot/svn/targets ; export PYTHONPATH=/home/myles/buildrom-devel/work/coreboot/svn/util/newconfig ; python tyan/s2892/s2892/config.py tyan/s2892//Config.lb /home/myles/buildrom-devel/work/coreboot/svn)

