Move SeaBIOS output out of coreboot source tree
[coreboot.git] / payloads / external / SeaBIOS / Makefile.inc
1
2
3 TAG-$(CONFIG_SEABIOS_MASTER)=origin/master
4 TAG-$(CONFIG_SEABIOS_STABLE)=e66fb31eac3e6be6aaab548c229af9bb1ba55c33
5
6 unexport KCONFIG_AUTOCONFIG
7
8 all: build
9
10 $(OUT)/seabios:
11         echo "    Cloning SeaBIOS from Git"
12         git clone git://git.seabios.org/seabios.git $(OUT)/seabios
13
14 fetch: $(OUT)/seabios
15         cd $(OUT)/seabios; git show $(TAG-y) >/dev/null 2>&1 ;  if [ $$? -ne 0 ]; \
16         then echo "    Fetching new commits from the SeaBIOS git repo"; git fetch; fi
17
18 checkout: fetch
19         echo "    Checking out SeaBIOS revision $(TAG-y)"
20         cd $(OUT)/seabios; git checkout master; git branch -D coreboot 2>/dev/null; git checkout -b coreboot $(TAG-y)
21
22 config: checkout
23         echo "    CONFIG     SeaBIOS $(TAG-y)"
24         $(MAKE) -C $(OUT)/seabios defconfig OUT=$(OUT)/seabios/out/
25         echo "CONFIG_COREBOOT=y" >> $(OUT)/seabios/.config
26         echo "CONFIG_DEBUG_SERIAL=y" >> $(OUT)/seabios/.config
27         echo "CONFIG_DEBUG_SERIAL_PORT=0x3f8" >> $(OUT)/seabios/.config
28         echo "CONFIG_COREBOOT_FLASH=y" >> $(OUT)/seabios/.config
29         echo "CONFIG_LZMA=y" >> $(OUT)/seabios/.config
30         echo "CONFIG_FLASH_FLOPPY=y" >> $(OUT)/seabios/.config
31         echo "CONFIG_VGAHOOKS=y" >> $(OUT)/seabios/.config
32         # This shows how to force a previously set .config option *off*
33         #echo "# CONFIG_SMBIOS is not set" >> $(OUT)/seabios/.config
34
35 build: config
36         echo "    MAKE       SeaBIOS $(TAG-y)"
37         $(MAKE) -C $(OUT)/seabios OUT=$(OUT)/seabios/out/
38
39 clean:
40         test -d $(OUT)/seabios && $(MAKE) -C $(OUT)/seabios clean OUT=$(OUT)/seabios/out/ || exit 0
41
42 distclean:
43         rm -rf $(OUT)/seabios
44
45 .PHONY: checkout config build clean distclean clone fetch