[mythtv] configure and "restrict"
Nigel Pearson
nigel at ind.tansu.com.au
Wed Oct 29 23:29:22 UTC 2008
> I'm not sure if it is a mac os x specific issue. We shouldn't
> use "restrict" in C++ code since the compiler will just ignore it.
We don't. The actual compile errors were from system #includes:
g++ ... audiooutputbase.cpp
/usr/include/inttypes.h:264: error: expected ',' or '...' before 'nptr'
/usr/include/inttypes.h:265: error: expected ',' or '...' before 'nptr'
/usr/include/inttypes.h:275: error: expected ',' or '...' before 'nptr'
/usr/include/inttypes.h:276: error: expected ',' or '...' before 'nptr'
make[2]: *** [audiooutputbase.o] Error 1
where that header has stuff like:
extern intmax_t strtoimax(const char * restrict nptr,
char ** restrict endptr, int base);
Basically, audiooutputdigitalencoder.h has
extern "C" {
#include "libavcodec/avcodec.h"
};
which pulls in libavutil/avutil.h, libavutil/common.h
and /usr/include/inttypes.h. Of course, the extern C
doesn't strip out C-specific qualifiers like restrict.
FreeBSD and Linux versions of that header seem to use
__restrict exclusively, so it does look OS X specific?
--
Nigel Pearson, nigel at ind.tansu.com.au| I've been talking to |
Telstra Net. Eng., Sydney, Australia | the ship's computer. |
Office: 9202 3900 Fax: 9212 6348 | ... It hates me! |
Mobile: 0408 664435 Home: 9792 6998 | Marvin |
More information about the mythtv-dev
mailing list