[odamex-bug-reporter] [Bug 827] New: Deprecated Mac API
- From: odamex-bugtracker@xxxxxxxxxx
- To: odamex-bug-reporter@xxxxxxxxxxxxx
- Date: Sat, 05 May 2012 19:00:03 +0000
http://odamex.net/bugs/show_bug.cgi?id=827
Bug #: 827
Summary: Deprecated Mac API
Classification: Unclassified
Product: Odamex
Version: 0.6-dev
Platform: All
OS/Version: Mac OS
Status: NEW
Severity: normal
Priority: P1
Component: Client
AssignedTo: odamex-bug-reporter@xxxxxxxxxxxxx
ReportedBy: mwoodj@xxxxxxxxxxx
A number of methods that Odamex uses on Mac OS X have been deprecated. The code
that uses these methods needs to be refactored to replace these method calls
with current API. Here are the warnings associated with the use of the
deprecated API:
[ 0%] Building CXX object client/CMakeFiles/odamex.dir/sdl/i_musicsystem.cpp.o
/Users/blackdogapps/Projects/Odamex/branches/0.6-dev/client/sdl/i_musicsystem.cpp:
In constructor ‘AuMusicSystem::AuMusicSystem()’:
/Users/blackdogapps/Projects/Odamex/branches/0.6-dev/client/sdl/i_musicsystem.cpp:375:
warning: ‘AUGraphNewNode’ is deprecated (declared at
/System/Library/Frameworks/AudioToolbox.framework/Headers/AUGraph.h:673)
/Users/blackdogapps/Projects/Odamex/branches/0.6-dev/client/sdl/i_musicsystem.cpp:375:
warning: ‘AUGraphNewNode’ is deprecated (declared at
/System/Library/Frameworks/AudioToolbox.framework/Headers/AUGraph.h:673)
/Users/blackdogapps/Projects/Odamex/branches/0.6-dev/client/sdl/i_musicsystem.cpp:382:
warning: ‘AUGraphNewNode’ is deprecated (declared at
/System/Library/Frameworks/AudioToolbox.framework/Headers/AUGraph.h:673)
/Users/blackdogapps/Projects/Odamex/branches/0.6-dev/client/sdl/i_musicsystem.cpp:382:
warning: ‘AUGraphNewNode’ is deprecated (declared at
/System/Library/Frameworks/AudioToolbox.framework/Headers/AUGraph.h:673)
/Users/blackdogapps/Projects/Odamex/branches/0.6-dev/client/sdl/i_musicsystem.cpp:402:
warning: ‘AUGraphGetNodeInfo’ is deprecated (declared at
/System/Library/Frameworks/AudioToolbox.framework/Headers/AUGraph.h:687)
/Users/blackdogapps/Projects/Odamex/branches/0.6-dev/client/sdl/i_musicsystem.cpp:402:
warning: ‘AUGraphGetNodeInfo’ is deprecated (declared at
/System/Library/Frameworks/AudioToolbox.framework/Headers/AUGraph.h:687)
/Users/blackdogapps/Projects/Odamex/branches/0.6-dev/client/sdl/i_musicsystem.cpp:
In member function ‘void AuMusicSystem::_RegisterSong(byte*, size_t)’:
/Users/blackdogapps/Projects/Odamex/branches/0.6-dev/client/sdl/i_musicsystem.cpp:632:
warning: ‘MusicSequenceLoadSMFData’ is deprecated (declared at
/System/Library/Frameworks/AudioToolbox.framework/Headers/MusicPlayer.h:1594)
/Users/blackdogapps/Projects/Odamex/branches/0.6-dev/client/sdl/i_musicsystem.cpp:632:
warning: ‘MusicSequenceLoadSMFData’ is deprecated (declared at
/System/Library/Frameworks/AudioToolbox.framework/Headers/MusicPlayer.h:1594)
[ 0%] Building CXX object client/CMakeFiles/odamex.dir/sdl/i_system.cpp.o
/Users/blackdogapps/Projects/Odamex/branches/0.6-dev/client/sdl/i_system.cpp:
In function ‘std::string I_GetClipboardText()’:
/Users/blackdogapps/Projects/Odamex/branches/0.6-dev/client/sdl/i_system.cpp:796:
warning: ‘GetCurrentScrap’ is deprecated (declared at
/System/Library/Frameworks/Carbon.framework/Frameworks/HIToolbox.framework/Headers/Scrap.h:263)
/Users/blackdogapps/Projects/Odamex/branches/0.6-dev/client/sdl/i_system.cpp:796:
warning: ‘GetCurrentScrap’ is deprecated (declared at
/System/Library/Frameworks/Carbon.framework/Frameworks/HIToolbox.framework/Headers/Scrap.h:263)
/Users/blackdogapps/Projects/Odamex/branches/0.6-dev/client/sdl/i_system.cpp:804:
warning: ‘GetScrapFlavorSize’ is deprecated (declared at
/System/Library/Frameworks/Carbon.framework/Frameworks/HIToolbox.framework/Headers/Scrap.h:322)
/Users/blackdogapps/Projects/Odamex/branches/0.6-dev/client/sdl/i_system.cpp:804:
warning: ‘GetScrapFlavorSize’ is deprecated (declared at
/System/Library/Frameworks/Carbon.framework/Frameworks/HIToolbox.framework/Headers/Scrap.h:322)
/Users/blackdogapps/Projects/Odamex/branches/0.6-dev/client/sdl/i_system.cpp:814:
warning: ‘GetScrapFlavorData’ is deprecated (declared at
/System/Library/Frameworks/Carbon.framework/Frameworks/HIToolbox.framework/Headers/Scrap.h:353)
/Users/blackdogapps/Projects/Odamex/branches/0.6-dev/client/sdl/i_system.cpp:814:
warning: ‘GetScrapFlavorData’ is deprecated (declared at
/System/Library/Frameworks/Carbon.framework/Frameworks/HIToolbox.framework/Headers/Scrap.h:353)
The methods and their availability are as follows:
AUGraphNewNode() - Available but deprecated as of 10.5
AUGraphGetNodeInfo() - Available but deprecated as of 10.5
MusicSequenceLoadSMFData() - Available but deprecated for 32-bit as of 10.5.
Unavailable for 64-bit archs.
GetCurrentScrap() - Available but deprecated for 32-bit as of 10.5. Unavailable
for 64-bit archs.
GetScrapFlavorSize() - Available but deprecated for 32-bit as of 10.5.
Unavailable for 64-bit archs.
GetScrapFlavorData() - Available but deprecated for 32-bit as of 10.5.
Unavailable for 64-bit archs.
Because some of this deprecated API is unavailable on 64-bit Odamex currently
does not build for 64-bit architectures on Mac. It has to be built for either
or both ppc and i386. This is not a show stopper for Odamex as the Mac releases
are always built against the 10.4 SDK, where this API is not deprecated, for
the 32-bit ppc and i386 architectures. Those builds run on all 32-bit and
64-bit Mac OS and platform combinations from 10.4 compatible hardware to
present hardware. Still, this means that a user will encounter an error if they
attempt to build Odamex on a 64-bit Mac when no flags are used. The information
related to properly configuring Odamex to build is available on the wiki.
The replacement methods and their availability are as follows:
AUGraphNewNode() > AUGraphAddNode() - Available as of 10.5.
AUGraphGetNodeInfo() > AUGraphNodeInfo() - Available as of 10.5.
MusicSequenceLoadSMFData() - Deprecated without replacement?
GetCurrentScrap() -> PasteboardCreate() - Available as of 10.3.
GetScrapFlavorSize() - Deprecated without replacement. New API makes it
unnecessary.
GetScrapFlavorData() -> PasteboardCopyItemFlavorData() - Available as of 10.3.
The AudioToolbox replacement methods obviously cannot simply be dropped in
place of the old API if we want to continue to support 10.4. We will need to
use one or the other based on the minimum supported OS provided at compile
time. This is different from the OS the user is building on or even the minimum
OS supported by the SDK being used as the compiler can be provided with a
specific requirement for the minimum OS to support for the build.
In general the Scrap Manager is a feature of classic Mac OS that was replaced
in OS X by the Pasteboard Manager. The use of Scrap Manager can likely be
removed completely in favor of Pasteboard Manager. It seems highly unlikely
that the current codebase still builds on classic Mac OS.
These warnings were generated by building against the 10.6 frameworks. It is
possible that more API could be deprecated by the 10.7 SDK. There is also a new
release of OS X coming up which I presume will introduce the 10.8 SDK.
--
Configure bugmail: http://odamex.net/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
Other related posts:
- » [odamex-bug-reporter] [Bug 827] New: Deprecated Mac API - odamex-bugtracker