diff options
author | Takashi Iwai <tiwai@suse.de> | 2020-05-06 22:40:16 +0200 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2020-05-06 22:40:16 +0200 |
commit | bb43546c7a3d535576b49f0a729761ba6a348892 (patch) | |
tree | 6614eda3901ff8d4e9f2d27d0c024298dc7cf4ee /include | |
parent | abc9f32cf45ccaf7a2f6674e5803aba6d4b5a7bf (diff) | |
download | alsa-lib-bb43546c7a3d535576b49f0a729761ba6a348892.tar.gz |
header: Fix build error with old kernel headers
Old development environment doesn't necessarily contain the headers
defining __kernel_long_t that is recently used for y2038 timespec
conditional. Define it explicitly in such a case.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'include')
-rw-r--r-- | include/sound/asound.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/include/sound/asound.h b/include/sound/asound.h index 3be4d850..89dd7d2f 100644 --- a/include/sound/asound.h +++ b/include/sound/asound.h @@ -1 +1,11 @@ +/* workaround for building with old glibc / kernel headers */ +#ifdef __linux__ +#include <linux/types.h> +#else +#include <sys/types.h> +#endif +#ifndef __kernel_long_t +#define __kernel_long_t long +#endif + #include <alsa/sound/uapi/asound.h> |