kcat / openal-soft

OpenAL Soft is a software implementation of the OpenAL 3D audio API.
Other
2.22k stars 536 forks source link

error: use of undeclared identifier 'kAudioObjectPropertyElementMain' #1063

Open ryandesign opened 2 days ago

ryandesign commented 2 days ago

openal-soft 1.24.0 doesn't build on macOS 11:

alc/backends/coreaudio.cpp:307:46: error: use of undeclared identifier 'kAudioObjectPropertyElementMain'; did you mean 'kAudioObjectPropertyElementName'?
            kAudioObjectPropertyScopeGlobal, kAudioObjectPropertyElementMain};
                                             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                                             kAudioObjectPropertyElementName
/Library/Developer/CommandLineTools/SDKs/MacOSX11.sdk/System/Library/Frameworks/CoreAudio.framework/Headers/AudioHardwareBase.h:331:5: note: 'kAudioObjectPropertyElementName' declared here
    kAudioObjectPropertyElementName         = 'lchn',
    ^
alc/backends/coreaudio.cpp:315:46: error: use of undeclared identifier 'kAudioObjectPropertyElementMain'; did you mean 'kAudioObjectPropertyElementName'?
            kAudioObjectPropertyScopeGlobal, kAudioObjectPropertyElementMain};
                                             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                                             kAudioObjectPropertyElementName
/Library/Developer/CommandLineTools/SDKs/MacOSX11.sdk/System/Library/Frameworks/CoreAudio.framework/Headers/AudioHardwareBase.h:331:5: note: 'kAudioObjectPropertyElementName' declared here
    kAudioObjectPropertyElementName         = 'lchn',
    ^

Full build log: https://build.macports.org/builders/ports-11_x86_64-builder/builds/172017/steps/install-port/logs/stdio

It builds on macOS 12 and later.

This is a regression; 1.23.1 didn't have this problem.

Problem introduced in 5f88fe54a06fda76cf16c2dec1d242cdb5e4a8ae.

kcat commented 2 days ago

Should be fixed with commit a74fa14d46659b60d0039a4aed3eab804d9e8c26.