Please, I need your help! I'm not able to compile.... typedef struct { } PCMMode; static PCMMode ; int pcm_mode_query(const void *mode, int request, void *ptr) { /*const PCMMode *m = (const PCMMode*)mode;*/ switch (request) { default: speex_warning_int("Unknown nb_mode_query request: ", request); return -1; } return 0; } /* Default mode for narrowband */ const SpeexMode pcm_wrapper_mode = { &pcmmode, pcm_mode_query, "PCM", 0, 4, &pcm_encoder_init, &pcm_encoder_destroy, &pcm_encode, &pcm_decoder_init, &pcm_decoder_destroy, &pcm_decode, &pcm_encoder_ctl, &pcm_decoder_ctl, }; I have 2 errors: - size of 'struct' is unknow or zero - udefined symbol pcmmode Thanks, Mattia.
Hi, Mattia. You wrote April 4th, 2006, 10:58:48:> Please, I need your help! > I'm not able to compile....> typedef struct { > } PCMMode;It's wrong in pure C, there must be at least one field. 2All: can't compile libspeex from trunk with Microsoft compiler. The first problem is the one mentioned above, and the second is absence of keyword 'inline' when compiling as C code (__inline__ must be used instead, may be with some #ifdef's/#define's?). -- WBR, Roman mailto:gembox@yandex.ru
> > Please, I need your help! > > I'm not able to compile.... > > > typedef struct { > > } PCMMode; > > It's wrong in pure C, there must be at least one field.Then just add int dummy. Actually, this code is pretty much useless at the moment, so you can simply remove it from the build and it'll work.> 2All: can't compile libspeex from trunk with Microsoft compiler. The first problem is the one mentioned above, and the second is absence of keyword 'inline' when compiling as C code (__inline__ must be used instead, may be with some #ifdef's/#define's?).Your project file should be using the win32/config.h header and define HAVE_CONFIG_H Jean-Marc