1 #define _GNU_SOURCE 2 #include <string.h> 3 #include <dirent.h> 4 versionsort(const struct dirent ** a,const struct dirent ** b)5int versionsort(const struct dirent **a, const struct dirent **b) 6 { 7 return strverscmp((*a)->d_name, (*b)->d_name); 8 } 9 10 #undef versionsort64 11 weak_alias(versionsort, versionsort64); 12