1 | # $Id: Makefile.kmk 86850 2020-11-10 18:31:41Z vboxsync $
|
---|
2 | ## @file
|
---|
3 | # Sub-Makefile for various generic build tools (there is currently only one of them).
|
---|
4 | #
|
---|
5 |
|
---|
6 | #
|
---|
7 | # Copyright (C) 2006-2020 Oracle Corporation
|
---|
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 |
|
---|
18 | SUB_DEPTH = ../..
|
---|
19 | include $(KBUILD_PATH)/subheader.kmk
|
---|
20 |
|
---|
21 | ifneq ($(KBUILD_TARGET).$(KBUILD_TARGET_ARCH),solaris.sparc64)
|
---|
22 | BLDPROGS += bin2c biossums filesplitter VBoxCmp
|
---|
23 | endif
|
---|
24 |
|
---|
25 | bin2c_TEMPLATE = VBoxBldProg
|
---|
26 | bin2c_SOURCES = bin2c.c
|
---|
27 |
|
---|
28 | biossums_TEMPLATE = VBoxBldProg
|
---|
29 | biossums_SOURCES = biossums.c
|
---|
30 |
|
---|
31 | filesplitter_TEMPLATE = VBoxBldProg
|
---|
32 | filesplitter_SOURCES = filesplitter.cpp
|
---|
33 |
|
---|
34 | VBoxCmp_TEMPLATE = VBoxBldProg
|
---|
35 | VBoxCmp_SOURCES = VBoxCmp.cpp
|
---|
36 |
|
---|
37 | ifndef VBOX_ONLY_BUILD
|
---|
38 | PROGRAMS += scm
|
---|
39 | scm_TEMPLATE = VBoxR3Tool
|
---|
40 | scm_SOURCES = \
|
---|
41 | scm.cpp \
|
---|
42 | scmdiff.cpp \
|
---|
43 | scmrw.cpp \
|
---|
44 | scmparser.cpp \
|
---|
45 | scmstream.cpp \
|
---|
46 | scmsubversion.cpp
|
---|
47 | ifdef VBOX_PATH_SUBVERSION_INCS
|
---|
48 | scm_INCS += $(VBOX_PATH_SUBVERSION_INCS) $(VBOX_PATH_APACHE_RUNTIME_INCS)
|
---|
49 | scm_DEFS += SCM_WITH_SVN_HEADERS
|
---|
50 | endif
|
---|
51 |
|
---|
52 | BLDPROGS += VBoxCPP
|
---|
53 | VBoxCPP_TEMPLATE = VBoxAdvBldProg
|
---|
54 | VBoxCPP_SOURCES = \
|
---|
55 | VBoxCPP.cpp \
|
---|
56 | scmstream.cpp
|
---|
57 | endif
|
---|
58 |
|
---|
59 | if !defined(VBOX_ONLY_BUILD) || defined(VBOX_ONLY_EXTPACKS)
|
---|
60 | BLDPROGS += VBoxTpG
|
---|
61 | VBoxTpG_TEMPLATE = VBoxAdvBldProg
|
---|
62 | VBoxTpG_SOURCES = \
|
---|
63 | VBoxTpG.cpp \
|
---|
64 | scmstream.cpp
|
---|
65 | endif
|
---|
66 |
|
---|
67 | ifeq ($(KBUILD_TARGET),win)
|
---|
68 | BLDPROGS += VBoxPeSetVersion
|
---|
69 | endif
|
---|
70 | VBoxPeSetVersion_TEMPLATE = VBoxBldProg
|
---|
71 | VBoxPeSetVersion_SOURCES = VBoxPeSetVersion.cpp
|
---|
72 |
|
---|
73 | BLDPROGS.win += VBoxCheckImports
|
---|
74 | VBoxCheckImports_TEMPLATE = VBoxBldProg
|
---|
75 | VBoxCheckImports_SOURCES = VBoxCheckImports.cpp
|
---|
76 |
|
---|
77 | ifneq ($(KBUILD_TARGET).$(KBUILD_TARGET_ARCH),solaris.sparc64)
|
---|
78 | BLDPROGS += VBoxDef2LazyLoad
|
---|
79 | endif
|
---|
80 | VBoxDef2LazyLoad_TEMPLATE = VBoxBldProg
|
---|
81 | VBoxDef2LazyLoad_SOURCES = VBoxDef2LazyLoad.cpp
|
---|
82 |
|
---|
83 | ifeq ($(KBUILD_TARGET),win)
|
---|
84 | BLDPROGS += VBoxEditCoffLib
|
---|
85 | endif
|
---|
86 | VBoxEditCoffLib_TEMPLATE = VBoxBldProg
|
---|
87 | VBoxEditCoffLib_SOURCES = VBoxEditCoffLib.cpp
|
---|
88 |
|
---|
89 | # temp hack.
|
---|
90 | VBoxCompilerPlugInsGcc.o VBoxCompilerPlugInsCommon.o VBoxCompilerPlugIns.o gccplugin: gccplugin$(SUFF_DLL)
|
---|
91 | gccplugin$(SUFF_DLL): VBoxCompilerPlugInsGcc.cpp VBoxCompilerPlugInsCommon.cpp VBoxCompilerPlugIns.h
|
---|
92 | $(TOOL_GXX3_CXX) -shared -fPIC -fno-rtti -g \
|
---|
93 | -DIN_RING3 \
|
---|
94 | $(if-expr "$(KBUILD_TYPE)" != "release",-DDEBUG,) \
|
---|
95 | -I$(shell $(TOOL_GXX3_CXX) -print-file-name=plugin)/include \
|
---|
96 | -I$(PATH_ROOT)/include \
|
---|
97 | $(if-expr "$(KBUILD_HOST)" == "solaris", -I/usr/include/gmp -I$(PATH_ROOT)/src/bldprogs/solgcc/,) \
|
---|
98 | -o $@ \
|
---|
99 | VBoxCompilerPlugInsGcc.cpp \
|
---|
100 | VBoxCompilerPlugInsCommon.cpp
|
---|
101 |
|
---|
102 |
|
---|
103 |
|
---|
104 | include $(FILE_KBUILD_SUB_FOOTER)
|
---|
105 |
|
---|