VirtualBox

source: vbox/trunk/src/VBox/ValidationKit/utils/audio/Makefile.kmk@ 96608

最後變更 在這個檔案從96608是 96407,由 vboxsync 提交於 3 年 前

scm copyright and license note update

  • 屬性 svn:eol-style 設為 native
  • 屬性 svn:keywords 設為 Author Date Id Revision
檔案大小: 6.4 KB
 
1# $Id: Makefile.kmk 96407 2022-08-22 17:43:14Z vboxsync $
2## @file
3# VirtualBox Validation Kit - Audio Utilities.
4#
5
6#
7# Copyright (C) 2010-2022 Oracle and/or its affiliates.
8#
9# This file is part of VirtualBox base platform packages, as
10# available from https://www.alldomusa.eu.org.
11#
12# This program is free software; you can redistribute it and/or
13# modify it under the terms of the GNU General Public License
14# as published by the Free Software Foundation, in version 3 of the
15# License.
16#
17# This program is distributed in the hope that it will be useful, but
18# WITHOUT ANY WARRANTY; without even the implied warranty of
19# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20# General Public License for more details.
21#
22# You should have received a copy of the GNU General Public License
23# along with this program; if not, see <https://www.gnu.org/licenses>.
24#
25# The contents of this file may alternatively be used under the terms
26# of the Common Development and Distribution License Version 1.0
27# (CDDL), a copy of it is provided in the "COPYING.CDDL" file included
28# in the VirtualBox distribution, in which case the provisions of the
29# CDDL are applicable instead of those of the GPL.
30#
31# You may elect to license modified versions of this file under the
32# terms and conditions of either the GPL or the CDDL or both.
33#
34# SPDX-License-Identifier: GPL-3.0-only OR CDDL-1.0
35#
36
37SUB_DEPTH = ../../../../..
38include $(KBUILD_PATH)/subheader.kmk
39
40#
41# Make sure the ValKit config file is included when the additions build
42# is including just this makefile.
43#
44ifndef VBOX_VALIDATIONKIT_CONFIG_KMK_INCLUDED
45 include $(PATH_ROOT)/src/VBox/ValidationKit/Config.kmk
46endif
47
48
49#
50# Append what we build here to PROGRAMS (at the top because it's a bit messy).
51#
52ifn1of ($(KBUILD_TARGET), os2 freebsd netbsd openbsd)
53 if defined(VBOX_ONLY_VALIDATIONKIT) || !defined(VBOX_ONLY_BUILD)
54 PROGRAMS += vkat
55 endif
56 ifdef VBOX_WITH_ADDITIONS_SHIPPING_AUDIO_TEST
57 if defined(VBOX_ONLY_ADDITIONS) || !defined(VBOX_ONLY_BUILD)
58 ifndef VBOX_WITH_ADDITIONS_FROM_BUILD_SERVER
59 ifdef VBOX_WITH_ADDITIONS
60 PROGRAMS += vkatadd
61 endif
62 endif
63 endif
64 endif
65endif
66
67
68#
69# Utility to play sine wave to Default Audio Device.
70#
71if 0 # Disabled for now; does not work without WinMM.dll import validator files.
72 PROGRAMS.win += ntPlayToneWaveX
73 ntPlayToneWaveX_TEMPLATE = VBoxValidationKitR3
74 ntPlayToneWaveX_SOURCES = ntPlayToneWaveX.cpp
75 ntPlayToneWaveX_LIBS += \
76 WinMM.Lib
77endif
78
79
80#
81# The Validation Kit Audio Test (VKAT) utility.
82#
83VKAT_PATH_AUDIO = $(PATH_ROOT)/src/VBox/Devices/Audio
84vkat_TEMPLATE = VBoxValidationKitR3
85vkat_VBOX_IMPORT_CHECKER.win.x86 = nt4
86vkat_DEFS = VBOX_AUDIO_VKAT IN_VMM_R3 IN_VMM_STATIC
87vkat_INCS = \
88 $(PATH_ROOT)/src/VBox/Devices/build \
89 $(PATH_ROOT)/src/VBox/Devices \
90 $(PATH_ROOT)/src/VBox/Devices/Audio
91vkat_SOURCES = \
92 vkat.cpp \
93 vkatCommon.cpp \
94 vkatCmdGeneric.cpp \
95 vkatDriverStack.cpp \
96 $(VKAT_PATH_AUDIO)/AudioTest.cpp \
97 $(VKAT_PATH_AUDIO)/DrvAudio.cpp \
98 $(VKAT_PATH_AUDIO)/DrvHostAudioNull.cpp \
99 $(VKAT_PATH_AUDIO)/AudioMixer.cpp \
100 $(VKAT_PATH_AUDIO)/AudioMixBuffer.cpp \
101 $(VKAT_PATH_AUDIO)/AudioHlp.cpp
102
103# Debug stuff.
104ifdef VBOX_WITH_AUDIO_DEBUG
105 vkat_DEFS += VBOX_WITH_AUDIO_DEBUG
106 vkat_SOURCES += \
107 $(VKAT_PATH_AUDIO)/DrvHostAudioDebug.cpp
108endif
109
110# Self-test stuff.
111vkat_DEFS += VBOX_WITH_AUDIO_VALIDATIONKIT
112vkat_SOURCES += \
113 vkatCmdSelfTest.cpp \
114 $(VKAT_PATH_AUDIO)/DrvHostAudioValidationKit.cpp \
115 $(VKAT_PATH_AUDIO)/AudioTestService.cpp \
116 $(VKAT_PATH_AUDIO)/AudioTestServiceClient.cpp \
117 $(VKAT_PATH_AUDIO)/AudioTestServiceProtocol.cpp \
118 $(VKAT_PATH_AUDIO)/AudioTestServiceTcp.cpp
119
120ifdef VBOX_WITH_AUDIO_PULSE
121 vkat_DEFS += VBOX_WITH_AUDIO_PULSE
122 vkat_SOURCES += \
123 $(VKAT_PATH_AUDIO)/DrvHostAudioPulseAudioStubs.cpp \
124 $(VKAT_PATH_AUDIO)/DrvHostAudioPulseAudio.cpp
125endif
126
127ifdef VBOX_WITH_AUDIO_ALSA
128 vkat_DEFS += VBOX_WITH_AUDIO_ALSA
129 vkat_SOURCES += \
130 $(VKAT_PATH_AUDIO)/DrvHostAudioAlsa.cpp \
131 $(VKAT_PATH_AUDIO)/DrvHostAudioAlsaStubs.cpp
132endif
133
134ifdef VBOX_WITH_AUDIO_OSS
135 vkat_DEFS += VBOX_WITH_AUDIO_OSS
136 vkat_SOURCES += \
137 $(VKAT_PATH_AUDIO)/DrvHostAudioOss.cpp
138endif
139
140vkat_SOURCES.win += \
141 $(VKAT_PATH_AUDIO)/DrvHostAudioDSound.cpp \
142 $(VKAT_PATH_AUDIO)/DrvHostAudioWasApi.cpp
143ifdef VBOX_WITH_AUDIO_MMNOTIFICATION_CLIENT
144 vkat_DEFS.win += VBOX_WITH_AUDIO_MMNOTIFICATION_CLIENT
145 vkat_SOURCES.win += \
146 $(VKAT_PATH_AUDIO)/DrvHostAudioDSoundMMNotifClient.cpp
147endif
148
149vkat_SOURCES.darwin = \
150 $(VKAT_PATH_AUDIO)/DrvHostAudioCoreAudio.cpp \
151 $(VKAT_PATH_AUDIO)/DrvHostAudioCoreAudioAuth.mm
152vkat_LDFLAGS.darwin = \
153 -framework CoreAudio \
154 -framework AudioUnit \
155 -framework AudioToolbox \
156 -framework Foundation
157ifn1of ($(VBOX_DEF_MACOSX_VERSION_MIN), 10.4 10.5 10.6)
158 vkat_LDFLAGS.darwin += \
159 -framework AVFoundation
160endif
161
162
163#
164# The additions variant of the audio test utility.
165#
166# We name it VBoxAudioTest though, to not clutter up Guest Additions
167# installations with cryptic binaries not sporting 'VBox' as prefix.
168#
169vkatadd_TEMPLATE = VBoxGuestR3Exe
170vkatadd_EXTENDS = vkat
171vkatadd_EXTENDS_BY = appending
172vkatadd_NAME = VBoxAudioTest
173vkatadd_SDKS = VBOX_ZLIB_STATIC
174vkatadd_LDFLAGS.darwin = -framework IOKit
175vkatadd_LIBS.solaris = m
176
177
178#
179# Copy the valkit vkat to bin so it can be shipped with the host installer too.
180#
181# We use the same name as for the GAs, even if the binaries is the same as the
182# validation kit.
183#
184ifdef VBOX_WITH_HOST_SHIPPING_AUDIO_TEST
185 ifn1of ($(KBUILD_TARGET), os2 freebsd netbsd openbsd)
186 ifndef VBOX_ONLY_ADDITIONS
187 INSTALLS += vkathost
188 vkathost_TEMPLATE = VBOXR3EXE
189 vkathost_SOURCES = $(vkat_1_TARGET)=>VBoxAudioTest$(HOSTSUFF_EXE)
190 vkathost_MODE = a+rx,u+w
191 endif
192 endif
193endif
194
195if defined(VBOX_WITH_TESTCASES) && !defined(VBOX_ONLY_ADDITIONS) && !defined(VBOX_ONLY_SDK) \
196 && 0 ## @todo r=bird: Disabled because nobody really wants or needs to run this during build other than Andy.
197 ## And more importantly, it breaks the build (os2, bsd*).
198
199 PROGRAMS += tstVkatHostSelftest
200 tstVkatHostSelftest_EXTENDS = vkat
201 tstVkatHostSelftest_EXTENDS_BY = appending
202 tstVkatHostSelftest_INST = $(INST_TESTCASE)
203 tstVkatHostSelftest_DEFS.debug = VBOX_WITH_EF_WRAPS
204
205 TESTING += $(tstVkatHostSelftest_0_OUTDIR)/tstVkatHostSelftest.run
206 $$(tstVkatHostSelftest_0_OUTDIR)/tstVkatHostSelftest.run: $$(tstVkatHostSelftest_1_TARGET)
207 export VKAT_RELEASE_LOG=-all; $(tstVkatHostSelftest_1_TARGET) selftest
208 $(QUIET)$(APPEND) -t "$@" "done"
209
210endif
211
212include $(FILE_KBUILD_SUB_FOOTER)
213
注意: 瀏覽 TracBrowser 來幫助您使用儲存庫瀏覽器

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