Skip to content
This repository has been archived by the owner on Mar 3, 2022. It is now read-only.

Build Failure With SpeexDSP>=1.2rc2 #627

Closed
GoogleCodeExporter opened this issue Apr 25, 2015 · 5 comments
Closed

Build Failure With SpeexDSP>=1.2rc2 #627

GoogleCodeExporter opened this issue Apr 25, 2015 · 5 comments

Comments

@GoogleCodeExporter
Copy link

Which version of Cantata?
r5668

Which build? KDE, Qt4, Qt5, Windows, Ubuntu, Mac?
KDE and Qt5

When the speex devs split the speex codec library and the speex DSP library 
into separate source trees starting with v1.2rc2 they made the following 
changes to /usr/include/speex/speex_config_types.h:

#ifndef __SPEEX_TYPES_H__                    #ifndef __SPEEX_TYPES_H__
#define __SPEEX_TYPES_H__                    #define __SPEEX_TYPES_H__

/* these are filled in by configure */       | #include <stdint.h>
typedef short spx_int16_t;                   |
typedef unsigned short spx_uint16_t;         | typedef int16_t spx_int16_t;
typedef int spx_int32_t;                     | typedef uint16_t spx_uint16_t;
typedef unsigned int spx_uint32_t;           | typedef int32_t spx_int32_t;
                                             > typedef uint32_t spx_uint32_t;

#endif                                       #endif

This now results in a build failure when trying to build with speexdsp-1.2rc2 
or higher:

In file included from /usr/include/speex/speexdsp_types.h:122:0,
                 from /usr/include/speex/speex_resampler.h:87,
                 from /home/user/Projects/cantata-kde-svn/src/cantata-kde-svn/3rdparty/ebur128/ebur128.c:34:
/usr/include/speex/speexdsp_config_types.h:13:9: error: unknown type name 
‘uint16_t’
 typedef uint16_t spx_uint16_t;
         ^
/usr/include/speex/speexdsp_config_types.h:15:9: error: unknown type name 
‘uint32_t’
 typedef uint32_t spx_uint32_t;
         ^
Scanning dependencies of target qtiocompressor
/home/user/cantata-kde-svn/src/cantata-kde-svn/3rdparty/ebur128/ebur128.c: In 
function ‘ebur128_check_true_peak’:
/home/user/cantata-kde-svn/src/cantata-kde-svn/3rdparty/ebur128/ebur128.c:395:19
: warning: comparison between signed and unsigned integer expressions 
[-Wsign-compare]
     for (i = 0; i < out_len; ++i) {
                   ^
3rdparty/ebur128/CMakeFiles/ebur128.dir/build.make:54: recipe for target 
'3rdparty/ebur128/CMakeFiles/ebur128.dir/ebur128.o' failed
make[2]: *** [3rdparty/ebur128/CMakeFiles/ebur128.dir/ebur128.o] Error 1
CMakeFiles/Makefile2:305: recipe for target 
'3rdparty/ebur128/CMakeFiles/ebur128.dir/all' failed
make[1]: *** [3rdparty/ebur128/CMakeFiles/ebur128.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....

Original issue reported on code.google.com by hbdee.a...@gmail.com on 15 Feb 2015 at 3:17

@GoogleCodeExporter
Copy link
Author

Build log cant be from r5668 - as the warning about signed/unsigned is fixed in 
that revision.

The actual errors, however, appear to be *within* speex itself. 
/usr/include/speex/speexdsp_config_types.h is a speex file - and that is where 
the error lies. Not sure what you expect Cantata to do. I'm guessing speex 
needs to include stdint.h. If you edit 3rdparty/ebur128/ebur128.c and add:

#include <stdint.h>

just before "#include <speex/speex_resampler.h>" - does this work-around the 
issue? If so, its still a speex issue - its headers should include any other 
headers they require.

Original comment by craig.p....@gmail.com on 15 Feb 2015 at 3:29

@GoogleCodeExporter
Copy link
Author

Actually, looking at your original post it appears as if 
speexdsp_config_types.h does include stdint.h So, this is very odd. Therefore, 
my 'fix' above will probably not work - worth a try.

Does your stdint.h have a typedef line for uint16_t ??

Original comment by craig.p....@gmail.com on 15 Feb 2015 at 4:18

@GoogleCodeExporter
Copy link
Author

Your fix actually worked. stdint.h does have a typedef line for uint16_t: 
typedef uint16_t spx_uint16_t;

Original comment by hbdee.a...@gmail.com on 16 Feb 2015 at 2:21

@GoogleCodeExporter
Copy link
Author

Fixed in trunk and branches/1.5 - thanks for the confirmation. Still, the issue 
is with speex

Original comment by craig.p....@gmail.com on 17 Feb 2015 at 8:06

  • Changed state: Verified

@GoogleCodeExporter
Copy link
Author

I had the same error with alsa project and fixed it by adding '-DHAVE_STDINT_H' 
to CFLAGS.

IMHO this issue should be reported to speex mailist. It should be really 
resolved on their side.

Original comment by ana...@google.com on 4 Mar 2015 at 5:16

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant