1 diff --git a/wvmodemscan.cc b/wvmodemscan.cc
2 index ef5ab87..f97581e 100644
5 @@ -503,11 +503,16 @@ static int fileselect(const struct dirent *e)
10 +#if defined(__GLIBC__) && __GLIBC_PREREQ(2, 10)
11 +static int filesort(const struct dirent **e1, const struct dirent **e2)
13 static int filesort(const void *_e1, const void *_e2)
16 +#if !(defined(__GLIBC__) && __GLIBC_PREREQ(2, 10))
17 dirent const * const *e1 = (dirent const * const *)_e1;
18 dirent const * const *e2 = (dirent const * const *)_e2;