VirtualBox

source: vbox/trunk/src/VBox/Devices/Graphics/BIOS/Makefile.kmk@ 7759

Last change on this file since 7759 was 7759, checked in by vboxsync, 17 years ago

The BIOS logo stuff moved to VGA device. Added 24bpp bitmaps support.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 3.8 KB
Line 
1# $Id: Makefile.kmk 7759 2008-04-05 11:36:02Z vboxsync $
2## @file
3# VGA BIOS Sub-Makefile
4#
5
6#
7# Copyright (C) 2006-2007 innotek GmbH
8#
9# This file is part of VirtualBox Open Source Edition (OSE), as
10# available from http://www.virtualbox.org. This file is free software;
11# you can redistribute it and/or modify it under the terms of the GNU
12# General Public License (GPL) as published by the Free Software
13# Foundation, in version 2 as it comes in the "COPYING" file of the
14# VirtualBox OSE distribution. VirtualBox OSE is distributed in the
15# hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
16#
17
18DEPTH ?= ../../../../..
19SUB_DEPTH = ../..
20include $(PATH_KBUILD)/subheader.kmk
21
22VBOX_PATH_DEVICES_SRC = $(PATH_SUB_ROOT)
23
24#
25# Build program for calculating the VGA BIOS checksums.
26#
27BLDPROGS += vgabiossums vbetables-gen
28vgabiossums_TEMPLATE = VBOXBLDPROG
29vgabiossums_SOURCES = biossums.c
30vbetables-gen_TEMPLATE = VBOXBLDPROG
31vbetables-gen_SOURCES = vbetables-gen.c
32
33#
34# The library containing the VGA BIOS image.
35#
36LIBRARIES += VgaBiosBin
37VgaBiosBin_TEMPLATE = VBOXR3
38VgaBiosBin_DEFS = IN_VBOXDD2
39VgaBiosBin_INCS = $(VBOX_PATH_DEVICES_SRC)
40VgaBiosBin_SOURCES = $(PATH_TARGET)/VgaBiosBin.c
41VgaBiosBin_CLEAN = \
42 $(PATH_TARGET)/_vgabios_.c \
43 $(PATH_TARGET)/vgabios0.s \
44 $(PATH_TARGET)/vgabios1.s \
45 $(PATH_TARGET)/vgabios.tmp \
46 $(PATH_TARGET)/vgabios.lst \
47 $(PATH_TARGET)/vgabios.bin \
48 $(PATH_TARGET)/VgaBiosBin.c \
49 $(PATH_TARGET)/VgaDefBiosLogo.c \
50 \
51 $(PATH_TARGET)/_vgabios-cirrus_.c \
52 $(PATH_TARGET)/vgabios-cirrus0.s \
53 $(PATH_TARGET)/vgabios-cirrus1.s \
54 $(PATH_TARGET)/vgabios-cirrus.tmp \
55 $(PATH_TARGET)/vgabios-cirrus.lst \
56 $(PATH_TARGET)/vgabios-cirrus.bin
57
58#
59# Rule for making the bios.
60#
61$(PATH_TARGET)/VgaBiosBin.c: $(PATH_TARGET)/vgabios.bin $(VBOX_BIN2C)
62 $(call MSG_TOOL,bin2c,VgaBiosBin,$<,$@)
63 $(QUIET)$(VBOX_BIN2C) -min 32 -max 64 -mask 0x0fff -ascii -export VgaBiosBinary $< $@
64
65#
66# vgabios
67#
68
69# 1. create vbetables.h
70$(PATH_TARGET)/vbetables.h: $(MAKEFILE_CURRENT) $(TARGET_vbetables-gen)
71 $(QUIET)$(REDIRECT) -wo $@ -- $(TARGET_vbetables-gen)
72
73# 2. precompile
74$(PATH_TARGET)/_vgabios_.c: $(addprefix $(PATH_SUB_CURRENT)/,vgabios.c vgabios.h vbe.h vgatables.h vgafonts.h vbe.c clext.c) $(PATH_TARGET)/vbetables.h
75 $(call MSG_TOOL,cpp,VgaBiosBin,$<,$@)
76 $(QUIET)$(TOOL_$(VBOX_GCC_TOOL)_CC) -E -P -DVBOX -DVBOX_VERSION_STRING=\"$(VBOX_VERSION_STRING)\" -DVBE -DVGABIOS_DATE="''" $(addprefix -D,$(DEFS) $(DEFS.$(BUILD_TYPE))) -o $@ $<
77
78# 3. compile - tempfile clashes, so make sure it's built in solitude.
79.NOTPARALLEL: $(PATH_TARGET)/vgabios0.s
80$(PATH_TARGET)/vgabios0.s: $(PATH_TARGET)/_vgabios_.c
81 $(call MSG_COMPILE,VgaBiosBin,$<,$@,C)
82 $(QUIET)$(VBOX_BCC) -o $@ -C-c -D__i86__ -0 -S $^
83
84# 4. preprocess intermediate assembly.
85$(PATH_TARGET)/vgabios1.s: $(PATH_TARGET)/vgabios0.s
86 $(call MSG_TOOL,Adjusting BCC Assembly,VgaBiosBin,$<,$@)
87 $(QUIET)$(SED) -e 's/^\.text//' -e 's/^\.data//' --output $@ $^
88
89# 5. assemble
90$(PATH_TARGET)/vgabios.tmp $(PATH_TARGET)/vgabios.lst: $(PATH_TARGET)/vgabios1.s
91 $(call MSG_COMPILE,VgaBiosBin,$<,$@,AS)
92 $(QUIET)$(REDIRECT) -ri $^ -- $(VBOX_AS86) -b $(PATH_TARGET)/vgabios.tmp -u- -w- -g -0 -j -O -l $(PATH_TARGET)/vgabios.lst
93
94# 6. checksums
95$(PATH_TARGET)/vgabios.bin: $(PATH_TARGET)/vgabios.tmp $$(TARGET_vgabiossums)
96 $(call MSG_TOOL,vgabiossums,VgaBiosBin,$<,$@)
97 $(QUIET)$(CP) -f $(PATH_TARGET)/vgabios.tmp $@
98 $(QUIET)$(TARGET_vgabiossums) $@
99
100#
101# The VGA BIOS Logo.
102#
103LIBRARIES += VgaDefBiosLogo
104VgaDefBiosLogo_TEMPLATE = VBOXR3
105VgaDefBiosLogo_INCS = $(VBOX_PATH_DEVICES_SRC)
106VgaDefBiosLogo_SOURCES = $(PATH_TARGET)/VgaDefBiosLogo.c
107
108#
109# Rule for making the bios logo.
110#
111$(PATH_TARGET)/VgaDefBiosLogo.c: $(PATH_SUB_CURRENT)/innotek_logo.bmp $(VBOX_BIN2C)
112 $(call MSG_TOOL,bin2c,VgaBiosBin,$<,$@)
113 $(QUIET)$(VBOX_BIN2C) -max 64 VgaDefBiosLogo $< $@
114
115
116include $(PATH_KBUILD)/subfooter.kmk
117
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette