mirror of
https://github.com/alsa-project/alsa-lib.git
synced 2025-10-29 05:40:25 -04:00
Added check for buggy gcc
This commit is contained in:
parent
58563bc209
commit
c9fb7faa1a
1 changed files with 31 additions and 0 deletions
|
|
@ -26,6 +26,10 @@
|
||||||
typedef float float_t;
|
typedef float float_t;
|
||||||
typedef double double_t;
|
typedef double double_t;
|
||||||
|
|
||||||
|
#if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR <= 91)
|
||||||
|
#define BUGGY_GCC
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifndef PIC
|
#ifndef PIC
|
||||||
/* entry for static linking */
|
/* entry for static linking */
|
||||||
const char *_snd_module_pcm_float = "";
|
const char *_snd_module_pcm_float = "";
|
||||||
|
|
@ -72,6 +76,8 @@ int snd_pcm_lfloat_put_s32_index(snd_pcm_format_t format)
|
||||||
return snd_pcm_lfloat_get_s32_index(format);
|
return snd_pcm_lfloat_get_s32_index(format);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifndef BUGGY_GCC
|
||||||
|
|
||||||
void snd_pcm_lfloat_convert_integer_float(const snd_pcm_channel_area_t *dst_areas, snd_pcm_uframes_t dst_offset,
|
void snd_pcm_lfloat_convert_integer_float(const snd_pcm_channel_area_t *dst_areas, snd_pcm_uframes_t dst_offset,
|
||||||
const snd_pcm_channel_area_t *src_areas, snd_pcm_uframes_t src_offset,
|
const snd_pcm_channel_area_t *src_areas, snd_pcm_uframes_t src_offset,
|
||||||
unsigned int channels, snd_pcm_uframes_t frames,
|
unsigned int channels, snd_pcm_uframes_t frames,
|
||||||
|
|
@ -425,3 +431,28 @@ int _snd_pcm_lfloat_open(snd_pcm_t **pcmp, const char *name,
|
||||||
return err;
|
return err;
|
||||||
}
|
}
|
||||||
SND_DLSYM_BUILD_VERSION(_snd_pcm_lfloat_open, SND_PCM_DLSYM_VERSION);
|
SND_DLSYM_BUILD_VERSION(_snd_pcm_lfloat_open, SND_PCM_DLSYM_VERSION);
|
||||||
|
|
||||||
|
#else /* BUGGY_GCC */
|
||||||
|
|
||||||
|
int snd_pcm_lfloat_open(snd_pcm_t **pcmp ATTRIBUTE_UNUSED,
|
||||||
|
const char *name ATTRIBUTE_UNUSED,
|
||||||
|
snd_pcm_format_t sformat ATTRIBUTE_UNUSED,
|
||||||
|
snd_pcm_t *slave ATTRIBUTE_UNUSED,
|
||||||
|
int close_slave ATTRIBUTE_UNUSED)
|
||||||
|
{
|
||||||
|
SNDERR("please, upgrade your GCC to use lfloat plugin");
|
||||||
|
return -EINVAL;
|
||||||
|
}
|
||||||
|
|
||||||
|
int _snd_pcm_lfloat_open(snd_pcm_t **pcmp ATTRIBUTE_UNUSED,
|
||||||
|
const char *name ATTRIBUTE_UNUSED,
|
||||||
|
snd_config_t *root ATTRIBUTE_UNUSED,
|
||||||
|
snd_config_t *conf ATTRIBUTE_UNUSED,
|
||||||
|
snd_pcm_stream_t stream ATTRIBUTE_UNUSED,
|
||||||
|
int mode ATTRIBUTE_UNUSED)
|
||||||
|
{
|
||||||
|
SNDERR("please, upgrade your GCC to use lfloat plugin");
|
||||||
|
return -EINVAL;
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif /* BUGGY_GCC */
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue