1 | # $Id: Makefile.kmk 51835 2014-07-03 08:51:17Z vboxsync $
|
---|
2 | ## @file
|
---|
3 | # Sub-Makefile for the stub installer.
|
---|
4 | #
|
---|
5 |
|
---|
6 | #
|
---|
7 | # Copyright (C) 2009-2012 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 | # This has to be 32-bit, so don't include it in the 64-bit build.
|
---|
22 | if "$(KBUILD_TARGET_ARCH)" == "x86"
|
---|
23 |
|
---|
24 | TEMPLATE_VBOXSTUB = Drop the signing, we will sign it later.
|
---|
25 | TEMPLATE_VBOXSTUB_EXTENDS = VBOXR3STATIC
|
---|
26 | TEMPLATE_VBOXSTUB_POST_CMDS = $(NO_SUCH_VARIABLE)
|
---|
27 |
|
---|
28 | PROGRAMS += VBoxStub
|
---|
29 | VBoxStub_TEMPLATE= VBOXSTUB
|
---|
30 | VBoxStub_DEFS = _WIN32_WINNT=0x0501 IN_RT_R3
|
---|
31 |
|
---|
32 | VBoxStub_SOURCES = \
|
---|
33 | VBoxStub.cpp \
|
---|
34 | VBoxStub.rc
|
---|
35 |
|
---|
36 | VBoxStub_SDKS += \
|
---|
37 | VBOX_NTDLL
|
---|
38 | VBoxStub_LIBS = \
|
---|
39 | $(VBOX_LIB_RUNTIME_STATIC) \
|
---|
40 | $(PATH_SDK_$(VBOX_WINPSDK)_LIB)/Msi.lib
|
---|
41 |
|
---|
42 | VBoxStub_LDFLAGS = /IntegrityCheck:NO
|
---|
43 |
|
---|
44 | VBoxStub.cpp_DEFS += VBOX_SVN_REV=$(VBOX_SVN_REV)
|
---|
45 | VBoxStub.cpp_DEPS = $(VBOX_SVN_REV_KMK)
|
---|
46 |
|
---|
47 | # If signing mode is enabled, then add the possibility to
|
---|
48 | # install public certificate automatically in /silent mode
|
---|
49 | ifdef VBOX_SIGNING_MODE
|
---|
50 |
|
---|
51 | VBoxStub_SOURCES += VBoxStubCertUtil.cpp
|
---|
52 | VBoxStub_LIBS += crypt32.lib
|
---|
53 | VBoxStub.cpp_DEPS += $(VBoxStub_0_OUTDIR)/VBoxStubPublicCert.h
|
---|
54 | VBoxStub.cpp_INCS += $(VBoxStub_0_OUTDIR)
|
---|
55 | VBoxStub.cpp_DEFS += VBOX_WITH_CODE_SIGNING
|
---|
56 |
|
---|
57 | $$(VBoxStub_0_OUTDIR)/VBoxStubPublicCert.h: $(VBOX_BIN2C) $(PATH_ROOT)/src/VBox/Additions/WINNT/tools/oracle-vbox.cer | $$(dir $$@)
|
---|
58 | $(VBOX_BIN2C) _VBoxStubPublicCert $(PATH_ROOT)/src/VBox/Additions/WINNT/tools/oracle-vbox.cer $@
|
---|
59 |
|
---|
60 | endif
|
---|
61 |
|
---|
62 | # The icon location is configurable.
|
---|
63 | VBoxStub.rc_INCS += $(VBoxStub_0_OUTDIR)
|
---|
64 | VBoxStub.rc_DEPS += \
|
---|
65 | $(VBoxStub_0_OUTDIR)/VBoxStub-icon.rc \
|
---|
66 | $(VBoxStub_0_OUTDIR)/VBoxStub-manifest.rc
|
---|
67 | VBoxStub.rc_CLEAN = \
|
---|
68 | $(VBoxStub_0_OUTDIR)/VBoxStub-icon.rc \
|
---|
69 | $(VBoxStub_0_OUTDIR)/VBoxStub-manifest.rc
|
---|
70 |
|
---|
71 | # Icon include file.
|
---|
72 | $$(VBoxStub_0_OUTDIR)/VBoxStub-icon.rc: $(VBOX_WINDOWS_ICON_FILE) $(MAKEFILE_CURRENT) | $$(dir $$@)
|
---|
73 | $(APPEND) -t $@ 'IDI_VIRTUALBOX ICON DISCARDABLE "$(subst /,\\,$(VBOX_WINDOWS_ICON_FILE))"'
|
---|
74 |
|
---|
75 | # Manifest.
|
---|
76 | VBOX_STUB_MANIFEST_FILE := $(PATH_SUB_CURRENT)/VBoxStub.manifest
|
---|
77 | $$(VBoxStub_0_OUTDIR)/VBoxStub-manifest.rc: $(VBOX_STUB_MANIFEST_FILE) $(MAKEFILE_CURRENT) | $$(dir $$@)
|
---|
78 | $(APPEND) -t $@ 'APP_MANIFEST RT_MANIFEST "$(subst /,\\,$(VBOX_STUB_MANIFEST_FILE))"'
|
---|
79 |
|
---|
80 |
|
---|
81 | endif # x86 only
|
---|
82 |
|
---|
83 | include $(FILE_KBUILD_SUB_FOOTER)
|
---|