Add Cygwin check for scandir(); fix from Ken Yarnall.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2595 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
parent
614e835fb9
commit
43519f1264
2
CHANGES
2
CHANGES
@ -1,5 +1,7 @@
|
|||||||
CHANGES IN FLTK 1.1.0
|
CHANGES IN FLTK 1.1.0
|
||||||
|
|
||||||
|
- The newest Cygwin needs the same scandir() handling as
|
||||||
|
HP-UX.
|
||||||
- FLUID didn't register the image formats in the
|
- FLUID didn't register the image formats in the
|
||||||
fltk_images library, and had some other image
|
fltk_images library, and had some other image
|
||||||
management problems.
|
management problems.
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
//
|
//
|
||||||
// "$Id: filename_list.cxx,v 1.10.2.11.2.4 2002/05/25 13:38:25 easysw Exp $"
|
// "$Id: filename_list.cxx,v 1.10.2.11.2.5 2002/08/19 18:11:24 easysw Exp $"
|
||||||
//
|
//
|
||||||
// Filename list routines for the Fast Light Tool Kit (FLTK).
|
// Filename list routines for the Fast Light Tool Kit (FLTK).
|
||||||
//
|
//
|
||||||
@ -49,8 +49,8 @@ int fl_casealphasort(struct dirent **a, struct dirent **b) {
|
|||||||
|
|
||||||
int fl_filename_list(const char *d, dirent ***list,
|
int fl_filename_list(const char *d, dirent ***list,
|
||||||
Fl_File_Sort_F *sort) {
|
Fl_File_Sort_F *sort) {
|
||||||
#if defined(__hpux)
|
#if defined(__hpux) || defined(__CYGWIN__)
|
||||||
// HP-UX defines the comparison function like this:
|
// HP-UX, Cygwin define the comparison function like this:
|
||||||
return scandir(d, list, 0, (int(*)(const dirent **, const dirent **))sort);
|
return scandir(d, list, 0, (int(*)(const dirent **, const dirent **))sort);
|
||||||
#elif defined(__osf__)
|
#elif defined(__osf__)
|
||||||
// OSF, DU 4.0x
|
// OSF, DU 4.0x
|
||||||
@ -59,17 +59,17 @@ int fl_filename_list(const char *d, dirent ***list,
|
|||||||
// AIX is almost standard...
|
// AIX is almost standard...
|
||||||
return scandir(d, list, 0, (int(*)(void*, void*))sort);
|
return scandir(d, list, 0, (int(*)(void*, void*))sort);
|
||||||
#elif HAVE_SCANDIR && !defined(__sgi)
|
#elif HAVE_SCANDIR && !defined(__sgi)
|
||||||
// The vast majority of Unix systems want the sort function to have this
|
// The vast majority of UNIX systems want the sort function to have this
|
||||||
// prototype, most likely so that it can be passed to qsort without any
|
// prototype, most likely so that it can be passed to qsort without any
|
||||||
// changes:
|
// changes:
|
||||||
return scandir(d, list, 0, (int(*)(const void*,const void*))sort);
|
return scandir(d, list, 0, (int(*)(const void*,const void*))sort);
|
||||||
#else
|
#else
|
||||||
// This version is when we define our own scandir (WIN32 and perhaps
|
// This version is when we define our own scandir (WIN32 and perhaps
|
||||||
// some Unix systems) and apparently on Irix:
|
// some Unix systems) and apparently on IRIX:
|
||||||
return scandir(d, list, 0, sort);
|
return scandir(d, list, 0, sort);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
// End of "$Id: filename_list.cxx,v 1.10.2.11.2.4 2002/05/25 13:38:25 easysw Exp $".
|
// End of "$Id: filename_list.cxx,v 1.10.2.11.2.5 2002/08/19 18:11:24 easysw Exp $".
|
||||||
//
|
//
|
||||||
|
Loading…
Reference in New Issue
Block a user