summaryrefslogtreecommitdiff
path: root/payloads/external/SeaBIOS/Makefile.inc
blob: faca57e56543ebf76ebc8150e6cfdf56f540ad15 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31


TAG-$(CONFIG_SEABIOS_MASTER)=master
TAG-$(CONFIG_SEABIOS_STABLE)=rel-0.6.1.3

all: seabios

seabios: patch
	cd seabios; $(MAKE) CC="$(CC)" LD="$(LD)"

patch: checkout
	test -r seabios/.patched || \
	perl -pi -e "s,#define CONFIG_COREBOOT 0,#define CONFIG_COREBOOT 1,;" \
		 -e "s,#define CONFIG_DEBUG_SERIAL 0,#define CONFIG_DEBUG_SERIAL 1,;" \
		 -e "s,#define CONFIG_VGAHOOKS 0,#define CONFIG_VGAHOOKS 1,;" \
		 seabios/src/config.h
	touch seabios/.patched

checkout:
	echo "Checking out SeaBIOS $(TAG-y)"
	test -d seabios && ( cd seabios; git pull ) || \
	git clone git://git.linuxtogo.org/home/kevin/seabios.git seabios
	cd seabios; git checkout $(TAG-y)

clean:
	test -d seabios && (cd seabios; $(MAKE) CC="$(CC)" LD="$(LD)" clean) || exit 0

distclean:
	rm -rf seabios

.PHONY: seabios