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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
|
Index: src/build/common.gypi
===================================================================
--- src/build/common.gypi (revision 239)
+++ src/build/common.gypi (revision 240)
@@ -25,6 +25,13 @@
'direct_show_base_classes':
'C:/Program Files/Microsoft SDKs/Windows/v7.1/Samples/multimedia/directshow/baseclasses/',
}],
+ ['build_with_chromium==1', {
+ # Exclude pulse audio on Chromium since its prerequisites don't
+ # include pulse audio.
+ 'include_pulse_audio%': 0,
+ }, {
+ 'include_pulse_audio%': 1,
+ }],
], # conditions
},
'target_defaults': {
Index: src/modules/audio_device/main/source/audio_device.gyp
===================================================================
--- src/modules/audio_device/main/source/audio_device.gyp (revision 239)
+++ src/modules/audio_device/main/source/audio_device.gyp (revision 240)
@@ -52,18 +52,12 @@
'Linux/alsasymboltable.h',
'Linux/audio_device_linux_alsa.cc',
'Linux/audio_device_linux_alsa.h',
- 'Linux/audio_device_linux_pulse.cc',
- 'Linux/audio_device_linux_pulse.h',
'Linux/audio_device_utility_linux.cc',
'Linux/audio_device_utility_linux.h',
'Linux/audio_mixer_manager_linux_alsa.cc',
'Linux/audio_mixer_manager_linux_alsa.h',
- 'Linux/audio_mixer_manager_linux_pulse.cc',
- 'Linux/audio_mixer_manager_linux_pulse.h',
'Linux/latebindingsymboltable.cc',
'Linux/latebindingsymboltable.h',
- 'Linux/pulseaudiosymboltable.cc',
- 'Linux/pulseaudiosymboltable.h',
'Mac/audio_device_mac.cc',
'Mac/audio_device_mac.h',
'Mac/audio_device_utility_mac.cc',
@@ -89,16 +83,10 @@
'Linux/alsasymboltable.h',
'Linux/audio_device_linux_alsa.cc',
'Linux/audio_device_linux_alsa.h',
- 'Linux/audio_device_linux_pulse.cc',
- 'Linux/audio_device_linux_pulse.h',
'Linux/audio_mixer_manager_linux_alsa.cc',
'Linux/audio_mixer_manager_linux_alsa.h',
- 'Linux/audio_mixer_manager_linux_pulse.cc',
- 'Linux/audio_mixer_manager_linux_pulse.h',
'Linux/latebindingsymboltable.cc',
'Linux/latebindingsymboltable.h',
- 'Linux/pulseaudiosymboltable.cc',
- 'Linux/pulseaudiosymboltable.h',
# Don't remove these, needed for dummy device
# 'Linux/audio_device_utility_linux.cc',
# 'Linux/audio_device_utility_linux.h',
@@ -131,7 +119,6 @@
}],
['OS=="linux"', {
'defines': [
- 'LINUX_PULSE',
'LINUX_ALSA',
],
'include_dirs': [
@@ -141,9 +128,28 @@
'libraries': [
'-ldl',
'-lasound',
- '-lpulse',
],
},
+ 'conditions': [
+ ['include_pulse_audio==1', {
+ 'defines': [
+ 'LINUX_PULSE',
+ ],
+ 'sources': [
+ 'Linux/audio_device_linux_pulse.cc',
+ 'Linux/audio_device_linux_pulse.h',
+ 'Linux/audio_mixer_manager_linux_pulse.cc',
+ 'Linux/audio_mixer_manager_linux_pulse.h',
+ 'Linux/pulseaudiosymboltable.cc',
+ 'Linux/pulseaudiosymboltable.h',
+ ],
+ 'link_settings': {
+ 'libraries': [
+ '-lpulse',
+ ],
+ },
+ }],
+ ],
}],
['OS=="mac"', {
'include_dirs': [
Index: src/build/common.gypi
===================================================================
--- src/build/common.gypi (revision 241)
+++ src/build/common.gypi (revision 242)
@@ -10,9 +10,19 @@
{
'variables': {
- # TODO(ajm): use webrtc_standalone to match NaCl?
- 'build_with_chromium%': 1, # 1 to build webrtc with chromium
+ # Putting a variables dict inside another variables dict looks kind of
+ # weird. This is done so that 'build_with_chromium' is defined as
+ # variable within the outer variables dict here. This is necessary
+ # to get these variables defined for the conditions within this variables
+ # dict that operate on these variables (e.g., for setting
+ # 'include_pulse_audio', we need to have 'build_with_chromium' already set).
+ 'variables': {
+ # TODO(ajm): use webrtc_standalone to match NaCl?
+ 'build_with_chromium%': 1, # 1 to build webrtc with chromium
+ },
+ 'build_with_chromium%': '<(build_with_chromium)',
+
# Selects fixed-point code where possible.
# TODO(ajm): we'd like to set this based on the target OS/architecture.
'prefer_fixed_point%': 0,
|