mirror of
https://github.com/panda3d/panda3d.git
synced 2025-09-29 16:20:11 -04:00
dist: replace p3fmod_audio with p3openal_audio if former is missing
This helps when deploying to macOS, where p3fmod_audio is the default for 1.10 builds, a fact that is very easy to overlook when deploying to macOS and only including the p3openal_audio plug-in.
This commit is contained in:
parent
69296585a4
commit
9e80282aff
7
direct/src/dist/commands.py
vendored
7
direct/src/dist/commands.py
vendored
@ -623,6 +623,13 @@ class build_apps(setuptools.Command):
|
||||
if var == 'model-cache-dir' and value:
|
||||
value = value.replace('/panda3d', '/{}'.format(self.distribution.get_name()))
|
||||
|
||||
if var == 'audio-library-name':
|
||||
# We have the default set to p3fmod_audio on macOS in 1.10,
|
||||
# but this can be unexpected as other platforms use OpenAL
|
||||
# by default. Switch it up if FMOD is not included.
|
||||
if value not in self.plugins and value == 'p3fmod_audio' and 'p3openal_audio' in self.plugins:
|
||||
self.warn("Missing audio plugin p3fmod_audio referenced in PRC data, replacing with p3openal_audio")
|
||||
|
||||
for plugin in check_plugins:
|
||||
if plugin in value and plugin not in self.plugins:
|
||||
useline = False
|
||||
|
Loading…
x
Reference in New Issue
Block a user