speechd-discuss
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH] determine availability of audio plugins by using config.h


From: William Hubbs
Subject: [PATCH] determine availability of audio plugins by using config.h
Date: Sun, 5 Dec 2010 10:27:25 -0600

On Sun, Dec 05, 2010 at 10:59:14AM +0000, Andrei Kholodnyi wrote:
> > +#ifdef HAVE_ALSA
> > +spd_audio_plugin_t const *alsa_plugin_get(void);
> > +#endif
> > +
> > +#ifdef HAVE_LIBAO
> > +spd_audio_plugin_t const *libao_plugin_get(void);
> > +#endif
> > +
> > +#ifdef HAVE_NAS
> > +spd_audio_plugin_t const *nas_plugin_get(void);
> > +#endif
> > +
> > +#ifdef HAVE_OSS
> > +spd_audio_plugin_t const *oss_plugin_get(void);
> > +#endif
> > +
> > +#ifdef HAVE_PULSE
> > +spd_audio_plugin_t const *pulse_plugin_get(void);
> > +#endif
> > +
> 
> 
> This has "no go" status from my side!
> It means if you'd have 1000 audio plugins,
> you'd have 1000 #ifdef MY FAVORITE SPECIAL CASE in C code.

If you look over the autotools manuals, this is the way they recommend
controling configurations. Config.h sets up HAVE_FOO directives and the
rest of the code responds based on those directives.

I really would like to see us have config.h be the only generated source
file other than Makefiles, and this patch makes that possible.

Thanks,

William

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
URL: 
<http://lists.freebsoft.org/pipermail/speechd/attachments/20101205/ee8cd334/attachment.pgp>


reply via email to

[Prev in Thread] Current Thread [Next in Thread]