Red Hat Bugzilla – Bug 463009
cdda_interface.h not compatible with C++
Last modified: 2008-09-30 09:30:05 EDT
Description of problem:
The /usr/include/cdda/cdda_interface.h header in cdparanoia 10.2 tries to use "private" as a structure member (in line 87: cdda_private_data_t *private;). This is not allowed in C++ because "private" is a C++ keyword. This breaks the kdemultimedia build.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. Try to rebuild kdemultimedia 4.1.1 against cdparanoia 10.2.
In file included from /builddir/build/BUILD/kdemultimedia-4.1.1/kioslave/audiocd/audiocd.cpp:30:
/usr/include/cdda/cdda_interface.h:87: error: expected unqualified-id before 'private'
/usr/include/cdda/cdda_interface.h:87: error: expected ';' before 'private'
Full build log here:
(and thanks to Matt Domsch for his regular rebuilds).
We could hack around this in kdemultimedia with a #define, but of course I'd much prefer cdparanoia to be fixed. :-)
This also breaks building at least one multimedia package in a 3rd-party repo...
Nb: in my case, even wrapping the cdda_interface.h include with extern "C" doesn't help.
extern "C" doesn't excuse the contained code from being valid C++.
This hack should work:
#define private cdparanoia_private
But instead of adding such hacks to our packages, we should just fix cdparanoia!
Gotcha. Hack does indeed work, employing it for the moment.
Any reason we can't simply rename 'private' to 'pvt' in cdparanoia and call it good? I mean, this breakage didn't exist in prior releases, so I doubt if anything outside of cdparanoia itself is actually using that part of that struct by name...
Also breaks kaffeine's build.
Upstream fix for cdparanoia: https://trac.xiph.org/changeset/15338
Ping? If you don't have the time to fix it, can you please open the package to the "packager" group so somebody else can make the trivial fix (just apply the patch from upstream)?
Thanks for having opened the ACL, I'm fixing this now.